summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/FakeVartree.py
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-11-07 01:09:49 +0000
committerZac Medico <zmedico@gentoo.org>2009-11-07 01:09:49 +0000
commit964a5a7c2b9f07c7a54a25a8652f8fcedeab4136 (patch)
tree32d9ef1ecd78ab6bdb7e6a5deeefe362dfa8d51f /pym/_emerge/FakeVartree.py
parent55a635af1605c9eef7bd1e2eafce8887a56eeaec (diff)
downloadportage-964a5a7c2b9f07c7a54a25a8652f8fcedeab4136.tar.gz
portage-964a5a7c2b9f07c7a54a25a8652f8fcedeab4136.tar.bz2
portage-964a5a7c2b9f07c7a54a25a8652f8fcedeab4136.zip
Move FakeVartree population out of the constructor by calling the sync()
method explicitly. This allows the depgraph constructor avoid populating the FakeVartree, and delay it until depgraph._load_vdb() is called. (trunk r14773) svn path=/main/branches/2.1.7/; revision=14786
Diffstat (limited to 'pym/_emerge/FakeVartree.py')
-rw-r--r--pym/_emerge/FakeVartree.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/pym/_emerge/FakeVartree.py b/pym/_emerge/FakeVartree.py
index 07703f3f2..e1b819809 100644
--- a/pym/_emerge/FakeVartree.py
+++ b/pym/_emerge/FakeVartree.py
@@ -21,8 +21,9 @@ class FakeVartree(portage.vartree):
allows things like vardb global updates to be done in memory so that the
user doesn't necessarily need write access to the vardb in cases where
global updates are necessary (updates are performed when necessary if there
- is not a matching ebuild in the tree)."""
- def __init__(self, root_config, pkg_cache=None, acquire_lock=1):
+ is not a matching ebuild in the tree). Instances of this class are not
+ populated until the sync() method is called."""
+ def __init__(self, root_config, pkg_cache=None):
self._root_config = root_config
if pkg_cache is None:
pkg_cache = {}
@@ -49,8 +50,6 @@ class FakeVartree(portage.vartree):
self._portdb = portdb
self._global_updates = None
- self.sync()
-
def _match_wrapper(self, cpv, use_cache=1):
"""
Make sure the metadata in Package instances gets updated for any