Skip to content

Commit

Permalink
Fix extensions.bzl to allow for multiple versions (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
filippobrizzi authored Dec 10, 2024
1 parent 51aff39 commit 0acf580
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion buf/extensions.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def _extension_impl(module_ctx):
for name, versions in registrations.items():
if len(versions) > 1:
# TODO: should be semver-aware, using MVS
selected = sorted(versions, reverse = True)[0]
selected = sorted(versions, key = lambda v: v["version"], reverse = True)[0]

# buildifier: disable=print
print("NOTE: buf toolchains {} has multiple versions {}, selected {}".format(name, versions, selected))
Expand Down

0 comments on commit 0acf580

Please sign in to comment.