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

Add convenience method to replace a purl component #82

Open
pombredanne opened this issue Apr 10, 2022 · 1 comment
Open

Add convenience method to replace a purl component #82

pombredanne opened this issue Apr 10, 2022 · 1 comment

Comments

@pombredanne
Copy link
Member

The current implementation uses a namedtuple for PackageURL but this is an implementation detail that should be relied uppon. We should have a method to create a new purl from an existing purl passing new field values as arguments.

pombredanne added a commit to aboutcode-org/vulnerablecode that referenced this issue Apr 11, 2022
The fact this is a namedtuple is an implementation detail that should
not be relied upon.

* Add new evolve_purl() helper function to help with this

Reference: package-url/packageurl-python#82
Signed-off-by: Philippe Ombredanne <[email protected]>
pombredanne added a commit to aboutcode-org/vulnerablecode that referenced this issue Apr 11, 2022
The fact this is a namedtuple is an implementation detail that should
not be relied upon.

* Add new evolve_purl() helper function to help with this

Reference: package-url/packageurl-python#82
Signed-off-by: Philippe Ombredanne <[email protected]>
@tdruez
Copy link
Collaborator

tdruez commented Jun 27, 2022

See also #87 (comment)

@pombredanne what about implementing a new update() method on the PackageURL class re-using the code from your evolve_purl function?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants