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

getPairs method is deprecated, need getKeyPaged #36

Open
levchmike opened this issue Jul 30, 2022 · 5 comments
Open

getPairs method is deprecated, need getKeyPaged #36

levchmike opened this issue Jul 30, 2022 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@levchmike
Copy link

if i use getPairs then i get -32603: Unknown error occurred: UnsafeRpcCalled, UnsafeRpcError. Can youupdate this?

@dimitrispaxinos
Copy link
Contributor

@levchmike thank you for trying out the Ajuna.SDK and opening the issue.

We will look into it and get back to you asap.

@dimitrispaxinos
Copy link
Contributor

Hi again @levchmike,

Could you please provide some more details regarding the issue, like

  • the Ajuna.SDK Version
  • the Node Versions
  • the exact error message/exception that you get

We do not seem to be able to reproduce this on our side and I am not sure whether the UnsafeRpcCalled & UnsafeRpcError errors could be caused by a deprecated method.

@darkfriend77
Copy link
Member

darkfriend77 commented Jul 31, 2022

@levchmike @dimitrispaxinos getPaires is a restricted RPC Call, we can reproduce by accessing rpc.polkadot.io with the SDK or simply executing getPairs in polkadot.js on Polkadot.

image

We will check, if we can use getKeysPaged.

@levchmike
Copy link
Author

@darkfriend77 @dimitrispaxinos hey! can i connect to my substrate wss? i can try ur branch with getPaged method but i have exception

@dimitrispaxinos
Copy link
Contributor

Hey @levchmike , what has been done on this branch is still Work In Progress. The main problem when switching getPairs with getKeyPaged is the fact that it significantly increases the initial number of calls to the node. We are currently working on the best possible approach.

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

No branches or pull requests

4 participants