Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retrieving error types from the metadata of the Substrate palette "SubtensorModule" for the btcli console #1859

Open
6 of 8 tasks
roman-opentensor opened this issue May 9, 2024 · 2 comments
Assignees
Labels

Comments

@roman-opentensor
Copy link
Contributor

roman-opentensor commented May 9, 2024

Is your feature request related to a problem? Please describe.

The feature related with following issues:

Describe the solution you'd like

With functionality of substrateinterface lib, we retrieve the metadata from Subtensor.

This allows us to:

  1. Avoid hardcoding the error description.
  2. Always have up-to-date information about all errors on the server.
  3. Automatically receive updates to the list of errors and their descriptions.

Acceptance Criteria

  • Research: Exploring the logic of how the substrateinterface package interacts with metadata.
  • Research: Exploring structure of metadata by the provided data.
  • Implementation: Retrieving metadata from SubtensorModule.
  • Implementation: Caching a JSON object with a list of errors in the user's directory.
  • Implementation: Logic to control the relevancy of cached data relative to server metadata.
  • Implementation: Covering new code with unit tests.
  • Implementation: a wrapper for presenting the error in a human-readable view.
  • Testing new logic on a local network.

Describe alternatives you've considered

Previously, the team considered the possibility of implementing an API endpoint that would return data about the list of errors. After starting the implementation, the decision was canceled in favor of using the capabilities of the substrateinterface package.

@roman-opentensor
Copy link
Contributor Author

roman-opentensor commented May 10, 2024

I decided to split #1859 into 2 PRs
The first one #1862 (merged)

@roman-opentensor
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant