summaryrefslogtreecommitdiff
path: root/morphlib/localrepocache.py
diff options
context:
space:
mode:
Diffstat (limited to 'morphlib/localrepocache.py')
-rw-r--r--morphlib/localrepocache.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/morphlib/localrepocache.py b/morphlib/localrepocache.py
index 1565b913..4fc3916a 100644
--- a/morphlib/localrepocache.py
+++ b/morphlib/localrepocache.py
@@ -10,8 +10,7 @@
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
-# with this program; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+# with this program. If not, see <http://www.gnu.org/licenses/>.
import os
@@ -173,7 +172,7 @@ class LocalRepoCache(object):
self._git(['config', 'remote.origin.mirror', 'true'], cwd=path)
self._git(['config', 'remote.origin.fetch', '+refs/*:refs/*'],
cwd=path)
- except BaseException, e: # pragma: no cover
+ except BaseException as e: # pragma: no cover
if self.fs.exists(path):
self.fs.removedir(path, force=True)
return False, 'Unable to extract tarball %s: %s' % (
@@ -193,7 +192,7 @@ class LocalRepoCache(object):
try:
return self.get_repo(reponame)
- except NotCached, e:
+ except NotCached as e:
pass
repourl = self._resolver.pull_url(reponame)
@@ -214,7 +213,7 @@ class LocalRepoCache(object):
try:
self._git(['clone', '--mirror', '-n', repourl, target],
echo_stderr=self._app.settings['verbose'])
- except cliapp.AppException, e:
+ except cliapp.AppException as e:
errors.append('Unable to clone from %s to %s: %s' %
(repourl, target, e))
if self.fs.exists(target):