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

refactor(toolshed): thegraph core types module code reorg #35

Merged
merged 1 commit into from
Nov 21, 2023

Conversation

LNSD
Copy link
Contributor

@LNSD LNSD commented Nov 21, 2023

This PR reorganizes the thegraph core types module to comply with the Rust codebase style.

  • Remove mod.rs in favor of thegraph.rs module index file as recommended in the Rust book.
  • Minor code refactorings and code improvements.
  • Extended the unit tests of the different submodules.

@LNSD LNSD requested a review from Theodus November 21, 2023 15:08
@LNSD LNSD self-assigned this Nov 21, 2023
Copy link
Member

@Theodus Theodus left a comment

Choose a reason for hiding this comment

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

LGTM

#[derive(
Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, SerializeDisplay, DeserializeFromStr,
)]
pub struct DeploymentId(pub B256);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I kept the visibility of the internal data public to avoid breaking changes. But, in my opinion, the internal representation should be opaque, i.e., non-public.

@LNSD LNSD merged commit 0fe719c into main Nov 21, 2023
5 checks passed
@LNSD LNSD deleted the refactor-toolshed-thegraph-core-types-module branch November 21, 2023 15:24
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