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

Create new cucumber package depending on @cucumber/cucumber #1440

Closed
aslakhellesoy opened this issue Sep 15, 2020 · 9 comments
Closed

Create new cucumber package depending on @cucumber/cucumber #1440

aslakhellesoy opened this issue Sep 15, 2020 · 9 comments
Labels
🔧 build Related to build / release process

Comments

@aslakhellesoy
Copy link
Contributor

This is to make sure people who rely on dependabot, renovate and the like get notifications about the new version.

It should have a post-install message encouraging people to change to @cucumber/cucumber

We should release this for every 7 RC, as well as the first final 7.

@aslakhellesoy aslakhellesoy added the 🔧 build Related to build / release process label Sep 15, 2020
@davidjgoss
Copy link
Contributor

I guess the downside of this is that if users installed it, they'd have to change their support code to import from the new package, and their IDE/linter may then get mad at them for importing something that's not a direct dependency.

An alternative might be to release a 6.0.6 or 6.1.0 (for dependabot and friends to still kick in) and then npm deprecate it with a message pointing to a blog post or similar. I think I've seen this done before.

Don't feel strongly though!

@aslakhellesoy
Copy link
Contributor Author

aslakhellesoy commented Sep 16, 2020

Oh I wasn't aware of the deprecate feature. Yes, that would be better. I'm not sure what we could possibly release though. Maybe just a 6.0.6 patch release that only adds a deprecation warning?

That sounds better. Suggested message:

You are using a deprecated version of cucumber. Please upgrade to @cucumber/cucumber
which has support for rules and report publishing.

Migration guide:
- npm uninstall cucumber
- npm install --save-dev @cucumber/cucumber
- require/import @cucumber/cucumber instead of cucumber
- TypeScript
  - Replace TableDefinition with DataTable
  - npm uninstall @types/cucumber

Please let us know if you have any problems upgrading so we can
improve the migration guide. Submit an issue to 
https://github.com/cucumber/cucumber-js/issues

@aslakhellesoy
Copy link
Contributor Author

I am updating the migration guide in CHANGELOG.md

@davidjgoss
Copy link
Contributor

Message LGTM. We could show at runtime as well similar to how we now do with the publish banner?

@aslakhellesoy
Copy link
Contributor Author

I think as a post-installation message is sufficient. Gotta be careful not to be too noisy!

@aslakhellesoy
Copy link
Contributor Author

@davidjgoss @charlierudolph how about something like this? https://github.com/cucumber/cucumber-js-package-upgrade/

It prints the README in the console (with some highlighting) after installation, but also at runtime. It's a bit noisy, but I think that's ok since it is a major version they will only stay at for a short moment.

I think this needs to be a major release. Releasing it as 6.0.3 or 6.1.0 would break semver as it is not backwards compatible. With 7.0.0 they will at least expect breakages.

@aslakhellesoy
Copy link
Contributor Author

I've installed this as a "cucumber": "cucumber/cucumber-js-package-upgrade" dependency in a project and it seems to work fine:

  • require "cucumber" works as in 6.0
  • I see the post-install and runtime warning to upgrade to @cucumber/cucumber
  • I see the publish banner
  • No other changes were necessary (this wasn't a TypeScript project)

I'll go ahead and release this so people on cucumber get upgrade notifications.

@aslakhellesoy
Copy link
Contributor Author

Done! https://www.npmjs.com/package/cucumber/v/7.0.0-rc.0

Let's release another one when we make 7.0.0 final (as well as any RC releases in-between). The release process is the same as for cucumber-js.

@aslakhellesoy
Copy link
Contributor Author

I've deprecated it too:

npm deprecate cucumber@7.0.0-rc.0 "The npm package has moved to @cucumber/cucumber"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔧 build Related to build / release process
Projects
None yet
Development

No branches or pull requests

2 participants