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

fix(torii): ensure torii doesn't stop on model processor fail #2093

Merged
merged 5 commits into from
Jun 26, 2024

Conversation

glihm
Copy link
Collaborator

@glihm glihm commented Jun 20, 2024

Description

When a model that is not registered is emitted in an event, which can be done simply by calling world.set_entity with wrong data.

This causes Torii to fail and be taken in an infinite loop.

Related issue

Closes #1794.

Tests

Test will be done in #1679.

Added to documentation?

  • README.md
  • Dojo Book
  • No documentation needed

Checklist

  • I've formatted my code (scripts/prettier.sh, scripts/rust_fmt.sh, scripts/cairo_fmt.sh)
  • I've linted my code (scripts/clippy.sh, scripts/docs.sh)
  • I've commented my code
  • I've requested a review after addressing the comments

@glihm glihm changed the title fix: ensure torii does not stop on fail process fix(torii): ensure torii does not stop on fail process Jun 20, 2024
@glihm glihm requested a review from Larkooo June 20, 2024 21:04
@glihm glihm changed the title fix(torii): ensure torii does not stop on fail process fix(torii): ensure torii does not stop on processor fail Jun 20, 2024
@glihm glihm requested a review from tarrencev June 21, 2024 05:18
Copy link

codecov bot commented Jun 25, 2024

Codecov Report

Attention: Patch coverage is 62.50000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 68.50%. Comparing base (e87118d) to head (0710ce3).

Files Patch % Lines
crates/torii/core/src/engine.rs 60.00% 2 Missing ⚠️
crates/torii/core/src/sql.rs 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2093      +/-   ##
==========================================
- Coverage   68.50%   68.50%   -0.01%     
==========================================
  Files         331      331              
  Lines       41280    41283       +3     
==========================================
+ Hits        28278    28279       +1     
- Misses      13002    13004       +2     

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

@glihm glihm changed the title fix(torii): ensure torii does not stop on processor fail fix(torii): ensure torii doesn't stop on model processor fail Jun 25, 2024
@glihm glihm merged commit badeeba into dojoengine:main Jun 26, 2024
14 of 15 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.

Loop fail when using unregistered model
3 participants