Closed speth closed 11 months ago
There was a change of support libraries in {fmt} version 7.1.0. With the current version being 10.0 (and numerous existing workarounds in fmt.h
for relatively dated versions), I am proposing to limit support to the most recent versions, while improving CI - see #1538. I found multiple bugs/regressions while addressing this issue report, which are mostly due to frequent changes of the {fmt} API.
Finally managed to get a configuration on macOS (Python 3.8 / fmt 6.1.2), by simply checking out the 6.1.2 hash from the submodule. It does, however, not compile with the following error right at the beginning:
For main
:
g++ -o build/src/extensions/pythonShim.os -c -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/lib/python3.8/site-packages/numpy/core/include -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/include/python3.8 -isystem include/cantera/ext -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/include -std=c++17 -Wno-deprecated-declarations -O3 -Wno-inline -g -Wall -fPIC -DNDEBUG -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -Iinclude -Iinclude -Ibuild/src src/extensions/pythonShim.cpp
scons: *** [build/ext/fmt/src/os.os] Source `ext/fmt/src/os.cc' not found, needed by target `build/ext/fmt/src/os.os'.
For the #1538 branch:
g++ -o build/src/extensions/pythonShim.os -c -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/lib/python3.8/site-packages/numpy/core/include -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/include/python3.8 -isystem include/cantera/ext -isystem /opt/homebrew/Caskroom/miniforge/base/envs/ctdev/include -std=c++17 -Wno-deprecated-declarations -O3 -Wno-inline -g -Wall -fPIC -DNDEBUG -DFMT_HEADER_ONLY=1 -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -Iinclude -Iinclude -Ibuild/src src/extensions/pythonShim.cpp
ext/fmt/src/format.cc:124:35: error: duplicate explicit instantiation of 'basic_data<>'
template struct FMT_API internal::basic_data<void>;
^
ext/fmt/include/fmt/format.h:739:28: note: previous explicit instantiation is here
FMT_EXTERN template struct basic_data<void>;
^
1 error generated.
Yes, this corresponds to changes in the organization of the {fmt} source code. Our compilation done in ext/SConscript
only needs to work with the submodule version (9.1.0). This was changed in 3c9af75f0537f0378e6d0406b0b3a72753766044, if you want to swap that for local testing -- it's a pretty small change.
Yes, this corresponds to changes in the organization of the {fmt} source code. Our compilation done in
ext/SConscript
only needs to work with the submodule version (9.1.0). This was changed in 3c9af75, if you want to swap that for local testing -- it's a pretty small change.
Ah, this makes sense.
Problem description
Using
fmt
version 6.1.2, a number of tests in the Python test suite that test the formatted output fromSolutionArray
report failures. This version offmt
is what is available on Ubuntu 20.04, so it would be nice to continue supporting it.Steps to reproduce
fmt
version 6.1.2scons test-python-composite
Behavior
The following tests fail:
A specific error that helps show that the output is indeed not as expected:
You can see that in the first data row, there is an ellipsis, not separated from adjacent entries, and also not present in either the header row or the following data row.
System information
Attachments
Complete log of running
scons test-python-composite
: test-python-composite-log.txt