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

Move cryptographic hashing procedures to crypto folder. #2306

Merged
merged 18 commits into from
Jan 23, 2024

Conversation

davxy
Copy link
Member

@davxy davxy commented Nov 14, 2023

Step towards #1975

As reported #1975 (comment) I'd like to encapsulate crypto related stuff in a dedicated folder.

Currently all cryptographic primitive wrappers are all sparsed in substrate/core which contains "misc core" stuff.

To simplify the process, as the first step with this PR I propose to move the cryptographic hashing there.

The substrate/crypto folder was already created to contains ec-utils crate.

Notes:

  • rename sp-core-hashing to sp-crypto-hashing
  • rename sp-core-hashing-proc-macro to sp-crypto-hashing-proc-macro
  • As the crates name is changed I took the freedom to restart fresh from version 0.1.0 for both crates

Deprecation

sp-core-hashing and sp-core-hashing-proc-pacro were moved to substrate/deprecated folder with removal scheduled to Jun 2024

@davxy davxy requested review from a team November 14, 2023 09:19
@davxy davxy self-assigned this Nov 14, 2023
@davxy davxy added the T0-node This PR/Issue is related to the topic “node”. label Nov 14, 2023
@davxy davxy requested a review from a team November 14, 2023 10:07
Copy link
Contributor

@lexnv lexnv left a comment

Choose a reason for hiding this comment

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

LGTM!

Is there a plan to handle older crates published on crates.io? Such developers know to which crates to migrate 🤔

For example, sp-core-hashing and others could be republished with an empty source code and the readme redirecting at the new ones on crates.io

@davxy davxy requested a review from liamaharon November 23, 2023 15:31
@paritytech paritytech deleted a comment from paritytech-cicd-pr Nov 24, 2023
Copy link
Contributor

@michalkucharczyk michalkucharczyk left a comment

Choose a reason for hiding this comment

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

LGTM, some nits only.

substrate/deprecated/hashing/src/lib.rs Show resolved Hide resolved
substrate/primitives/consensus/beefy/Cargo.toml Outdated Show resolved Hide resolved
substrate/primitives/core/src/ecdsa.rs Show resolved Hide resolved
substrate/primitives/core/src/lib.rs Outdated Show resolved Hide resolved
@michalkucharczyk michalkucharczyk requested a review from a team November 24, 2023 12:17
@bkchr
Copy link
Member

bkchr commented Jan 20, 2024

@davxy maybe you could update the pr.

@paritytech-review-bot paritytech-review-bot bot requested a review from a team January 22, 2024 08:15
@paritytech-review-bot paritytech-review-bot bot requested a review from a team January 22, 2024 12:05
@paritytech paritytech deleted a comment from paritytech-cicd-pr Jan 22, 2024
@davxy davxy added the R0-silent Changes should not be mentioned in any release notes label Jan 22, 2024
@davxy davxy requested review from ggwpez and bkchr January 22, 2024 12:36
Copy link
Contributor

@Lederstrumpf Lederstrumpf left a comment

Choose a reason for hiding this comment

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

lgtm, just trivial nits (fine to ignore)

substrate/primitives/core/src/lib.rs Show resolved Hide resolved
substrate/primitives/keystore/src/testing.rs Outdated Show resolved Hide resolved
davxy and others added 2 commits January 22, 2024 14:32
Co-authored-by: Robert Hambrock <roberthambrock@gmail.com>
@davxy davxy enabled auto-merge January 22, 2024 17:28
@davxy davxy added this pull request to the merge queue Jan 22, 2024
Merged via the queue into paritytech:master with commit 4c10fd2 Jan 23, 2024
125 checks passed
@davxy davxy deleted the davxy-crypto-overhaul branch January 23, 2024 00:20
bgallois pushed a commit to duniter/duniter-polkadot-sdk that referenced this pull request Mar 25, 2024
)

Step towards paritytech#1975

As reported
paritytech#1975 (comment)
I'd like to encapsulate crypto related stuff in a dedicated folder.

Currently all cryptographic primitive wrappers are all sparsed in
`substrate/core` which contains "misc core" stuff.

To simplify the process, as the first step with this PR I propose to
move the cryptographic hashing there.

The `substrate/crypto` folder was already created to contains `ec-utils`
crate.

Notes:
- rename `sp-core-hashing` to `sp-crypto-hashing`
- rename `sp-core-hashing-proc-macro` to `sp-crypto-hashing-proc-macro`
- As the crates name is changed I took the freedom to restart fresh from
version 0.1.0 for both crates

---------

Co-authored-by: Robert Hambrock <roberthambrock@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
R0-silent Changes should not be mentioned in any release notes T0-node This PR/Issue is related to the topic “node”.
Projects
Status: done
Development

Successfully merging this pull request may close these issues.

6 participants