* [gentoo-commits] gentoo-x86 commit in app-portage/mirrorselect/files: 2.2.0-Fix-setup.py-PVR.patch 2.2.0-Ignore-inaccessible-fsmirrors.patch
@ 2012-12-16 6:12 Brian Dolbec (dolsen)
0 siblings, 0 replies; only message in thread
From: Brian Dolbec (dolsen) @ 2012-12-16 6:12 UTC (permalink / raw
To: gentoo-commits
dolsen 12/12/16 06:12:57
Added: 2.2.0-Fix-setup.py-PVR.patch
2.2.0-Ignore-inaccessible-fsmirrors.patch
Log:
Fix bug 373195 and incorrect egg-info version numbering
(Portage version: 2.2.0_alpha144_p1/cvs/Linux x86_64, unsigned Manifest commit)
Revision Changes Path
1.1 app-portage/mirrorselect/files/2.2.0-Fix-setup.py-PVR.patch
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-portage/mirrorselect/files/2.2.0-Fix-setup.py-PVR.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-portage/mirrorselect/files/2.2.0-Fix-setup.py-PVR.patch?rev=1.1&content-type=text/plain
Index: 2.2.0-Fix-setup.py-PVR.patch
===================================================================
From bc0efc857b5708ea572e3a4c57c9689cf48c50ad Mon Sep 17 00:00:00 2001
From: Brian Dolbec <dolsen@gentoo.org>
Date: Sat, 15 Dec 2012 20:48:17 -0800
Subject: [PATCH] Fix setup.py to use PVR instead of VERSION from the
environment so that egg-info is set correctly during the
merge.
---
setup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup.py b/setup.py
index 8a9f980..7a53076 100755
--- a/setup.py
+++ b/setup.py
@@ -12,7 +12,7 @@ import os
import io
-__version__ = os.getenv('VERSION', default='9999')
+__version__ = os.getenv('VERSION', default=os.getenv('PVR', default='9999'))
cwd = os.getcwd()
--
1.8.0
1.1 app-portage/mirrorselect/files/2.2.0-Ignore-inaccessible-fsmirrors.patch
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-portage/mirrorselect/files/2.2.0-Ignore-inaccessible-fsmirrors.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-portage/mirrorselect/files/2.2.0-Ignore-inaccessible-fsmirrors.patch?rev=1.1&content-type=text/plain
Index: 2.2.0-Ignore-inaccessible-fsmirrors.patch
===================================================================
From 362ba4585a48273289f382c16947e858ff3818cf Mon Sep 17 00:00:00 2001
From: Brian Dolbec <dolsen@gentoo.org>
Date: Sat, 15 Dec 2012 18:37:50 -0800
Subject: [PATCH] Add aditional debug info, fix bug 373195, removing garbage
or otherwise inaccessible file system mirrors from existing
SYNC or GENTOO_MIRRORS make.conf values.
---
mirrorselect/main.py | 14 +++++++++++---
mirrorselect/selectors.py | 4 +++-
2 files changed, 14 insertions(+), 4 deletions(-)
diff --git a/mirrorselect/main.py b/mirrorselect/main.py
index cbff890..48d74a7 100755
--- a/mirrorselect/main.py
+++ b/mirrorselect/main.py
@@ -154,8 +154,7 @@ class MirrorSelect(object):
sys.exit(0)
- @staticmethod
- def get_filesystem_mirrors(config_path, sync=False):
+ def get_filesystem_mirrors(self, config_path, sync=False):
"""Read the current mirrors and retain mounted filesystems mirrors
@param config_path: string
@@ -170,6 +169,7 @@ class MirrorSelect(object):
else:
var = 'GENTOO_MIRRORS'
+ self.output.write('get_filesystem_mirrors(): config_path = %s\n' % config_path)
try:
f = open(config_path,'r')
except IOError:
@@ -182,6 +182,8 @@ class MirrorSelect(object):
lex.quotes = "\"'"
while 1:
key = lex.get_token()
+ #self.output.write('get_filesystem_mirrors(): processing key = %s\n' % key, 2)
+
if key == var:
equ = lex.get_token()
@@ -196,16 +198,22 @@ class MirrorSelect(object):
""" Look for mounted filesystem in value """
mirrorlist = val.rsplit()
+ self.output.write('get_filesystem_mirrors(): mirrorlist = %s\n' % mirrorlist, 2)
p = re.compile('rsync://|http://|ftp://', re.IGNORECASE)
for mirror in mirrorlist:
if (p.match(mirror) == None):
- fsmirrors.append(mirror)
+ if os.access(mirror, os.F_OK):
+ self.output.write('get_filesystem_mirrors(): found file system mirror = %s\n' % mirror, 2)
+ fsmirrors.append(mirror)
+ else:
+ self.output.write('get_filesystem_mirrors(): ignoring non-accessible mirror = %s\n' % mirror, 2)
break
elif key is None:
break
except Exception:
fsmirrors = []
+ self.output.write('get_filesystem_mirrors(): fsmirrors = %s\n' % fsmirrors, 2)
return fsmirrors
diff --git a/mirrorselect/selectors.py b/mirrorselect/selectors.py
index b2a5fc7..38ca07a 100644
--- a/mirrorselect/selectors.py
+++ b/mirrorselect/selectors.py
@@ -303,14 +303,16 @@ class Deep(object):
self.output.write('\n') #this just makes output nicer
- #can't just return the dict.valuse, because we want the fastest mirror first...
+ #can't just return the dict.values, because we want the fastest mirror first...
keys = list(top_hosts.keys())
keys.sort()
rethosts = []
for key in keys:
+ #self.output.write('deeptest(): adding rethost %s, %s' % (key, top_hosts[key]), 2)
rethosts.append(top_hosts[key])
+ self.output.write('deeptest(): final rethost %s' % (rethosts), 2)
self.urls = rethosts
--
1.8.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-12-16 6:13 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-16 6:12 [gentoo-commits] gentoo-x86 commit in app-portage/mirrorselect/files: 2.2.0-Fix-setup.py-PVR.patch 2.2.0-Ignore-inaccessible-fsmirrors.patch Brian Dolbec (dolsen)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox