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

Use workspace metadata and deps #900

Merged
merged 6 commits into from
Feb 14, 2025
Merged

Conversation

jasl
Copy link
Contributor

@jasl jasl commented Feb 13, 2025

In this PR:

  • Extract common metadata fields to workspace Cargo.toml
  • Extract deps to workspace Cargo.toml

This PR shouldn't change any dependencies. Just move them to the workspace Cargo.toml

@jasl
Copy link
Contributor Author

jasl commented Feb 13, 2025

@bkchr
I don't know who the repo maintainer is. Could you help to review it?

Since polkadot-sdk still has not begun the deprecation process of rocksdb, what do you think about releasing a new version of kvdb-rocksdb?

Cargo.toml Outdated Show resolved Hide resolved
@jasl jasl changed the title Use workspace metadata and dpes, and upgrade rocksdb Use workspace metadata and deps Feb 14, 2025
Copy link
Member

@ordian ordian left a comment

Choose a reason for hiding this comment

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

Thanks!

@jasl
Copy link
Contributor Author

jasl commented Feb 14, 2025

@ordian Sorry, I made a mistake. Could you help re-trigger the CI?

Copy link
Member

@ordian ordian left a comment

Choose a reason for hiding this comment

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

hopefully last small changes and ready to go

Cargo.toml Outdated Show resolved Hide resolved
criterion = "0.5.1"
rand = { version = "0.8.0", default-features = false }
hex-literal = "0.4.1"
scale-info = { version = ">=1.0, <3", default-features = false }
Copy link
Member

Choose a reason for hiding this comment

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

this was >= 0.9, < 3, why did you change it? the reason we set it this way is to allow upsteam users to update scale-info without having to update crates in parity-common.

Copy link
Contributor Author

@jasl jasl Feb 14, 2025

Choose a reason for hiding this comment

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

Oh, this version range comes from https://github.com/paritytech/parity-common/pull/900/files#diff-c949d3988c105a100fde1d974b36302b74911bbb90efeb2581f94e6379a39ce5L20

I align with the highest one. Should I need to separate them?

Copy link
Member

Choose a reason for hiding this comment

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

ah, i see. ok, let's keep it >= 1.0, < 3. i think nobody should be using scale-info 0.9 at this point

Co-authored-by: ordian <[email protected]>
impl-codec = { workspace = true, optional = true }
impl-num-traits = { workspace = true, optional = true }
impl-rlp = { workspace = true, optional = true }
scale-info = { workspace = true, features = ["derive"], optional = true }
Copy link
Member

Choose a reason for hiding this comment

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

technically, renaming an optional dependency is a breaking change, because someone could have used scale-info-crate feature, but hopefully nobody did 🤞🏽

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 was struggling here. I should keep codes as is, but workspace dependency isn't flexible.
I had to add a scale-info-crate in the workspace, but I felt odd and changed the code.

@jasl
Copy link
Contributor Author

jasl commented Feb 14, 2025

CI has passed

BTW, the PR doesn't touch uint/fuzz, which has broken. I can fix it in a following PR

Should I add uint/fuzz to the workspace?

@ordian ordian requested a review from niklasad1 February 14, 2025 09:58
@ordian ordian enabled auto-merge (squash) February 14, 2025 09:58
Copy link
Member

@niklasad1 niklasad1 left a comment

Choose a reason for hiding this comment

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

nice 👍

@ordian ordian merged commit 7afa1ea into paritytech:master Feb 14, 2025
6 checks passed
@jasl jasl deleted the upgrade-deps branch February 14, 2025 13:41
@jasl
Copy link
Contributor Author

jasl commented Feb 14, 2025

I made three following PRs:

Thank you all for helping review my PR!

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.

4 participants