[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Duplicity-talk] Duplicity crashes on locked files (windows)
From: |
Kenneth Loafman |
Subject: |
Re: [Duplicity-talk] Duplicity crashes on locked files (windows) |
Date: |
Tue, 07 Apr 2009 09:56:35 -0500 |
User-agent: |
Thunderbird 2.0.0.21 (X11/20090318) |
Kenneth Loafman wrote:
> Georg Lutz wrote:
>> As I cannot access savannahs bug tracker, because our company firewall
>> thinks that savannah has "evil" software downloads I file it here.
>
> Not an Open Source shop I take it? Don't get yourself into trouble
> using duplicity. Jobs are hard to find nowadays.
>
>> I understand that some locking mechanisms under windows could prevent
>> files from being saved, but nevertheless duplicity should not crash but
>> just skip this particular file.
>
> This is indeed a bug. Duplicity should just report that it could not
> read it and why, then just skip it.
Attached is a patch that fixes this problem. If the file is locked, or
otherwise unavailable, you will get an error message and duplicity will
continue onwards.
...Thanks,
...Ken
Index: robust.py
===================================================================
RCS file: /sources/duplicity/duplicity/duplicity/robust.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- robust.py 2 Apr 2009 14:47:16 -0000 1.13
+++ robust.py 7 Apr 2009 14:51:13 -0000 1.14
@@ -34,12 +34,13 @@
# todo: import here to avoid circular dependency issue
from duplicity import path
- try: return function(*args)
+ try:
+ return function(*args)
#except (EnvironmentError, SkipFileException, DSRPPermError,
# RPathException, Rdiff.RdiffException,
# librsync.librsyncError, C.UnknownFileTypeError), exc:
# TracebackArchive.add()
- except (EnvironmentError, librsync.librsyncError, path.PathException), exc:
+ except (IOError, EnvironmentError, librsync.librsyncError,
path.PathException), exc:
if (not isinstance(exc, EnvironmentError) or
((exc[0] in errno.errorcode)
and errno.errorcode[exc[0]] in
@@ -47,7 +48,8 @@
'ENOTDIR', 'ENAMETOOLONG', 'EINTR', 'ENOTEMPTY',
'EIO', 'ETXTBSY', 'ESRCH', 'EINVAL'])):
#Log.exception()
- if error_handler: return error_handler(exc, *args)
+ if error_handler:
+ return error_handler(exc, *args)
else:
#Log.exception(1, 2)
raise
signature.asc
Description: OpenPGP digital signature
- [Duplicity-talk] Duplicity crashes on locked files (windows), Georg Lutz, 2009/04/07
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Kenneth Loafman, 2009/04/07
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows),
Kenneth Loafman <=
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Georg Lutz, 2009/04/08
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Kenneth Loafman, 2009/04/08
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Georg Lutz, 2009/04/08
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Kenneth Loafman, 2009/04/08
- [Duplicity-talk] Error 30 TypeError: bad operand type for unary +: 'str', Bonvicini, Alessandro, 2009/04/09
- Re: [Duplicity-talk] Error 30 TypeError: bad operand type for unary +: 'str', Kenneth Loafman, 2009/04/09
- Re: [Duplicity-talk] Error 30 TypeError: bad operand type for unary +: 'str', Jacob, 2009/04/09
- Re: [Duplicity-talk] Error 30 TypeError: bad operand type for unary +: 'str', Kenneth Loafman, 2009/04/09
- Re: [Duplicity-talk] Duplicity crashes on locked files (windows), Georg Lutz, 2009/04/09