Skip to content

refactor(torii): abstract out how to format felts to avoid bugs - #2444

Merged
itzlambda merged 6 commits into
spr/main/5231a946from
spr/main/d618e874
Sep 24, 2024
Merged

refactor(torii): abstract out how to format felts to avoid bugs#2444
itzlambda merged 6 commits into
spr/main/5231a946from
spr/main/d618e874

Conversation

@itzlambda

@itzlambda itzlambda commented Sep 18, 2024

Copy link
Copy Markdown

@glihm glihm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for this refactoring, useful to avoid too much strings to update in case of changes.

}

pub(crate) fn felt_to_sql_string(felt: &Felt) -> String {
format!("{:#x}", felt)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We should perhaps have a function with padding and one without padding? Or we always use without padding?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

yeah for felt we where not padding previously so i kept the same behaviour

@itzlambda
itzlambda force-pushed the spr/main/d618e874 branch 2 times, most recently from a97288c to 6f1f5a4 Compare September 19, 2024 09:41
@codecov

codecov Bot commented Sep 19, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 26.08696% with 34 lines in your changes missing coverage. Please review.

Please upload report for BASE (spr/main/5231a946@3414843). Learn more about missing BASE report.

Files with missing lines Patch % Lines
crates/torii/core/src/sql/erc.rs 0.00% 28 Missing ⚠️
crates/torii/core/src/sql/mod.rs 62.50% 3 Missing ⚠️
crates/torii/core/src/sql/utils.rs 57.14% 3 Missing ⚠️
Additional details and impacted files
@@                 Coverage Diff                  @@
##             spr/main/5231a946    #2444   +/-   ##
====================================================
  Coverage                     ?   67.57%           
====================================================
  Files                        ?      370           
  Lines                        ?    48574           
  Branches                     ?        0           
====================================================
  Hits                         ?    32822           
  Misses                       ?    15752           
  Partials                     ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

- cleanup plus other refactor for the PR stack
- `start_block` configuration removed since it was no longer necessary now that we use `get_events` for `sync_range`
- use debug log level transfer events

commit-id:4acad5f3
@itzlambda
itzlambda merged commit bf9878a into spr/main/5231a946 Sep 24, 2024
@itzlambda
itzlambda deleted the spr/main/d618e874 branch September 24, 2024 14:20
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.

2 participants