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

NPE in FileParser for composer #5919

Closed
1 task done
leoamigood opened this issue Oct 18, 2022 · 5 comments
Closed
1 task done

NPE in FileParser for composer #5919

leoamigood opened this issue Oct 18, 2022 · 5 comments
Assignees
Labels
Batch How We Work: Feature. Outcome achieved within 1 iteration. Can live under an epic, or stand alone. good first issue L: php:composer Issues and code for Composer T: bug 🐞 Something isn't working

Comments

@leoamigood
Copy link

leoamigood commented Oct 18, 2022

Is there an existing issue for this?

  • I have searched the existing issues

Package ecosystem

composer

What you expected to see, versus what you actually saw

Looks like there is NPE in FileParser for composer code:

parsed_lockfile.fetch(key, []).find { |d| d["name"] == name }

undefined method `find' for nil:NilClass\n\n        
parsed_lockfile.fetch(key, []).find { |d| d[\"name\"] == name }\n

I get this error in this repo: https://github.com/JoshuaEstes/ServerTools

@leoamigood leoamigood added the T: bug 🐞 Something isn't working label Oct 18, 2022
@deivid-rodriguez deivid-rodriguez added the L: php:composer Issues and code for Composer label Oct 21, 2022
@jeffwidman
Copy link
Member

We should try to repro this using the dry-run script against that repo... if it doesn't reproduce, then close for the reasons outlined here:

@deivid-rodriguez
Copy link
Contributor

It seems to be indeed crashing, so let's keep open!

@abdulapopoola abdulapopoola added the Batch How We Work: Feature. Outcome achieved within 1 iteration. Can live under an epic, or stand alone. label Mar 14, 2024
@abdulapopoola
Copy link
Member

This will be picked up by @GarryHurleyJr

@GarryHurleyJr
Copy link
Contributor

added some defensive coding around nil for key file and lockfile. still have debugging code to remove.

@GarryHurleyJr
Copy link
Contributor

Code merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Batch How We Work: Feature. Outcome achieved within 1 iteration. Can live under an epic, or stand alone. good first issue L: php:composer Issues and code for Composer T: bug 🐞 Something isn't working
Projects
Archived in project
Development

No branches or pull requests

5 participants