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

release-please failed: Cannot convert undefined or null to object (package-lock.json with lockfileVersion: 1) #2263

Open
caugner opened this issue Apr 8, 2024 · 1 comment
Assignees
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@caugner
Copy link

caugner commented Apr 8, 2024

Thanks for stopping by to let us know something could be better!

Please provide the following details.

Environment details

  • OS: Ubuntu 22.04 LTS (GitHub Public Runner)
  • Node.js version: 18.20
  • npm version: 10
  • release-please version: 4

Steps to reproduce

  1. Create a package-lock.json using lockFileVersion: 1 (see this example)
  2. Run release-please.

Expected

Error message:

Your `package-lock.json` uses lockFileVersion X, which is not supported by release-please.

Actual

Cannot convert undefined or null to object

See this action run.

Context

if (parsed.lockfileVersion === 2 || parsed.lockfileVersion === 3) {

@caugner caugner added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Apr 8, 2024
@kerruba-milkman
Copy link

+1, facing the same issue with package-lock.json having lockfileVedrsion == 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

3 participants