Skip to content

chore(code): Move mode check for effect handling in engine#942

Closed
ancazamfir wants to merge 13 commits intomainfrom
anca/engine_effect_handling
Closed

chore(code): Move mode check for effect handling in engine#942
ancazamfir wants to merge 13 commits intomainfrom
anca/engine_effect_handling

Conversation

@ancazamfir
Copy link
Copy Markdown
Contributor

Closes: #XXX


PR author checklist

For all contributors

For external contributors

@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 0.00%. Comparing base (5fb4820) to head (23c5a2b).
Report is 2 commits behind head on main.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@     Coverage Diff     @@
##   main   #942   +/-   ##
===========================
===========================

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

@ancazamfir ancazamfir changed the title chore(code): Move mode check on effect handling in engine chore(code): Move mode check for effect handling in engine Mar 25, 2025
@ancazamfir ancazamfir marked this pull request as ready for review March 25, 2025 16:08
@ancazamfir ancazamfir requested a review from romac as a code owner March 25, 2025 16:08
Comment thread code/crates/engine/src/consensus.rs Outdated
Comment thread code/crates/engine/src/consensus.rs Outdated
Comment on lines +957 to +960
let should_broadcast = match &msg {
SignedConsensusMsg::Vote(_) => true,
_ => value_payload.include_proposal(),
};
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.

Let's refactor this into a function that we can use here and for the WAL below

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I think for the WAL we will have to remove the check when we fix #897. So we have three options

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 28, 2025

✅ Semver Check Passed

Great job! All semver violations have been resolved. This PR now complies with semantic versioning rules.

If you made version updates, please ensure that:

  • The version in Cargo.toml accurately reflects the nature of your changes
  • Any breaking changes are properly documented in BREAKING_CHANGES.md

@romac
Copy link
Copy Markdown
Contributor

romac commented Jul 22, 2025

I think this approach puts too much burden on users integrating at the core-consensus level, and we should postpone this until we have a higher-level wrapper around the core-consensus API. What do you think @ancazamfir?

@ancazamfir
Copy link
Copy Markdown
Contributor Author

I think this approach puts too much burden on users integrating at the core-consensus level, and we should postpone this until we have a higher-level wrapper around the core-consensus API. What do you think @ancazamfir?

We should clarify with the integrators if this is the case. Having less Effects to implement is good but it comes at a cost of integrators having to verify all sigs before sending messages to core. But I assume core API integrators will look at the engine and see what they need to do.

For me the bigger concern is that here we do the expensive checks early, for example before we verify that messages are for lower heights and discard. For that reason I would also move some of the checks in the engine...and then yes it's extra work on integration that need to be done and a wrapper would be good.

@ancazamfir
Copy link
Copy Markdown
Contributor Author

Let's close this until we have a way to verify signatures for future heights in the engine, or we decide to optimistically verify with current height validator set.

@ancazamfir ancazamfir closed this Feb 2, 2026
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