vulnerablecode icon indicating copy to clipboard operation
vulnerablecode copied to clipboard

The query for affected and fixed packages should be abstracted as methods on the models (and/or on a model manager)

Open Hritik14 opened this issue 3 years ago • 2 comments

The query for affected and fixed packages should be abstracted as methods on the models (and/or on a model manager)

Originally posted by @pombredanne in https://github.com/nexB/vulnerablecode/pull/525#discussion_r791658135

Currently we query for affected and fixed packages as: https://github.com/nexB/vulnerablecode/blob/67fc00e5a8dbdf690f1c1b0d627da0d06322adb9/vulnerabilities/views.py#L81-L87

This needs to be abstracted as model methods.

Related:

  • https://github.com/nexB/vulnerablecode/issues/596

Hritik14 avatar Jan 25 '22 20:01 Hritik14

@Hritik14 @pombredanne .. is this issue open for contribution ?

remote007 avatar Feb 24 '23 09:02 remote007

Hi @Hritik14 and @pombredanne, can I work on this issue, or has it already been solved?

poju3185 avatar Mar 13 '24 22:03 poju3185

We now have these at least in https://github.com/nexB/vulnerablecode/blob/457f8f8ce8550502714d3f19d914c5ab2409c935/vulnerabilities/models.py#L651-L670

  • affected_by
  • fixing

Closing this now. Note that we still need to rework the models as described in https://github.com/nexB/vulnerablecode/issues/966

pombredanne avatar Aug 13 '24 12:08 pombredanne

We now have these at least in https://github.com/nexB/vulnerablecode/blob/457f8f8ce8550502714d3f19d914c5ab2409c935/vulnerabilities/models.py#L651-L670

  • affected_by
  • fixing

Closing this now. Note that we still need to rework the models as described in https://github.com/nexB/vulnerablecode/issues/966

pombredanne avatar Aug 13 '24 12:08 pombredanne