8000 feat(core): implement `getBlockHeight` RPC method by Ozodimgba · Pull Request #132 · txtx/surfpool · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(core): implement getBlockHeight RPC method #132

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

Merged
merged 6 commits into from
Jun 6, 2025

Conversation

Ozodimgba
Copy link
Contributor

No description provided.

}

#[test]
fn test_get_block_height_debug_slots() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test has no assertions, and I'm not sure from the name what the purpose of the test is

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that was my personal test that I didnt remove

}

#[test]
fn test_get_block_height_with_valid_min_context_slot() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good test! Can we also get one for the failure case - asserting the RPC returns an error if the min_context_slot is beyond the current slot?

@Ozodimgba
Copy link
Contributor Author

@MicaiahReid refactored blocks, take a look

@MicaiahReid MicaiahReid self-requested a review June 5, 2025 15:12
Copy link
Member
@MicaiahReid MicaiahReid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking great! Two minor changes then we're ready to merge!

@Ozodimgba
Copy link
Contributor Author

@MicaiahReid this should do it

Copy link
Member
@MicaiahReid MicaiahReid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work!!

@MicaiahReid
Copy link
Member

aggh, sorry, looks like CI isn't passing cause of some formatting. Should be an easy fix!

Run cargo +nightly fmt --all -- --check and implement the changes

@Ozodimgba
Copy link
Contributor Author

@MicaiahReid done

@MicaiahReid
Copy link
Member

Hey @Ozodimgba there are still more issues that need to be fixed from cargo +nightly fmt --all -- --check

Copy link
Collaborator
@BretasArthur1 BretasArthur1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!!

@MicaiahReid MicaiahReid changed the title added Get block height feat(core): implement getBlockHeight RPC method Jun 6, 2025
@MicaiahReid MicaiahReid merged commit 8041b12 into txtx:main Jun 6, 2025
2 checks passed
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 this pull request may close these issues.

4 participants
0