Skip to content

Commit

Permalink
Use a set when calculating resolve names (pantsbuild#18939)
Browse files Browse the repository at this point in the history
I saw errors with duplicates, so using a `set` (which is OK since this
gets `sorted`) to stop that.
  • Loading branch information
thejcannon authored May 8, 2023
1 parent 7e6728e commit de48a69
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/python/pants/core/goals/export.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,13 +177,13 @@ async def export(
for request in union_membership.get(KnownUserResolveNamesRequest)
)
all_valid_resolve_names = sorted(
[
{
*itertools.chain.from_iterable(kurn.names for kurn in all_known_user_resolve_names),
*(
sentinel.resolve_name
for sentinel in union_membership.get(GenerateToolLockfileSentinel)
),
]
}
)
raise UnrecognizedResolveNamesError(
unexported_resolves,
Expand Down

0 comments on commit de48a69

Please sign in to comment.