Skip to content
This repository has been archived by the owner on Jan 11, 2024. It is now read-only.

New proposal logic #447

Merged
merged 9 commits into from
Nov 29, 2023
Merged

New proposal logic #447

merged 9 commits into from
Nov 29, 2023

Conversation

cryptoAtwill
Copy link
Contributor

Fix based on review feedbacks.

if let Some(final_proposal) = r {
// this is possible due to delayed execution as the proposed height's data cannot be
// executed because they have yet to be executed.
return if last_committed_height == final_proposal {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@adlrocha Please help review this check, it is possible under delayed execution.

Copy link
Contributor

@adlrocha adlrocha left a comment

Choose a reason for hiding this comment

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

@cryptoAtwill, do you mind also propagating here some of the changes from Akosh here (or actually merging it here). Like e.g. the changes of the infra script: https://github.com/consensus-shipyard/fendermint/pull/435/files#diff-b901e8f9e6284b4e07255572105751b3e7b79683ddea1ff19bc9b06d30426b01R40, or including the comments and the parameter into the config.

The same applies to the max_proposal_range.

for h in start..=end {
if let Some(Some(_)) = cache.get_value(h) {
return Ok(Some(h));
Ok(cache.lower_bound().and_then(|lower_bound| {
Copy link
Contributor

Choose a reason for hiding this comment

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

I assume here that if the cache doesn't have the height it will go to fetch it from the parent, right?


tracing::debug!(first_non_null_height, candidate_height);
// an extra layer of delay
let r =
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
let r =
let proposal_height =

@adlrocha adlrocha merged commit 5818bfa into remove-look-ahead Nov 29, 2023
3 of 5 checks passed
@adlrocha adlrocha deleted the new-proposal-logic branch November 29, 2023 17:26
maciejwitowski pushed a commit that referenced this pull request Nov 29, 2023
* remove look ahead in query topdown

* use three pointers

* up crate

* fix error

* Update fendermint/vm/topdown/src/sync/syncer.rs

Co-authored-by: Akosh Farkash <[email protected]>

* fix from integration testing

* remove to_confirm pointer

* restrict memory size

* dont propose until interval reached

* update latest height

* split tendermint query to separete file

* Update fendermint/vm/topdown/src/sync/syncer.rs

Co-authored-by: adlrocha <[email protected]>

* fix test linting

* fix tests

* more tests

* check hash when executing

* sync

* sort by nonce

* fmt

* more unit tests

* New proposal logic (#447)

* new proposal logic

* fmt

* fix typo

* minor changes

* adding check

* ignore proposal height

* Fix type

* expose config params

---------

Co-authored-by: Alfonso de la Rocha <[email protected]>

---------

Signed-off-by: Alfonso de la Rocha <[email protected]>
Co-authored-by: Akosh Farkash <[email protected]>
Co-authored-by: adlrocha <[email protected]>
Co-authored-by: Alfonso de la Rocha <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants