[csw-devel] SF.net SVN: gar:[13579] csw/mgar/gar/v2/lib/python/csw_upload_pkg.py
wahwah at users.sourceforge.net
wahwah at users.sourceforge.net
Sat Mar 5 09:07:34 CET 2011
Revision: 13579
http://gar.svn.sourceforge.net/gar/?rev=13579&view=rev
Author: wahwah
Date: 2011-03-05 08:07:33 +0000 (Sat, 05 Mar 2011)
Log Message:
-----------
csw-upload-pkg: Graceful handling of nonexistent
When asked to remove a file from a catalog, and the file is not present in the
database, gracefully skip it and proceed to the next one.
Modified Paths:
--------------
csw/mgar/gar/v2/lib/python/csw_upload_pkg.py
Modified: csw/mgar/gar/v2/lib/python/csw_upload_pkg.py
===================================================================
--- csw/mgar/gar/v2/lib/python/csw_upload_pkg.py 2011-03-05 08:07:00 UTC (rev 13578)
+++ csw/mgar/gar/v2/lib/python/csw_upload_pkg.py 2011-03-05 08:07:33 UTC (rev 13579)
@@ -85,6 +85,9 @@
def _RemoveFile(self, filename):
md5_sum = self._GetFileMd5sum(filename)
file_in_allpkgs, file_metadata = self._GetSrv4FileMetadata(md5_sum)
+ if not file_metadata:
+ logging.warning("Could not find metadata for file %s", repr(filename))
+ return
osrel = file_metadata['osrel']
arch = file_metadata['arch']
catalogs = self._MatchSrv4ToCatalogs(
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the devel
mailing list