vulnerablecode
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)
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 @pombredanne .. is this issue open for contribution ?
Hi @Hritik14 and @pombredanne, can I work on this issue, or has it already been solved?
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
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