From 94bea5b7c54991991d9e1265d9a8940f2da66d13 Mon Sep 17 00:00:00 2001 From: Eric Arellano Date: Mon, 25 Oct 2021 14:44:50 -0700 Subject: [PATCH] [internal] Make explicit that we're redownloading Go modules multiple times # Rust tests and lints will be skipped. Delete if not intended. [ci skip-rust] # Building wheels and fs_util will be skipped. Delete if not intended. [ci skip-build-wheels] --- src/python/pants/backend/go/util_rules/go_mod.py | 2 ++ src/python/pants/backend/go/util_rules/sdk.py | 1 + src/python/pants/backend/go/util_rules/third_party_pkg.py | 2 ++ 3 files changed, 5 insertions(+) diff --git a/src/python/pants/backend/go/util_rules/go_mod.py b/src/python/pants/backend/go/util_rules/go_mod.py index b78c47305d18..1b2fbeceb632 100644 --- a/src/python/pants/backend/go/util_rules/go_mod.py +++ b/src/python/pants/backend/go/util_rules/go_mod.py @@ -105,6 +105,8 @@ async def determine_go_mod_info( input_digest=sources_digest, working_dir=go_mod_dir, description=f"List modules in {go_mod_path}", + # TODO: Fix this! + allow_downloads=True, ), ) diff --git a/src/python/pants/backend/go/util_rules/sdk.py b/src/python/pants/backend/go/util_rules/sdk.py index 82aad83857b7..680b6aaa54bf 100644 --- a/src/python/pants/backend/go/util_rules/sdk.py +++ b/src/python/pants/backend/go/util_rules/sdk.py @@ -96,6 +96,7 @@ async def setup_go_sdk_process( argv=[bash.path, go_sdk_run.script.path, *request.command], env={ GoSdkRunSetup.CHDIR_ENV: request.working_dir or "", + **request.env, }, input_digest=input_digest, description=request.description, diff --git a/src/python/pants/backend/go/util_rules/third_party_pkg.py b/src/python/pants/backend/go/util_rules/third_party_pkg.py index 3c3dc79b53f6..0364d13a3a19 100644 --- a/src/python/pants/backend/go/util_rules/third_party_pkg.py +++ b/src/python/pants/backend/go/util_rules/third_party_pkg.py @@ -277,6 +277,8 @@ async def compute_third_party_module_metadata( "Determine metadata for Go third-party module " f"{request.module_path}@{request.version}" ), + # TODO: Fix this! + allow_downloads=True, ), )