summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-10-13 14:27:03 -0700
committerZac Medico <zmedico@gentoo.org>2011-10-13 14:27:03 -0700
commit5c7bf4eb09f644813a6f017ffd91665664142560 (patch)
tree25d71f9506171f3c62f63e820e318b7a4d134722
parenta27f3f3058fdbdaca2bcb838aca02ffc4e32007a (diff)
downloadportage-5c7bf4eb09f644813a6f017ffd91665664142560.tar.gz
portage-5c7bf4eb09f644813a6f017ffd91665664142560.tar.bz2
portage-5c7bf4eb09f644813a6f017ffd91665664142560.zip
layout.conf: revert authoritative-cache support
Those who wanted it have decided to use a different approach.
-rw-r--r--pym/portage/cache/template.py1
-rw-r--r--pym/portage/dbapi/porttree.py10
-rw-r--r--pym/portage/repository/config.py27
3 files changed, 6 insertions, 32 deletions
diff --git a/pym/portage/cache/template.py b/pym/portage/cache/template.py
index 847683621..f84d8f4b9 100644
--- a/pym/portage/cache/template.py
+++ b/pym/portage/cache/template.py
@@ -30,7 +30,6 @@ class database(object):
self.readonly = readonly
self.sync_rate = 0
self.updates = 0
- self.is_authoritative = False
def __getitem__(self, cpv):
"""set a cpv to values
diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py
index 911dbb5fe..ef2e08870 100644
--- a/pym/portage/dbapi/porttree.py
+++ b/pym/portage/dbapi/porttree.py
@@ -218,7 +218,6 @@ class portdbapi(dbapi):
conf = self.repositories.get_repo_for_location(x)
cache = self._pregen_auxdb[x] = self.metadbmodule(
x, "metadata/cache", filtered_auxdbkeys, readonly=True)
- cache.is_authoritative = conf.cache_is_authoritative
try:
cache.ec = self._repo_info[x].eclass_db
except AttributeError:
@@ -443,11 +442,10 @@ class portdbapi(dbapi):
eapi = metadata.get('EAPI', '').strip()
if not eapi:
eapi = '0'
- if not (eapi[:1] == '-' and eapi_is_supported(eapi[1:])):
- if auxdb.is_authoritative or ( \
- emtime == metadata['_mtime_'] and \
- eclass_db.is_eclass_data_valid(metadata['_eclasses_'])):
- doregen = False
+ if not (eapi[:1] == '-' and eapi_is_supported(eapi[1:])) and \
+ emtime == metadata['_mtime_'] and \
+ eclass_db.is_eclass_data_valid(metadata['_eclasses_']):
+ doregen = False
if not doregen:
break
diff --git a/pym/portage/repository/config.py b/pym/portage/repository/config.py
index 8f5517711..2490b65da 100644
--- a/pym/portage/repository/config.py
+++ b/pym/portage/repository/config.py
@@ -44,11 +44,11 @@ class RepoConfig(object):
"""Stores config of one repository"""
__slots__ = ('aliases', 'allow_missing_manifest',
- 'cache_is_authoritative', 'create_manifest', 'disable_manifest',
+ 'create_manifest', 'disable_manifest',
'eclass_overrides', 'eclass_locations', 'format', 'location',
'main_repo', 'manifest_hashes', 'masters', 'missing_repo_name',
'name', 'priority', 'sign_manifest', 'sync', 'thin_manifest',
- 'trust_authoritative_cache', 'user_location')
+ 'user_location')
def __init__(self, name, repo_opts):
"""Build a RepoConfig with options in repo_opts
@@ -127,13 +127,6 @@ class RepoConfig(object):
self.disable_manifest = False
self.manifest_hashes = None
- self.cache_is_authoritative = False
-
- trust_authoritative_cache = repo_opts.get('trust-authoritative-cache')
- if trust_authoritative_cache is not None:
- trust_authoritative_cache = trust_authoritative_cache.lower() == 'true'
- self.trust_authoritative_cache = trust_authoritative_cache
-
def load_manifest(self, *args, **kwds):
kwds['thin'] = self.thin_manifest
kwds['allow_missing'] = self.allow_missing_manifest
@@ -151,8 +144,6 @@ class RepoConfig(object):
self.eclass_overrides = new_repo.eclass_overrides
if new_repo.masters is not None:
self.masters = new_repo.masters
- if new_repo.trust_authoritative_cache is not None:
- self.trust_authoritative_cache = new_repo.trust_authoritative_cache
if new_repo.name is not None:
self.name = new_repo.name
self.missing_repo_name = new_repo.missing_repo_name
@@ -240,11 +231,6 @@ class RepoConfigLoader(object):
if prepos['DEFAULT'].masters is not None:
default_repo_opts['masters'] = \
' '.join(prepos['DEFAULT'].masters)
- if prepos['DEFAULT'].trust_authoritative_cache is not None:
- if prepos['DEFAULT'].trust_authoritative_cache:
- default_repo_opts['trust-authoritative-cache'] = 'true'
- else:
- default_repo_opts['trust-authoritative-cache'] = 'false'
if overlays:
#overlay priority is negative because we want them to be looked before any other repo
@@ -265,11 +251,6 @@ class RepoConfigLoader(object):
if repo_conf_opts.masters is not None:
repo_opts['masters'] = \
' '.join(repo_conf_opts.masters)
- if repo_conf_opts.trust_authoritative_cache is not None:
- if repo_conf_opts.trust_authoritative_cache:
- repo_opts['trust-authoritative-cache'] = 'true'
- else:
- repo_opts['trust-authoritative-cache'] = 'false'
repo = RepoConfig(repo.name, repo_opts)
if repo.name in prepos:
@@ -425,10 +406,6 @@ class RepoConfigLoader(object):
DeprecationWarning)
repo.manifest_hashes = manifest_hashes
- repo.cache_is_authoritative = layout_data.get('authoritative-cache', 'false').lower() == 'true'
- if not repo.trust_authoritative_cache:
- repo.cache_is_authoritative = False
-
#Take aliases into account.
new_prepos = {}
for repo_name, repo in prepos.items():