diff options
author | Peter Josef Scheibel <scheibel1@llnl.gov> | 2019-11-27 14:04:45 -0800 |
---|---|---|
committer | Massimiliano Culpo <massimiliano.culpo@gmail.com> | 2019-12-13 08:38:50 +0100 |
commit | 8c2305e86714f61da1a5415e8cd1831b75ab2f14 (patch) | |
tree | 5fd2ea0041f77d12ada09548ba5a5f35aae86c15 /lib | |
parent | 8199f22e7c31c6f9e2c70ac7e45a6d98414a5310 (diff) | |
download | spack-8c2305e86714f61da1a5415e8cd1831b75ab2f14.tar.gz spack-8c2305e86714f61da1a5415e8cd1831b75ab2f14.tar.bz2 spack-8c2305e86714f61da1a5415e8cd1831b75ab2f14.tar.xz spack-8c2305e86714f61da1a5415e8cd1831b75ab2f14.zip |
Patch fetching: remove unnecessary argument
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/package.py | 2 | ||||
-rw-r--r-- | lib/spack/spack/patch.py | 8 | ||||
-rw-r--r-- | lib/spack/spack/test/patch.py | 2 |
3 files changed, 4 insertions, 8 deletions
diff --git a/lib/spack/spack/package.py b/lib/spack/spack/package.py index 38631c7a0e..26335ed2ff 100644 --- a/lib/spack/spack/package.py +++ b/lib/spack/spack/package.py @@ -1086,7 +1086,7 @@ class PackageBase(with_metaclass(PackageMeta, PackageViewMixin, object)): self.stage.cache_local() for patch in self.spec.patches: - patch.fetch(self.stage) + patch.fetch() if patch.cache(): patch.cache().cache_local() diff --git a/lib/spack/spack/patch.py b/lib/spack/spack/patch.py index 9e29dcc638..73fdf4df25 100644 --- a/lib/spack/spack/patch.py +++ b/lib/spack/spack/patch.py @@ -64,11 +64,8 @@ class Patch(object): self.level = level self.working_dir = working_dir - def fetch(self, stage): + def fetch(self): """Fetch the patch in case of a UrlPatch - - Args: - stage: stage for the package that needs to be patched """ def clean(self): @@ -185,8 +182,7 @@ class UrlPatch(Patch): if not self.sha256: raise PatchDirectiveError("URL patches require a sha256 checksum") - # TODO: this function doesn't use the stage arg - def fetch(self, stage): + def fetch(self): """Retrieve the patch in a temporary stage and compute self.path Args: diff --git a/lib/spack/spack/test/patch.py b/lib/spack/spack/test/patch.py index aae0687ec1..5a4b6dba34 100644 --- a/lib/spack/spack/test/patch.py +++ b/lib/spack/spack/test/patch.py @@ -80,7 +80,7 @@ first line third line """) # apply the patch and compare files - patch.fetch(stage) + patch.fetch() patch.apply(stage) patch.clean() |