gofractally / psibase

Open source protocol enabling communities to easily self-host web applications
https://docs.psibase.io
MIT License
26 stars 6 forks source link

Cargo-psibase version management #730

Open James-Mart opened 1 month ago

James-Mart commented 1 month ago

Since cargo-psibase doesn't show up as a dependency in any cargo.toml, but psibase itself does (I think it's a dependency of every service, test, and plugin), it is going to be easy for them to get out of sync. This could cause non-obvious build errors.

What is the right way to ensure that the version of cargo-psibase stays up-to-date?

Option 1: When cargo-psibase is building a service/test, it can check the version of psibase depended upon in that project's cargo.toml. Compare that version number with its own version. If its own version is != the version of psibase that the project is using... show a warning to the developer that there's a version mismatch.

Any other ideas?

swatanabe commented 1 month ago

Do we want to compare against the version in Cargo.toml or the version in the lockfile?