Repository navigation
Add Akash deployment status route - #439
Closed
Dhirenderchoudhary wants to merge 2 commits into
Closed
Dhirenderchoudhary wants to merge 2 commits into
Dhirenderchoudhary wants to merge 2 commits into
Conversation
Collaborator
|
Thanks for this and for testing it against a stub chain API. I'm closing it rather than merging, and want to explain why, since the code itself is fine. While reviewing, I checked the chain API against mainnet:
That's a project of its own and the proposed platform plan moves DePIN providers out of core, since they can't give the runtime control the scaling work needs. So we're parking Akash rather than fixing it piece by piece. Your branch stays here if Akash comes back later behind the plugin boundary. Closing #435 for the same reason. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #435
Why
The Python Akash adapter polls
GET /deployments/status/{id}, but the sidecar never had that route. Every poll got a 404, so every Akash deploy timed out after the paid deployment was already created. The adapter also had noget_node_status, so liveness always saw "unknown" and never noticed a dead Akash deployment.What changed
GET /akash/deployments/status/:id. It reads the deployment from the chain REST API and returns{ state }(activeorclosed). It returns 404 if the chain doesn't know the dseq, and 502 on other errors.AkashAdapter.get_node_statusmapsactiveto RUNNING andclosedto STOPPED. Anything else, including errors, is "unknown", so liveness only acts on a confirmed state.AKASH_API(defaulthttps://api.akashnet.net).fetchBidsuses it too.Scope
closeDeploymentandsendManifestin the sidecar are still placeholders that don't touch the chain. That is a separate fix.wait_for_readyis unchanged. It already handledactive/closed; it just never got an answer.Verification
get_node_statusreturned "unknown" for both live and closed deployments on main, and returns RUNNING / STOPPED / unknown now.ts-node src/server.ts) against a stub chain API and called it from the adapter:111 RUNNING,222 STOPPED,333 unknown, andwait_for_readyreturned straight away. The stub saw the wallet address and dseq in each query.tsc --noEmitpasses for the sidecar. Liveness and direct provision tests pass (78).