diff options
author | Brian Harring <ferringb@gentoo.org> | 2005-09-24 19:13:25 +0000 |
---|---|---|
committer | Brian Harring <ferringb@gentoo.org> | 2005-09-24 19:13:25 +0000 |
commit | 9d7c2ca645653e2533355aa305977c5e601377a2 (patch) | |
tree | 5b22f813a2617ea46163129c43d3338031209597 | |
parent | d2ccf4135a8ae3e326804b7fc0167e0b51bb59b3 (diff) | |
download | portage-9d7c2ca645653e2533355aa305977c5e601377a2.tar.gz portage-9d7c2ca645653e2533355aa305977c5e601377a2.tar.bz2 portage-9d7c2ca645653e2533355aa305977c5e601377a2.zip |
emerge --metadata ran as user, and silenced auxdb Corruption exceptions when doing metadata transfer.
svn path=/main/branches/2.0/; revision=2025
-rw-r--r-- | ChangeLog | 9 | ||||
-rwxr-xr-x | bin/emerge | 4 | ||||
-rw-r--r-- | pym/portage.py | 3 |
3 files changed, 13 insertions, 3 deletions
@@ -7,6 +7,15 @@ 2. /var/cache/edb/world is now /var/lib/portage/world. 3. /etc/portage/profile/virtuals is _USER_ configs only. + 24 Sep 2005; Brian Harring <ferringb@gentoo.org> pym/portage.py, + bin/emerge: + Final emerge metadata/cache cleanups; emerge --metadata no longer + requires root (we run searches as non root, which can update the cache, + so emerge --metadata as root is daft), and silenced auxdb exceptions + when doing metadata transfers- preparation for when the default backend + is changed. If that weren't in, user would see > 20,0000 lines of + pointless cruft output. + 24 Sep 2005; Brian Harring <ferringb@gentoo.org> pym/portage.py, +pym/portage_db_metadata.py, +pym/portage_db_flat_hash.py, pym/portage_db_flat.py, pym/portage_const.py: diff --git a/bin/emerge b/bin/emerge index 7f482eed7..ed5f9ee0a 100755 --- a/bin/emerge +++ b/bin/emerge @@ -596,7 +596,7 @@ def help(): emergehelp.help(myaction,myopts,havecolor) # check if root user is the current user for the actions where emerge needs this -if ("--pretend" in myopts) or ("--fetchonly" in myopts or "--fetch-all-uri" in myopts) or (myaction=="search"): +if ("--pretend" in myopts) or ("--fetchonly" in myopts or "--fetch-all-uri" in myopts) or (myaction=="metadata"): if not portage.secpass: if portage.wheelgid==portage.portage_gid: print "emerge: wheel group membership required for \"--pretend\" and search." @@ -612,7 +612,7 @@ elif "--help" in myopts: help() sys.exit(0) elif portage.secpass!=2: - if myaction in ["search", "info", "regen"]: + if myaction in ["search", "info", "regen", "metadata"]: pass elif (not myaction) and (not myfiles): pass diff --git a/pym/portage.py b/pym/portage.py index 26dd195f2..bcaff842c 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -5315,7 +5315,8 @@ class portdbapi(dbapi): raise except Exception, e: auxdb_is_valid = 0 - writemsg("auxdb exception: [%(loc)s]: %(exception)s\n" % {"loc":mylocation+"::"+cat+"/"+pkg, "exception":str(e)}) + if not metacachedir: + writemsg("auxdb exception: [%(loc)s]: %(exception)s\n" % {"loc":mylocation+"::"+cat+"/"+pkg, "exception":str(e)}) if self.auxdb[mylocation][cat].has_key(pkg): self.auxdb[mylocation][cat].del_key(pkg) self.auxdb[mylocation][cat].sync() |