duply stumbles on python -s shebang in duplicity
Brought to you by:
edso
In recent Fedora packages, duplicity has this shebang: #!/usr/bin/python3 -s. This caused duply to fail like this Python:
Start duply v2.3.1, time is 2022-03-25 09:45:55.
Sorry. A fatal ERROR occured:
/usr/bin/python3 -s missing. installed und available in path?
PATH='/root/.local/bin:/root/bin:/usr/lib64/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin'
In one of the bug reports it was suggested to change the relevant line in function duplicity_python_binary_parse from
DUPL_PYTHON_BIN=$(awk 'NR==1&&/^#!/{sub(/^#!( *\/usr\/bin\/env *)?/,""); print}' < "$DUPL_BIN")
to
DUPL_PYTHON_BIN=$(awk 'NR==1&&/^#!/{sub(/^#!( *\/usr\/bin\/env *)?/,""); print $1}' < "$DUPL_BIN")
hey Thomas,
thanks for the heads up! i'm about to remove the shebang parsing from duplicity as well as the need for any python binary (for duply).
there is another bug report about shebang parsing already,
https://sourceforge.net/p/ftplicity/bugs/129/
so i will close this as a duplicate, although it strictly speaking isn't. still one bug will remind me plenty.
thanks again! ..ede
hi Thomas,
can you please test if this v2.4dev snapshot
https://duply.net/tmp/duply.sh
works for you?
thanks.. ede