Skip to content

Conversation

chong-he
Copy link
Member

@chong-he chong-he commented Jun 4, 2025

Issue Addressed

Additional Info

Thank you @ethDreamer and @michaelsproul for the help and guidance

@chong-he chong-he added work-in-progress PR is a work-in-progress val-client Relates to the validator client binary UX-and-logs labels Jun 4, 2025
.await,
),
};

Copy link
Member

Choose a reason for hiding this comment

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

This is the wrong place to do this. This function will call produce_block_with_verification() which will call produce_block_on_state() which will call the graffiti_calculator.get_graffiti() again. I would suggest you pass this argument down the function calls along with the graffiti. So maybe (inside graffiti_calculator.rs) create some new enum:

enum GraffitiSettings {
    Unspecified,
    Specified {
        graffiti: Graffiti,
        policy: GraffitiPolicy,
    }
}

impl GraffitiSettings {
    fn new(validator_graffiti: Option<Graffiti>, policy: GraffitiPolicy) {
        validator_graffiti.map(|graffiti| Self::Specified {
            graffiti,
            policy,
        })
        .unwrap_or(Self::Unspecified)
    }
}

and pass that down through the functions. Then you'd want to change get_graffiti to:

pub async fn get_graffiti(&self, graffiti_settings: GraffitiSettings) -> Graffiti

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks so much for the comment, made some amendment based on your comment. If you have some time to spare, will appreciate for another look to see if this is on the right track @ethDreamer

@chong-he chong-he added ready-for-review The code is ready for review and removed work-in-progress PR is a work-in-progress labels Jun 30, 2025
@chong-he chong-he requested a review from ethDreamer June 30, 2025 07:40
@michaelsproul michaelsproul added the v8.0.0-rc.0 Q3 2025 release for Fusaka on Holesky label Jul 10, 2025
@jimmygchen jimmygchen added v8.0.0 Q4 2025 Fusaka Mainnet Release and removed v8.0.0-rc.0 Q3 2025 release for Fusaka on Holesky labels Sep 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-review The code is ready for review UX-and-logs v8.0.0 Q4 2025 Fusaka Mainnet Release val-client Relates to the validator client binary
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants