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(Torii-core): Handle entity deletion events #1439

Merged
merged 18 commits into from
Jan 25, 2024

Conversation

gianalarcon
Copy link
Contributor

@gianalarcon gianalarcon commented Jan 15, 2024

  • Implement processor to handle StoreDelRecord events that are generated from the world.
  • Implement fn process() for StoreDelRecordProcessor
  • Implement fn build_delete_entity_queries_recursive() on fn delete_entity()
  • Improve current model_test
  • Implement delete tests

Closes #1349

@broody

Copy link
Collaborator

@broody broody left a comment

Choose a reason for hiding this comment

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

Recursive model deletion looking good, just some minor comments on testing

crates/torii/graphql/src/tests/mod.rs Outdated Show resolved Hide resolved
crates/torii/types-test/src/contracts.cairo Show resolved Hide resolved
crates/torii/types-test/src/contracts.cairo Show resolved Hide resolved
@gianalarcon gianalarcon marked this pull request as ready for review January 24, 2024 18:10
@gianalarcon gianalarcon changed the title WIP, Feat(Torii-core): Handle entity deletion events Feat(Torii-core): Handle entity deletion events Jan 24, 2024
Copy link

codecov bot commented Jan 24, 2024

Codecov Report

Attention: 15 lines in your changes are missing coverage. Please review.

Comparison is base (7527fcd) 69.40% compared to head (ec1ceb0) 69.45%.

Files Patch % Lines
...ates/torii/core/src/processors/store_del_record.rs 78.78% 7 Missing ⚠️
crates/torii/core/src/sql.rs 79.41% 7 Missing ⚠️
bin/torii/src/main.rs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1439      +/-   ##
==========================================
+ Coverage   69.40%   69.45%   +0.04%     
==========================================
  Files         228      229       +1     
  Lines       22138    22203      +65     
==========================================
+ Hits        15364    15420      +56     
- Misses       6774     6783       +9     

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

Copy link
Collaborator

@broody broody left a comment

Choose a reason for hiding this comment

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

Just one more debug print remove and it LGTM

crates/torii/core/src/processors/store_del_record.rs Outdated Show resolved Hide resolved
@tarrencev tarrencev merged commit 68e2199 into dojoengine:main Jan 25, 2024
12 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.

[Torii-core] Handle entity deletion events properly
3 participants