-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Setting versions locally towards 2.0 release #4404
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but it seems that some versions are still missing.
node-template-runtime = { path = "runtime" } | ||
sp-runtime = { path = "../../primitives/runtime" } | ||
sc-basic-authority = { path = "../../client/basic-authorship"} | ||
sp-io = { version = "2.0.0", path = "../../primitives/io" } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why set versions as well as path? it's just redundant additional tedious data to maintain isn't it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately, defining the version is a requirement to publish on crates.io
. Cargo doesn't have any publish --all
and won't resolve path to figure out which version to use–in general its publishing helper for workspaces are pretty rudimentary. On the other side path
is obviously a lot easier and nicer for development.
Fortunately, because cargo uses semver this isn't much of a deal. We can just define version = "2.0.0"
and even if we bump the minor or patch version of that crate to make a new release, this doesn't need any update on this crate. Cargo just will figure out the best version on cargo update
(or cargo build
if first time). Our internal Cargo.lock
will also update without problems. This also allows us to do version updates more independently per crate, like updating network and consensus and apply the changes to the crates that follow without having to publish a breaking change on these, if those dependencies don't alter their externally perceived API.
Having both is the common way to stay sane, and is what we do in the libp2p workspace repo and common practice on other workspace repos, too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
* clean up cargo.toml syntax * bumping versions to 2.0 * bump networking to 0.8 * move consensus down to 0.8 * bump consensus pallets to 0.8.0, too * Upping babe and aura pallets * add remaining, missing version definitions * missed some
In order to allow to publish,
path
-dependencies must have a matching version specified, too. This PR attempts to make us ready for a 2.0 releasing to crates by :Cargo.toml
0.8.0
, inclpallet-aura
andpallet-babe
refs #4099