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

packaging: remove semver tags from package versions #388

Merged
merged 2 commits into from
Sep 16, 2024

Conversation

CedarMist
Copy link
Member

@CedarMist CedarMist commented Sep 10, 2024

So, need to re-release packages to get versioning working correctly.

So, we're going to archive:

  • @oasisprotocol/sapphire-paratime v2.0.0-alpha.0 on the latest tag
  • @oasisprotocol/sapphire-paratime v2.0.0-next.3 on the next tag

Then release @oasisprotocol/sapphire-paratime v2.0.0 on the next tag

The sapphire-viem-v2, sapphire-ethers-v6, sapphire-hardhat and sapphire-wagmi-v2 packages will be published on their own latest tags.

Meaning people who npm install @oasisprotocol/sapphire-paratime will get v1.x by default, but if you install @oasisprotocol/sapphire-ethers-v6 you'll get @oasisprotocol/sapphire-paratime v2 as a dependency.

This means we'll be tagging clients/js/v2.0.0-next (to publish to the next dist-tag on NPMJS), but integrations/ethers-v6/v6.0.0 (to publish to latest).

Version resolution for dependencies on package.json will ignore the dist-tags, but adhere to any semver rules.

@CedarMist CedarMist added javascript Pull requests that update JavaScript code packaging labels Sep 10, 2024
@CedarMist CedarMist self-assigned this Sep 10, 2024
@CedarMist CedarMist requested a review from aefhm September 10, 2024 11:12
@CedarMist CedarMist marked this pull request as ready for review September 10, 2024 11:12
Copy link

netlify bot commented Sep 10, 2024

Deploy Preview for oasisprotocol-sapphire-paratime canceled.

Name Link
🔨 Latest commit 6ea04d7
🔍 Latest deploy log https://app.netlify.com/sites/oasisprotocol-sapphire-paratime/deploys/66e6094c994b0a00087665c8

@CedarMist CedarMist requested a review from matevz September 10, 2024 12:07
@CedarMist
Copy link
Member Author

So quick point of thought, currently sapphire-hardhat is 2.22.2-next.0

If I do pnpm upgrade and v2.22.2 is in the next dist-tag, this will upgrade to that version, but if -next is used as a semver tag it won't.

So, I think we should keep sapphire-hardhat semver tag as next, and release on dist-tag next.

@CedarMist CedarMist force-pushed the CedarMist/package-versioning-v2 branch from 96c1479 to 2242de7 Compare September 10, 2024 13:51
@aefhm
Copy link
Contributor

aefhm commented Sep 10, 2024

If I do pnpm upgrade and v2.22.2 is in the next dist-tag, this will upgrade to that version, but if -next is used as a semver tag it won't.

Isn't this the desired behavior? 🤔

So, I think we should keep sapphire-hardhat semver tag as next, and release on dist-tag next.

Just checking, you are suggesting we keep it on -next?

@aefhm aefhm added the client label Sep 12, 2024
@CedarMist CedarMist force-pushed the CedarMist/package-versioning-v2 branch from 2242de7 to b938516 Compare September 14, 2024 13:59
@CedarMist
Copy link
Member Author

CedarMist commented Sep 14, 2024

Release checklist:

  • tag clients/js/v2.0.0-next to release @oasisprotocol/sapphire-paratime on next channel
    • git tag clients/js/v2.0.0-next
    • git push origin clients/js/v2.0.0-next
  • deprecate previous sapphire-paratime v2.x semver pre-releases in favor of next channel
    • npm deprecate '@oasisprotocol/sapphire-paratime@2.0.0-alpha.0' "Please use @oasisprotocol/sapphire-paratime@next"
    • npm deprecate '@oasisprotocol/sapphire-paratime@2.0.0-next.3' "Please use @oasisprotocol/sapphire-paratime@next"
    • npm dist-tag add '@oasisprotocol/sapphire-paratime@1.3.2' 'latest'
  • tag integrations/viem-v2/v2.0.1 to release @oasisprotocol/sapphire-viem-v2 on latest channel
    • git tag integrations/viem-v2/v2.0.1
    • git push origin integrations/viem-v2/v2.0.1
  • Deprecate the previous two sapphire-viem-v2 packages with semver tags, people will install from the latest channel
    • npm deprecate '@oasisprotocol/sapphire-viem-v2@2.0.0-next.1' "Please use @oasisprotocol/sapphire-viem-v2 (without -next.1)"
    • npm deprecate '@oasisprotocol/sapphire-viem-v2@2.0.0-alpha.0' "Please use @oasisprotocol/sapphire-viem-v2 (without -alpha.0)"
  • tag integrations/wagmi-v2/v2.0.0 to release @oasisprotocol/sapphire-wagmi-v2 on latest channel
    • git tag integrations/wagmi-v2/v2.0.0
    • git push origin integrations/wagmi-v2/v2.0.0
  • Deprecate @oasisprotocol/sapphire-wagmi-v2 2.0.0-next.1
    • npm deprecate '@oasisprotocol/sapphire-wagmi-v2@2.0.0-next.1' "Please use @oasisprotocol/sapphire-wagmi-v2 (without -next.1)"
  • tag integrations/ethers-v6/v6.0.0 to release @oasisprotocol/sapphire-ethers-v6 on latest channel
    • git tag integrations/ethers-v6/v6.0.0
    • git push origin integrations/ethers-v6/v6.0.0
  • Deprecate the previous two versions of sapphire-ethers-v6 packages with semver tags, people will install from the latest channel
    • npm deprecate '@oasisprotocol/sapphire-ethers-v6@6.0.0-next.1' "Please use @oasisprotocol/sapphire-ethers-v6 (without -next.1)"
    • npm deprecate '@oasisprotocol/sapphire-ethers-v6@6.0.0-alpha.0' "Please use @oasisprotocol/sapphire-ethers-v6 (without -alpha.0)"
  • tag integrations/hardhat/v2.22.2-next to release @oasisprotocol/sapphire-hardhat on next channel, depending on @oasisprotocol/sapphire-paratime without the semver tag.
    • git tag integrations/hardhat/v2.22.2-next
    • git push origin integrations/hardhat/v2.22.2-next

Have skipped these as unnecessary

  • deprecate @oasisprotocol/sapphire-hardhat/2.22.2-next.0
    • npm deprecate '@oasisprotocol/sapphire-hardhat@2.22.2-next.0' "Please use @oasisprotocol/sapphire-hardhat (without -next.0)"

@CedarMist CedarMist merged commit f33604e into main Sep 16, 2024
10 checks passed
@CedarMist CedarMist deleted the CedarMist/package-versioning-v2 branch September 16, 2024 00:23
github-actions bot added a commit that referenced this pull request Sep 16, 2024
…edarMist/package-versioning-v2

packaging: remove semver tags from package versions f33604e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
client javascript Pull requests that update JavaScript code packaging
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants