summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/_emerge/Package.py4
-rw-r--r--pym/_emerge/Scheduler.py9
-rw-r--r--pym/_emerge/depgraph.py14
3 files changed, 7 insertions, 20 deletions
diff --git a/pym/_emerge/Package.py b/pym/_emerge/Package.py
index 88adbf55f..6763f8e16 100644
--- a/pym/_emerge/Package.py
+++ b/pym/_emerge/Package.py
@@ -237,3 +237,7 @@ class _PackageMetadataWrapper(_PackageMetadataWrapperBase):
except ValueError:
v = 0
self._pkg.mtime = v
+
+ @property
+ def properties(self):
+ return self['PROPERTIES'].split()
diff --git a/pym/_emerge/Scheduler.py b/pym/_emerge/Scheduler.py
index b63245cda..34476d86c 100644
--- a/pym/_emerge/Scheduler.py
+++ b/pym/_emerge/Scheduler.py
@@ -328,14 +328,7 @@ class Scheduler(PollScheduler):
if not (isinstance(task, Package) and \
task.operation == "merge"):
continue
- try:
- properties = flatten(use_reduce(paren_reduce(
- task.metadata["PROPERTIES"]), uselist=task.use.enabled))
- except portage.exception.InvalidDependString, e:
- show_invalid_depstring_notice(task,
- task.metadata["PROPERTIES"], str(e))
- raise self._unknown_internal_error()
- if "interactive" in properties:
+ if 'interactive' in task.metadata.properties:
interactive_tasks.append(task)
return interactive_tasks
diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py
index e69a20278..2d9c50405 100644
--- a/pym/_emerge/depgraph.py
+++ b/pym/_emerge/depgraph.py
@@ -4007,18 +4007,8 @@ class depgraph(object):
else:
return colorize("PKG_NOMERGE", pkg_str)
- try:
- properties = flatten(use_reduce(paren_reduce(
- pkg.metadata["PROPERTIES"]), uselist=pkg.use.enabled))
- except portage.exception.InvalidDependString, e:
- if not pkg.installed:
- show_invalid_depstring_notice(pkg,
- pkg.metadata["PROPERTIES"], str(e))
- del e
- return 1
- properties = []
- interactive = "interactive" in properties
- if interactive and pkg.operation == "merge":
+ if 'interactive' in pkg.metadata.properties and \
+ pkg.operation == 'merge':
addl = colorize("WARN", "I") + addl[1:]
if ordered:
counters.interactive += 1