summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMassimiliano Culpo <massimiliano.culpo@gmail.com>2019-04-12 22:40:06 +0200
committerPeter Scheibel <scheibel1@llnl.gov>2019-04-18 18:41:22 -0700
commit400aa5fe515f90e4c9034fa4d5607f59c307594b (patch)
tree8e7446d9f5766e6795b56366e3e92b42a2312445
parent76b5af6bf364fac0bab99d327527128f0e04f62e (diff)
downloadspack-400aa5fe515f90e4c9034fa4d5607f59c307594b.tar.gz
spack-400aa5fe515f90e4c9034fa4d5607f59c307594b.tar.bz2
spack-400aa5fe515f90e4c9034fa4d5607f59c307594b.tar.xz
spack-400aa5fe515f90e4c9034fa4d5607f59c307594b.zip
Cleaned get methods of Repo and RepoPath
-rw-r--r--lib/spack/spack/repo.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/spack/spack/repo.py b/lib/spack/spack/repo.py
index fcc76af37c..00928d84b6 100644
--- a/lib/spack/spack/repo.py
+++ b/lib/spack/spack/repo.py
@@ -638,11 +638,8 @@ class RepoPath(object):
return self.first_repo()
@autospec
- def get(self, spec, new=False):
- """Find a repo that contains the supplied spec's package.
-
- Raises UnknownPackageError if not found.
- """
+ def get(self, spec):
+ """Returns the package associated with the supplied spec."""
return self.repo_for_pkg(spec).get(spec)
def get_pkg_class(self, pkg_name):
@@ -873,6 +870,7 @@ class Repo(object):
@autospec
def get(self, spec):
+ """Returns the package associated with the supplied spec."""
if not self.exists(spec.name):
raise UnknownPackageError(spec.name)