diff options
author | Sebastian Pipping <sebastian@pipping.org> | 2010-02-18 05:42:00 +0100 |
---|---|---|
committer | Sebastian Pipping <sebastian@pipping.org> | 2010-02-18 05:42:00 +0100 |
commit | b3c281c1c5060f4d28e83680dbbc3f2819f0bd42 (patch) | |
tree | 0ce9dca24be6096b176e3c2ff878ae91e515c5c3 | |
parent | No longer read same XML file twice (diff) | |
download | overlord-b3c281c1c5060f4d28e83680dbbc3f2819f0bd42.tar.gz overlord-b3c281c1c5060f4d28e83680dbbc3f2819f0bd42.tar.bz2 overlord-b3c281c1c5060f4d28e83680dbbc3f2819f0bd42.zip |
Move safe op out of try-except block, extend code doc
-rw-r--r-- | layman/dbbase.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/layman/dbbase.py b/layman/dbbase.py index a7c4154..d8aa401 100644 --- a/layman/dbbase.py +++ b/layman/dbbase.py @@ -94,7 +94,7 @@ class DbBase: def read(self, text): ''' - Read an xml list of overlays. + Read an xml list of overlays (adding to and potentially overwriting existing entries) >>> here = os.path.dirname(os.path.realpath(__file__)) >>> config = {'svn_command': '/usr/bin/svn', 'rsync_command':'/usr/bin/rsync'} @@ -113,9 +113,10 @@ class DbBase: OUT.debug('Parsing overlay entry', 8) try: ovl = Overlay(overlay, self.config, self.ignore, self.quiet) - self.overlays[ovl.name] = ovl except Exception, error: OUT.warn(str(error), 3) + else: + self.overlays[ovl.name] = ovl def write(self, path): |