Skip to content

Commit

Permalink
Review feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
KyleFromNVIDIA committed May 30, 2024
1 parent 405b042 commit 632b3c0
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/rapids_pre_commit_hooks/alpha_spec.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,12 @@ def create_specifier_string(specifiers):
if req.name in RAPIDS_ALPHA_SPEC_PACKAGES or is_rapids_cuda_suffixed_package(
req.name
):
anchor = (
keys[0]
if (keys := [key for key, value in anchors.items() if value == node])
else None
)
for key, value in anchors.items():
if value == node:
anchor = key
break
else:
anchor = None
if anchor not in used_anchors:
if anchor is not None:
used_anchors.add(anchor)
Expand Down

0 comments on commit 632b3c0

Please sign in to comment.