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

torii: validate events #1100

Merged
merged 1 commit into from
Oct 31, 2023
Merged

Conversation

notV4l
Copy link
Collaborator

@notV4l notV4l commented Oct 25, 2023

  • validate that events are emitted by world by checking event.keys.len()

@@ -17,6 +18,18 @@ where
{
fn event_key(&self) -> String;

fn validate(&self, event: &Event) -> bool {
Copy link
Contributor

Choose a reason for hiding this comment

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

Hmm I think we should enforce this in each event processor so it can be done in the context of a particular event. We might want to define more keys on the starknet events for more efficient querying over rpc

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

updated

@notV4l notV4l force-pushed the torii_validate_events branch from 2ef1013 to a0e9f85 Compare October 31, 2023 09:58
@tarrencev tarrencev merged commit f02b313 into dojoengine:main Oct 31, 2023
11 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.

2 participants