diff options
author | Anthony G. Basile <blueness@gentoo.org> | 2015-07-01 12:54:27 -0400 |
---|---|---|
committer | Anthony G. Basile <blueness@gentoo.org> | 2015-07-01 12:54:27 -0400 |
commit | 453e36867eb79ec1989f241caf15552c04b49de4 (patch) | |
tree | a11823691c0e4dedf9617c2e99dccb2860ce12f7 /grs/Seed.py | |
parent | Clean up makedirs(). (diff) | |
download | grss-453e36867eb79ec1989f241caf15552c04b49de4.tar.gz grss-453e36867eb79ec1989f241caf15552c04b49de4.tar.bz2 grss-453e36867eb79ec1989f241caf15552c04b49de4.zip |
Clean up more exceptions.
Diffstat (limited to 'grs/Seed.py')
-rw-r--r-- | grs/Seed.py | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/grs/Seed.py b/grs/Seed.py index 76034cc..4ac95ed 100644 --- a/grs/Seed.py +++ b/grs/Seed.py @@ -56,16 +56,9 @@ class Seed(): # Download a stage tarball if we don't have one if not os.path.isfile(self.filepath): - try: - request = urllib.request.urlopen(self.stage_uri) - with open(self.filepath, 'wb') as f: - shutil.copyfileobj(request, f) - except: #any exception will do here - pid = os.getpid() - with open(self.logfile, 'r') as f: - f.write('SENDING SIGTERM to pid = %d\n' % pid) - f.close() - os.kill(pid, signal.SIGTERM) + request = urllib.request.urlopen(self.stage_uri) + with open(self.filepath, 'wb') as f: + shutil.copyfileobj(request, f) # Because python's tarfile sucks cmd = 'tar --xattrs -xf %s -C %s' % (self.filepath, self.portage_configroot) |