Skip to content

Commit

Permalink
fix(api/parser): don't overwrite existing eol dates
Browse files Browse the repository at this point in the history
  • Loading branch information
c0rydoras committed Mar 25, 2024
1 parent 54ed485 commit 9ddca0e
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions api/outdated/outdated/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,15 @@ def _get_version(
minor_version=semver.minor,
)

if remote_name := next(
(
remote_name
for key, remote_name in settings.ENDOFLIFE_DATE_ASSOCIATIONS.items()
if search(compile(f"^{key}$"), dependency.name)
),
None,
if not release_version.end_of_life and (
remote_name := next(
(
remote_name
for key, remote_name in settings.ENDOFLIFE_DATE_ASSOCIATIONS.items()
if search(compile(f"^{key}$"), dependency.name)
),
None,
)
):
release_version.end_of_life = self._get_end_of_life_date(
remote_name, release_version
Expand Down

0 comments on commit 9ddca0e

Please sign in to comment.