diff --git a/cybertools/storage/filesystem.py b/cybertools/storage/filesystem.py index 7494d01..19ee8c1 100644 --- a/cybertools/storage/filesystem.py +++ b/cybertools/storage/filesystem.py @@ -60,7 +60,7 @@ class FileSystemStorage(object): data = f.read() f.close() return data - except(IOError, e): + except IOError as e: logger.warn(e) #'File %r cannot be read.' % fn) return '' @@ -70,7 +70,7 @@ class FileSystemStorage(object): fn = self.getDir(address, subDir) try: return os.path.getsize(fn) - except(OSError, e): + except OSError as e: logger.warn(e) return 0 @@ -81,7 +81,7 @@ class FileSystemStorage(object): ts = os.path.getmtime(fn) if ts: return datetime.fromtimestamp(ts) - except(OSError, e): + except OSError as e: logger.warn(e) return None diff --git a/cybertools/xedit/handler.py b/cybertools/xedit/handler.py index cb6e5f8..bb312f9 100644 --- a/cybertools/xedit/handler.py +++ b/cybertools/xedit/handler.py @@ -1,25 +1,6 @@ -# -# Copyright (c) 2007 Helmut Merz helmutm@cy55.de -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -# +# cybertools.xedit.handler -""" -HTTP method handler. - -$Id$ +""" HTTP method handler. """ """ @@ -66,4 +47,4 @@ class NullLOCK(object): return '' def printRequest(self, request): - print self.request['wsgi.input'].read() + print(self.request['wsgi.input'].read())