Re: Feedback required - new arguments parsing for rdiff-backup

Eric Lavarde <[email protected]>
Newsgroups gmane.comp.sysutils.backup.rdiff-backup.general
Organization Zorglub & Co
Message-ID <[email protected]>
Hi Dominic,

On 05/01/2021 12:39, Dominic Raferd wrote:
> Thanks Eric for all your great work on rdiff-backup over the last year
> (I now use v2.0.5 on Ubuntu 20.04 and Windows [latter only as client],
> it works great), and all the best for 2021.

Thanks a lot for the kind words.

> But when I try arguments.py I get this:
> # python3 --version
> Python 3.8.5
> # python3 ./arguments.py --help
> Traceback (most recent call last):
>   File "./arguments.py", line 120, in <module>
>     "--fsync", default=True, action=argparse.BooleanOptionalAction,
> AttributeError: module 'argparse' has no attribute 'BooleanOptionalAction'

I can only apologize, I forgot to test on lower versions of Python and
did only work with Python 3.9 [1]. The attached version should now work
with python down to version 3.6.

Sorry for the inconvenience,
Eric

[1] to my defense, the argparse documentation doesn't say that
BooleanOptionalAction is new with 3.9
arguments.py.gz (application/gzip, 8 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.