build-error against python 3.11 - re.error: global flags not at the start of the expression
Good morning,
building against python 3.11 fails with:
Postprocessing html files
cd /dev/shm/VIGRA/libvigraimpex-1.11.1/obj.x86_64-linux-gnu/docsrc && /usr/bin/python3 /dev/shm/VIGRA/libvigraimpex-1.11.1/docsrc/makeFunctionIndex.py /dev/shm/VIGRA/libvigraimpex-1.11.1/doc/vigra
cd /dev/shm/VIGRA/libvigraimpex-1.11.1/obj.x86_64-linux-gnu/docsrc && /usr/bin/python3 /dev/shm/VIGRA/libvigraimpex-1.11.1/docsrc/post.py /dev/shm/VIGRA/libvigraimpex-1.11.1/doc/vigra 1.11.1
Traceback (most recent call last):
File "/dev/shm/VIGRA/libvigraimpex-1.11.1/docsrc/post.py", line 84, in <module>
headingSummary = re.compile(r'''(<!-- Generated by Doxygen .+ -->
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/__init__.py", line 227, in compile
return _compile(pattern, flags)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/__init__.py", line 294, in _compile
p = _compiler.compile(pattern, flags)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/_compiler.py", line 743, in compile
p = _parser.parse(p, flags)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/_parser.py", line 980, in parse
p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/_parser.py", line 455, in _parse_sub
itemsappend(_parse(source, state, verbose, nested + 1,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/re/_parser.py", line 841, in _parse
raise source.error('global flags not at the start '
re.error: global flags not at the start of the expression at position 87 (line 5, column 1)
make[5]: *** [docsrc/CMakeFiles/doc_cpp.dir/build.make:82: doc_cpp] Error 1
cu Andreas
There is another issue in vigranumpy/docsrc/conf.py.*, which uses inspect.getargspec. This was removed in python 3.11.
Monkey-quality hotfix (google + c'n'p) for both issues: python311.diff.txt
There is another issue in vigranumpy/docsrc/conf.py.*, which uses inspect.getargspec. This was removed in python 3.11.
Monkey-quality hotfix (google + c'n'p) for both issues: python311.diff.txt
Actually the code using inspect.getargspec in vigranumpy/docsrc/conf.py.* seems to be unused and can simply be deleted.
sorry for the delay in responding. this project is really just in maintenance mode.
We recently got the CIs working again, and as such, I am not in a position to review parts of the codebase I am not entirely familiar with. Please feel free to make PRs to address the issue you find and we can gladly incorporate.