rdff-backup / python linux fat32

Tim Gahnstrom it2gati at ituniv.se
Thu Jun 24 16:00:37 CEST 2004

Peter Hansen wrote:
> Tim Gahnstrom wrote:
>> rdiff-backup is aperently written in Python and when I run it in a 
>> special way I get some funy Python errors. Does anyone know if linux 

>>   File "/usr/lib/python2.3/gzip.py", line 94, in __init__
>>     fileobj = self.myfileobj = __builtin__.open(filename, mode or 'rb')
>> IOError: invalid mode: wb
> That line "should" execute, AFAICS.  Try this, after changing the
> directory to the drive that is failing:
> -bash-2.05b$ python
> Python 2.3.3 (#1, May  7 2004, 10:31:40)
> [GCC 3.3.3 20040412 (Red Hat Linux 3.3.3-7)] on linux2
>  >>> import gzip
>  >>> gzip.GzipFile('test.file', 'w')
> If it reports the same error, then the problem is just in Python
> or your USB (or FAT32) drive.
> If it doesn't report the same error, it seems likely that rdiff-backup
> has substituted the builtin open() function with its own, for reasons
> unknown...  At least, that's the only thought that occurs to me.

 >>> import gzip
 >>> gzip.GzipFile('test.file', 'w')
<gzip open file 'test.file', mode 'wb' at 0x5505b1e0 0x5506088c>

Hmm, that seemed to work like a charm so off to look for an other source 
of the error.



More information about the Python-list mailing list