Skip to content

Commit

Permalink
Strip archive query strings in bcr_validation.py (#2261)
Browse files Browse the repository at this point in the history
Strips query strings from the source archive of a module to support
modules hosted in GCS buckets.
  • Loading branch information
armandomontanez authored Jun 14, 2024
1 parent 3a9a6a2 commit 1344458
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/bcr_validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ def verify_module_dot_bazel(self, module_name, version):
source = self.registry.get_source(module_name, version)
source_url = source["url"]
tmp_dir = Path(tempfile.mkdtemp())
archive_file = tmp_dir.joinpath(source_url.split("/")[-1])
archive_file = tmp_dir.joinpath(source_url.split("/")[-1].split("?")[0])
output_dir = tmp_dir.joinpath("source_root")
download_file(source_url, archive_file)
shutil.unpack_archive(str(archive_file), output_dir)
Expand Down

0 comments on commit 1344458

Please sign in to comment.