Skip to content

fix: Package.get_purldb_entries() built a purl payload but placed it#554

Open
singlaamitesh wants to merge 1 commit into
aboutcode-org:mainfrom
singlaamitesh:fix/462-dejacode-462
Open

fix: Package.get_purldb_entries() built a purl payload but placed it#554
singlaamitesh wants to merge 1 commit into
aboutcode-org:mainfrom
singlaamitesh:fix/462-dejacode-462

Conversation

@singlaamitesh

Copy link
Copy Markdown

Fixes #462

Summary

Package.get_purldb_entries() built a purl payload but placed it last in the request list, so the synchronous PurlDB tab view (which calls it with max_request_call=1) stopped after only trying hash/download_url and never attempted the purl match — even though update_from_purldb (used by 'Improve Packages from PurlDB') has no such limit and succeeds. Restructured the method to always try the purl payload as a final fallback regardless of max_request_call, since it's the broadest/cheapest match.

Changes

  • component_catalog/models.py
  • component_catalog/tests/test_models.py

How this was tested

Ran the affected tests locally.

Copilot AI review requested due to automatic review settings July 15, 2026 06:23

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

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

Successfully merging this pull request may close these issues.

BUG: Go package mapping fails

2 participants