diff options
author | Richard Ipsum <richardipsum@fastmail.co.uk> | 2014-10-10 20:03:17 +0100 |
---|---|---|
committer | Richard Ipsum <richardipsum@fastmail.co.uk> | 2014-10-10 21:27:28 +0100 |
commit | 639bca2a58e872238e991311676f448065093ea2 (patch) | |
tree | 245b134c42f277f3843856e0cf17710a7b49e13f /morphlib/artifactresolver.py | |
parent | 97f5b7fdfc7cb89748ce477653aae5c54c16668b (diff) | |
download | morph-639bca2a58e872238e991311676f448065093ea2.tar.gz |
Simplify _resolve_system_artifacts
Diffstat (limited to 'morphlib/artifactresolver.py')
-rw-r--r-- | morphlib/artifactresolver.py | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/morphlib/artifactresolver.py b/morphlib/artifactresolver.py index 30fb5e5a..e53c7511 100644 --- a/morphlib/artifactresolver.py +++ b/morphlib/artifactresolver.py @@ -57,19 +57,11 @@ class ArtifactResolver(object): if not a.dependents] def _resolve_system_artifacts(self, source, artifacts): # pragma: no cover - systems = [source.artifacts[name] - for name in source.split_rules.artifacts] + systems = [source.artifacts[name] for name + in source.split_rules.artifacts] - for system in (s for s in systems if s not in self._added_artifacts): - artifacts.append(system) - self._added_artifacts.add(system) - - resolved_artifacts = self._resolve_system_dependencies(systems, source) - - for artifact in resolved_artifacts: - if not artifact in self._added_artifacts: - artifacts.append(artifact) - self._added_artifacts.add(artifact) + artifacts += systems + artifacts += self._resolve_system_dependencies(systems, source) def _resolve_stratum_artifacts(self, source, artifacts): # Iterate split_rules.artifacts, rather than |