Only occurs in latest version (0.6.07).
Traceback (most recent call last):
File "/usr/bin/duplicity", line 1236, in ?
with_tempdir(main)
File "/usr/bin/duplicity", line 1229, in with_tempdir
fn()
File "/usr/bin/duplicity", line 1115, in main
action = commandline.ProcessCommandLine(sys.argv[1:])
File "/usr/lib/python2.4/site-packages/duplicity/commandline.py", line 876, in ProcessCommandLine
args = parse_cmdline_options(cmdline_list)
File "/usr/lib/python2.4/site-packages/duplicity/commandline.py", line 503, in parse_cmdline_options
globals.remove_time = dup_time.genstrtotime(arg)
File "/usr/lib/python2.4/site-packages/duplicity/dup_time.py", line 271, in genstrtotime
return override_curtime - intstringtoseconds(timestr)
TypeError: unsupported operand type(s) for -: 'NoneType' and 'int'
I just ran into this after upgrading from 0.6.06 to 0.6.07 -
duplicity --name BACKUP1 --full- if-older- than 1M --no-encryption --include- globbing- filelist filelist / file:// /media/ BACKUP1 duplicity" , line 1236, in <module> tempdir( main) duplicity" , line 1229, in with_tempdir duplicity" , line 1115, in main ProcessCommandL ine(sys. argv[1: ]) python2. 6/dist- packages/ duplicity/ commandline. py", line 876, in ProcessCommandLine options( cmdline_ list) python2. 6/dist- packages/ duplicity/ commandline. py", line 450, in parse_cmdline_ options python2. 6/optparse. py", line 1394, in parse_args args(largs, rargs, values) python2. 6/optparse. py", line 1434, in _process_args _process_ long_opt( rargs, values) python2. 6/optparse. py", line 1509, in _process_long_opt process( opt, value, values, self) python2. 6/optparse. py", line 782, in process value(opt, value) python2. 6/optparse. py", line 774, in convert_value value(opt, value) python2. 6/optparse. py", line 769, in check_value python2. 6/dist- packages/ duplicity/ commandline. py", line 110, in check_time genstrtotime( value) python2. 6/dist- packages/ duplicity/ dup_time. py", line 271, in genstrtotime nds(timestr)
Traceback (most recent call last):
File "/usr/bin/
with_
File "/usr/bin/
fn()
File "/usr/bin/
action = commandline.
File "/usr/lib/
args = parse_cmdline_
File "/usr/lib/
(options, args) = parser.parse_args()
File "/usr/lib/
stop = self._process_
File "/usr/lib/
self.
File "/usr/lib/
option.
File "/usr/lib/
value = self.convert_
File "/usr/lib/
return self.check_
File "/usr/lib/
return checker(self, opt, value)
File "/usr/lib/
return dup_time.
File "/usr/lib/
return override_curtime - intstringtoseco
TypeError: unsupported operand type(s) for -: 'NoneType' and 'int'
In my case the workaround is to remove "-full- if-older- than 1M" and to specify a full or incremental backup explicitly.
I believe the problem is that in duplicity main(), commandline. ProcessCommandL ine() is now called before dup_time. setcurtime( ), so the curtime global is not set.