Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

failing python tests with shared libs if python bindings are on. #5322

Open
blattms opened this issue Apr 29, 2024 · 2 comments
Open

failing python tests with shared libs if python bindings are on. #5322

blattms opened this issue Apr 29, 2024 · 2 comments
Labels

Comments

@blattms
Copy link
Member

blattms commented Apr 29, 2024

For both Python 3.11 (Debian stable) and 3.12 (Ubuntu noble) I am now getting failing python tests because of an assertion.
E.g. for python_basic:

343: python3: /home/mblatt/src/dune/opm-2.9/opm-models/opm/models/blackoil/blackoilprimaryvariables.hh:437: void Opm::BlackOilPrimaryVariables<TypeTag>::assignNaive(const FluidState&) [with FluidState = Opm::BlackOilFluidState<double, Opm::BlackOilFluidSystem<double, Opm::BlackOilDefaultIndexTraits>, true, false, true, false, false, false, false, 3>; TypeTag = Opm::Properties::TTag::FlowProblemTPFA]: Assertion `FluidSystem::phaseIsActive(waterPhaseIdx)' failed.
343: [frau-mahlzahn:74975] *** Process received signal ***
343: [frau-mahlzahn:74975] Signal: Aborted (6)
343: [frau-mahlzahn:74975] Signal code:  (-6)
343: [frau-mahlzahn:74975] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x3c050)[0x7f22cde6c050]

build options:

set(BUILD_SHARED_LIBS ON CACHE BOOL "Use shared libs")
set(CMAKE_CXX_FLAGS "-DDEBUG -g -Og -Wall -Wextra -DDEBUG " CACHE STRING "CXX opts")
set(CMAKE_C_FLAGS "-DDEBUG -g -Og -Wall -Wextra -DDEBUG " CACHE STRING "CXX opts")
set(CMAKE_DISABLE_FIND_PACKAGE_dune-uggrid ON CACHE STRING "disable ug")
set(CMAKE_BUILD_TYPE "None" CACHE STRING "Build type")
set(USE_MPI ON         CACHE STRING "Use mpi")
set(BUILD_TESTING ON CACHE BOOL "Build tests")
set(CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY 1 CACHE BOOL "" FORCE)
set(BUILD_ECL_SUMMARY ON CACHE BOOL "Build summary.x")
set(BUILD_APPLICATIONS OFF CACHE BOOL "Build applications")
set(CMAKE_INSTALL_PREFIX "/home/mblatt/opt/opm/" CACHE PATH "installation directory")
set(CMAKE_DISABLE_FIND_PACKAGE_CUDA ON CACHE PATH "no cuda")
set(CMAKE_DISABLE_FIND_PACKAGE_dune-fem ON CACHE PATH "no dune-fem")
set(BUILD_FLOW_VARIANTS ON CACHE BOOL "cpr variants")
set(CMAKE_DISABLE_FIND_PACKAGE_dune-uggrid ON CACHE BOOL "disable UG")
set(CMAKE_DISABLE_FIND_PACKAGE_UG ON CACHE BOOL "disable UG")
set(OPM_ENABLE_PYTHON ON CACHE BOOL "Python")
set(OPM_ENABLE_EMBEDDED_PYTHON ON CACHE BOOL "Embedded Python")
set(OPM_INSTALL_PYTHON ON CACHE BOOL "Install Python")

If I set BUILD_SHARED_LIBS to OFF the problem is not there. This is why jenkins does not notice it. For whatever reason I also have deactivated the python tests for opm-simulators on Debian/Ubuntu, which is why I did not notice this earlier.

Somehow this smells like a static variable issue to me.

@blattms
Copy link
Member Author

blattms commented Apr 29, 2024

Here are the logs from the python tests: failing_python_tests.log

@blattms
Copy link
Member Author

blattms commented Apr 29, 2024

I see the same failures if OPM_ENABLE_EMBEDDED_PYTHON is off. So this is really an issue with the python bindings here.

@blattms blattms added the bug label Apr 29, 2024
@blattms blattms changed the title failing python tests with shared libs if embedded python and python bindings are on. failing python tests with shared libs if python bindings are on. Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant