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

Support archive_unstable_hashByHeight #852

Closed
Tbaut opened this issue Oct 31, 2024 · 2 comments · Fixed by #853
Closed

Support archive_unstable_hashByHeight #852

Tbaut opened this issue Oct 31, 2024 · 2 comments · Fixed by #853

Comments

@Tbaut
Copy link
Contributor

Tbaut commented Oct 31, 2024

hello there,
I'm using with papi the archive_unstable_hashByHeight because it's the only way to get a block hash from a block number. It used to be possible with pjs using api.rpc.getBlockHash(number), and this was working well with Chopstick too.. but it's not the case any more.

Is there any way you can support this? Also I'm actually requesting a block height that has been seen by smoldot, so this block should be found easily.

Here's the error stack, using chopsticks v1.0.0

ERROR (ws): Error handling request: 'ResponseError: Method not found: archive_unstable_hashByHeight
[0] at /home/thib/.npm/_npx/1063adea9feffe0e/node_modules/@acala-network/chopsticks/dist/cjs/rpc/index.js:39:19
[0] at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[0] at async processRequest (/home/thib/.npm/_npx/1063adea9feffe0e/node_modules/@acala-network/chopsticks/dist/cjs/server.js:225:30)
[0] at async WebSocket. (/home/thib/.npm/_npx/1063adea9feffe0e/node_modules/@acala-network/chopsticks/dist/cjs/server.js:287:30)'
[0] app: "chopsticks"

@ermalkaleci
Copy link
Collaborator

archive_unstable_hashByHeight has never existed on Chopsticks RPC. This is just an alias of getBlockHash and has nothing to do with smoldot. If you can please add this alias and make a PR

@Tbaut
Copy link
Contributor Author

Tbaut commented Nov 4, 2024

Thanks for the pointer, I have no idea what I'm talking about indeed! I've never hinted at the fact that Chopstick changed, I say it's not working any more (now with papi, knowing perfectly that this is what made it fail). I'll check how to make aliases and make a pr ;)

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

Successfully merging a pull request may close this issue.

2 participants