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

feat: RPC - add starknet_getClassHashAt #276

Conversation

ftupas
Copy link
Contributor

@ftupas ftupas commented Apr 20, 2023

Implement starknet_getClassHashAt RPC that gets the contract class hash in the given block for the contract deployed at the given address

Pull Request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no API changes)
  • Build-related changes
  • Documentation content changes
  • Testing
  • Other (please describe):

What is the current behavior?

Issue Number: #196

What is the new behavior?

image

Does this introduce a breaking change?

  • Yes
  • No

Other information

@codecov
Copy link

codecov bot commented Apr 20, 2023

Codecov Report

Patch coverage has no change and project coverage change: -0.33 ⚠️

Comparison is base (99594b8) 35.66% compared to head (91f98b3) 35.33%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #276      +/-   ##
==========================================
- Coverage   35.66%   35.33%   -0.33%     
==========================================
  Files          61       61              
  Lines        5050     5097      +47     
  Branches     5050     5097      +47     
==========================================
  Hits         1801     1801              
- Misses       2779     2826      +47     
  Partials      470      470              
Impacted Files Coverage Δ
crates/client/rpc-core/src/lib.rs 16.47% <ø> (ø)
crates/client/rpc/src/lib.rs 11.83% <0.00%> (-1.42%) ⬇️
crates/client/storage/src/overrides/mod.rs 0.00% <0.00%> (ø)
...client/storage/src/overrides/schema_v1_override.rs 0.00% <0.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@ftupas ftupas force-pushed the feat/rpc-add-starknet_getClassHashAt branch from 7948acc to a2b1d3d Compare April 20, 2023 12:27
Copy link
Collaborator

@EvolveArt EvolveArt left a comment

Choose a reason for hiding this comment

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

left few comments, please improve integration tests (add more cases and test return values)

crates/client/rpc-core/src/lib.rs Outdated Show resolved Hide resolved
crates/client/rpc/src/lib.rs Outdated Show resolved Hide resolved
crates/client/storage/src/overrides/mod.rs Show resolved Hide resolved
@ftupas
Copy link
Contributor Author

ftupas commented Apr 21, 2023

left few comments, please improve integration tests (add more cases and test return values)

Thanks for the review @EvolveArt , will update accordingly ✌️

@ftupas ftupas force-pushed the feat/rpc-add-starknet_getClassHashAt branch from 5ce375d to 04075ff Compare April 26, 2023 17:39
@ftupas ftupas requested a review from EvolveArt April 26, 2023 17:39
@ftupas ftupas force-pushed the feat/rpc-add-starknet_getClassHashAt branch 4 times, most recently from 6967432 to 04bec2f Compare May 1, 2023 07:02
@AbdelStark
Copy link
Contributor

hey @ftupas what is the status of this PR ?

@ftupas
Copy link
Contributor Author

ftupas commented May 1, 2023

hey @ftupas what is the status of this PR ?

Hi @abdelhamidbakhta, it's up for review normally I've resolved the conflicts 🤙 I've also improved the integration test by adding more test cases

@AbdelStark
Copy link
Contributor

hey @ftupas what is the status of this PR ?

Hi @abdelhamidbakhta, it's up for review normally I've resolved the conflicts 🤙 I've also improved the integration test by adding more test cases

awesome thanks for the prompt reply. I will leave @EvolveArt continue the review then

@ftupas ftupas force-pushed the feat/rpc-add-starknet_getClassHashAt branch from 04bec2f to b2dcc51 Compare May 1, 2023 15:04
@ftupas ftupas force-pushed the feat/rpc-add-starknet_getClassHashAt branch from b2dcc51 to 3e9eda3 Compare May 2, 2023 15:16
Copy link
Collaborator

@EvolveArt EvolveArt left a comment

Choose a reason for hiding this comment

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

lgtm

@EvolveArt EvolveArt merged commit 44a90ef into keep-starknet-strange:main May 4, 2023
8 of 9 checks passed
@ftupas ftupas deleted the feat/rpc-add-starknet_getClassHashAt branch May 4, 2023 14:58
@VeryDustyBot
Copy link

This item belongs to payment request #19FC5A on OnlyDust:

@github-actions github-actions bot locked and limited conversation to collaborators May 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: RPC - starknet_getClassHashAt
4 participants