Revert GCS fetch strategy, to remove s3 interface (#28736)
This commit reverts the GCS fetch strategy to before commit:
d759612523
The previous commit added some s3 syntax to handle connections, but
added them into the GCS fetch strategy in a way that prevents GCS from
working anymore.
This commit is contained in:
parent
b13629062a
commit
06fd0f892e
@ -1437,13 +1437,7 @@ def fetch(self):
|
||||
basename = os.path.basename(parsed_url.path)
|
||||
|
||||
with working_dir(self.stage.path):
|
||||
import spack.util.s3 as s3_util
|
||||
s3 = s3_util.create_s3_session(self.url,
|
||||
connection=s3_util.get_mirror_connection(parsed_url), url_type="fetch") # noqa: E501
|
||||
|
||||
headers = s3.get_object(Bucket=parsed_url.netloc,
|
||||
Key=parsed_url.path.lstrip("/"))
|
||||
stream = headers["Body"]
|
||||
_, headers, stream = web_util.read_from_url(self.url)
|
||||
|
||||
with open(basename, 'wb') as f:
|
||||
shutil.copyfileobj(stream, f)
|
||||
|
Loading…
Reference in New Issue
Block a user