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

Start pruning content out of the penumbra-chain crate #3474

Merged
merged 2 commits into from
Dec 5, 2023

Conversation

hdevalence
Copy link
Member

This is a catch-all crate at the bottom of the component dependency tree, and it'd be clearer to get rid of it and move the code into places where it belongs.

@hdevalence hdevalence changed the title [WIP]: remove penumbra-chain crate Start pruning content out of the penumbra-chain crate Dec 5, 2023
@hdevalence
Copy link
Member Author

This is a reasonable start and doesn't depend on further changes.

Comment on lines +17 to +18
pub raw_amount: Amount,
pub raw_denom: String,
Copy link
Member Author

Choose a reason for hiding this comment

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

I changed these to raw_ to reflect that they might be in units that need adjustment. This is not a great pattern -- we should avoid using Amount for anything other than an amount of the base denom -- but it's probably okay here because it's only for the genesis data, which has to be trusted anyways.

@@ -918,12 +919,15 @@ impl<T: StateWrite + StateWriteExt + ?Sized> StakingImpl for T {}

#[async_trait]
impl Component for Staking {
type AppState = GenesisContent;
type AppState = (GenesisContent, ShieldedPoolGenesisContent);
Copy link
Member Author

Choose a reason for hiding this comment

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

In this way, components can reference other components' genesis data.

@hdevalence hdevalence merged commit d84cdaa into main Dec 5, 2023
7 checks passed
@hdevalence hdevalence deleted the remove-chain-crate branch December 5, 2023 17:41
conorsch added a commit that referenced this pull request Dec 6, 2023
Follow up to #3474, to
satisfy buf linting CI check.
conorsch added a commit that referenced this pull request Dec 6, 2023
Follow up to #3474, to
satisfy buf linting CI check.
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.

1 participant