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

When vsce publish fails, version still gets bumped #187

Closed
idleberg opened this issue Jul 5, 2017 · 2 comments
Closed

When vsce publish fails, version still gets bumped #187

idleberg opened this issue Jul 5, 2017 · 2 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug help wanted Issues identified as good community contribution opportunities released
Milestone

Comments

@idleberg
Copy link

idleberg commented Jul 5, 2017

When running vsce publish <major|minor|patch> and something goes wrong, e.g. vscode:prepublish throwing an error, the version numbers still get bumped.

Example:

$ vsce publish major
Executing prepublish script 'npm run vscode:prepublish'...
Error: Command failed: npm run vscode:prepublish
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] vscode:prepublish: `tsc -p ./`
npm ERR! Exit status 1 

# after fixing the error
$ vsce publish major
Executing prepublish script 'npm run vscode:prepublish'...

>  [email protected] vscode:prepublish /path/to/my-package

Note that after the first publish command, the version gets bumped to 1.0.0. After fixing the error that caused prepublish script to exit, the version gets bumped to 2.0.0. The expected behaviour is to bump to 1.0.0, since it failed earlier.

I should also mention, that the version in package.json remains unchanged after the failed publish command.

@joaomoreno joaomoreno self-assigned this Jul 6, 2017
@joaomoreno joaomoreno added this to the Backlog milestone Jul 6, 2017
@TheColorRed
Copy link

It would be nice if an error occurs that vsce would rollback to the previous version. I pushed some code it was supposed to be 0.0.12, but it didn't work. By the time it worked it pushed as 0.0.14 and now my CHANGELOG.md is wrong.

@joaomoreno joaomoreno added bug Issue identified by VS Code Team member as probable bug help wanted Issues identified as good community contribution opportunities labels Sep 20, 2018
@joaomoreno joaomoreno removed their assignment Sep 20, 2018
jtaox added a commit to jtaox/vscode-vsce that referenced this issue Apr 20, 2019
@joaomoreno joaomoreno removed this from the Backlog milestone Oct 11, 2019
@joaomoreno joaomoreno self-assigned this Nov 2, 2021
@joaomoreno joaomoreno added this to the November 2021 milestone Nov 2, 2021
@github-actions
Copy link

github-actions bot commented Nov 2, 2021

🎉 This issue has been resolved in version 1.102.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue identified by VS Code Team member as probable bug help wanted Issues identified as good community contribution opportunities released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants