From 5ee5c5a2f2b17563117b30f757d065e25b1f4b58 Mon Sep 17 00:00:00 2001 From: erik pernod Date: Tue, 15 Sep 2026 21:41:33 +0200 Subject: [PATCH 1/6] =?UTF-8?q?=EF=BB=BF[scenes]=20Update=20scenes=20to=20?= =?UTF-8?q?be=20compatible=20with=20changes=20in=20SOFA=20regarding=20Inte?= =?UTF-8?q?grationScheme?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- examples/ArticulatedToolManager.scn | 4 ++-- examples/BeatingCube.scn | 6 +++--- examples/BeatingCube_moving.scn | 6 +++--- examples/CollisionDetectionDisplay.scn | 14 +++++++------- examples/Cube_AdvCarvingTexcoords.scn | 4 ++-- examples/Cube_AdvCarvingWithRefinement.scn | 4 ++-- .../Cube_AdvCarvingWithRefinementTexcoords.scn | 4 ++-- examples/Cube_Carving.scn | 4 ++-- examples/Cube_CarvingWithPenetration.scn | 4 ++-- examples/Geomagic-AdvCarving.scn | 6 +++--- examples/Geomagic-AdvCarvingWithRefinement.scn | 4 ++-- examples/Geomagic-AdvCarvingWithTexCoords.scn | 6 +++--- examples/Geomagic_RigidCube_AdvCarving.scn | 4 ++-- .../SubdivisionController_CutFromPlane.scn | 4 ++-- .../SubdivisionController_CutWithSurface.scn | 4 ++-- .../SubdivisionController_RefineFullMesh.scn | 4 ++-- .../SubdivisionController_RefineTetrahedra.scn | 4 ++-- examples/NearestTexcoordsMap.scn | 10 +++++----- examples/NearestTexcoordsMap_options.scn | 10 +++++----- examples/ProximityOscillatorConstraint.scn | 6 +++--- examples/RigidCube_CarvingWithRefinement.scn | 4 ++-- examples/TetrahedronBeamMultiMaterials.scn | 10 +++++----- .../Triangle2RefinedTriangleTopologicalMapping.scn | 6 +++--- examples/VirtualTools.xml | 8 ++++---- extensions/MeshRefinement/README.md | 2 +- .../TetrahedronSubdivisionController_test.cpp | 2 +- .../tests/scenes/SimpleCubeRefinement.scn | 4 ++-- .../scenes/TetrahedronCutting_Advanced_01.scn | 4 ++-- extensions/MeshRefinement/tests/scenes/headers.xml | 2 +- scripts/changeComponentName_script.py | 2 +- scripts/oglLoader_script.py | 2 +- 31 files changed, 79 insertions(+), 79 deletions(-) diff --git a/examples/ArticulatedToolManager.scn b/examples/ArticulatedToolManager.scn index f6c2cc3..1506ddc 100644 --- a/examples/ArticulatedToolManager.scn +++ b/examples/ArticulatedToolManager.scn @@ -19,7 +19,7 @@ - + @@ -57,7 +57,7 @@ - + diff --git a/examples/BeatingCube.scn b/examples/BeatingCube.scn index 2691583..dce6d75 100644 --- a/examples/BeatingCube.scn +++ b/examples/BeatingCube.scn @@ -11,7 +11,7 @@ - + @@ -34,8 +34,8 @@ - - + + diff --git a/examples/BeatingCube_moving.scn b/examples/BeatingCube_moving.scn index 2e9fa6c..4bf910e 100644 --- a/examples/BeatingCube_moving.scn +++ b/examples/BeatingCube_moving.scn @@ -11,7 +11,7 @@ - + @@ -34,8 +34,8 @@ - - + + diff --git a/examples/CollisionDetectionDisplay.scn b/examples/CollisionDetectionDisplay.scn index 0a901c6..1334de4 100644 --- a/examples/CollisionDetectionDisplay.scn +++ b/examples/CollisionDetectionDisplay.scn @@ -8,7 +8,7 @@ - + @@ -33,8 +33,8 @@ - - + + @@ -55,8 +55,8 @@ - - + + @@ -77,8 +77,8 @@ - - + + diff --git a/examples/Cube_AdvCarvingTexcoords.scn b/examples/Cube_AdvCarvingTexcoords.scn index d0bd6bc..bc2bf62 100644 --- a/examples/Cube_AdvCarvingTexcoords.scn +++ b/examples/Cube_AdvCarvingTexcoords.scn @@ -12,7 +12,7 @@ - + @@ -34,7 +34,7 @@ - + - + @@ -35,7 +35,7 @@ - + - + @@ -32,7 +32,7 @@ - + - + @@ -31,7 +31,7 @@ - + diff --git a/examples/Cube_CarvingWithPenetration.scn b/examples/Cube_CarvingWithPenetration.scn index 2c141ee..c9b5f4b 100644 --- a/examples/Cube_CarvingWithPenetration.scn +++ b/examples/Cube_CarvingWithPenetration.scn @@ -12,7 +12,7 @@ - + @@ -33,7 +33,7 @@ - + diff --git a/examples/Geomagic-AdvCarving.scn b/examples/Geomagic-AdvCarving.scn index cb7cf04..d734644 100644 --- a/examples/Geomagic-AdvCarving.scn +++ b/examples/Geomagic-AdvCarving.scn @@ -19,7 +19,7 @@ - + @@ -61,7 +61,7 @@ - + @@ -95,7 +95,7 @@ - + diff --git a/examples/Geomagic-AdvCarvingWithRefinement.scn b/examples/Geomagic-AdvCarvingWithRefinement.scn index 6359615..5ed7e78 100644 --- a/examples/Geomagic-AdvCarvingWithRefinement.scn +++ b/examples/Geomagic-AdvCarvingWithRefinement.scn @@ -19,7 +19,7 @@ - + @@ -79,7 +79,7 @@ - + diff --git a/examples/Geomagic-AdvCarvingWithTexCoords.scn b/examples/Geomagic-AdvCarvingWithTexCoords.scn index 1d631ff..caf8e90 100644 --- a/examples/Geomagic-AdvCarvingWithTexCoords.scn +++ b/examples/Geomagic-AdvCarvingWithTexCoords.scn @@ -19,7 +19,7 @@ - + @@ -61,7 +61,7 @@ - + @@ -95,7 +95,7 @@ - + diff --git a/examples/Geomagic_RigidCube_AdvCarving.scn b/examples/Geomagic_RigidCube_AdvCarving.scn index f6f2166..24d5725 100644 --- a/examples/Geomagic_RigidCube_AdvCarving.scn +++ b/examples/Geomagic_RigidCube_AdvCarving.scn @@ -19,7 +19,7 @@ - + @@ -79,7 +79,7 @@ - + diff --git a/examples/MeshRefinement/SubdivisionController_CutFromPlane.scn b/examples/MeshRefinement/SubdivisionController_CutFromPlane.scn index d842030..04eb624 100644 --- a/examples/MeshRefinement/SubdivisionController_CutFromPlane.scn +++ b/examples/MeshRefinement/SubdivisionController_CutFromPlane.scn @@ -17,7 +17,7 @@ - + @@ -41,7 +41,7 @@ - + diff --git a/examples/MeshRefinement/SubdivisionController_CutWithSurface.scn b/examples/MeshRefinement/SubdivisionController_CutWithSurface.scn index d3b292a..1cd7492 100644 --- a/examples/MeshRefinement/SubdivisionController_CutWithSurface.scn +++ b/examples/MeshRefinement/SubdivisionController_CutWithSurface.scn @@ -22,7 +22,7 @@ - + @@ -47,7 +47,7 @@ - + diff --git a/examples/MeshRefinement/SubdivisionController_RefineFullMesh.scn b/examples/MeshRefinement/SubdivisionController_RefineFullMesh.scn index 858b743..0361174 100644 --- a/examples/MeshRefinement/SubdivisionController_RefineFullMesh.scn +++ b/examples/MeshRefinement/SubdivisionController_RefineFullMesh.scn @@ -16,7 +16,7 @@ - + @@ -40,7 +40,7 @@ - + diff --git a/examples/MeshRefinement/SubdivisionController_RefineTetrahedra.scn b/examples/MeshRefinement/SubdivisionController_RefineTetrahedra.scn index 445bd8e..b48f4d9 100644 --- a/examples/MeshRefinement/SubdivisionController_RefineTetrahedra.scn +++ b/examples/MeshRefinement/SubdivisionController_RefineTetrahedra.scn @@ -15,7 +15,7 @@ - + @@ -39,7 +39,7 @@ - + diff --git a/examples/NearestTexcoordsMap.scn b/examples/NearestTexcoordsMap.scn index 5d2beee..b506a17 100644 --- a/examples/NearestTexcoordsMap.scn +++ b/examples/NearestTexcoordsMap.scn @@ -15,7 +15,7 @@ - + @@ -35,8 +35,8 @@ - - + + @@ -69,8 +69,8 @@ - - + + diff --git a/examples/NearestTexcoordsMap_options.scn b/examples/NearestTexcoordsMap_options.scn index 1b696d1..a98d55e 100644 --- a/examples/NearestTexcoordsMap_options.scn +++ b/examples/NearestTexcoordsMap_options.scn @@ -15,7 +15,7 @@ - + @@ -35,8 +35,8 @@ - - + + @@ -69,8 +69,8 @@ - - + + diff --git a/examples/ProximityOscillatorConstraint.scn b/examples/ProximityOscillatorConstraint.scn index f1c3e82..926a7b2 100644 --- a/examples/ProximityOscillatorConstraint.scn +++ b/examples/ProximityOscillatorConstraint.scn @@ -11,7 +11,7 @@ - + @@ -44,8 +44,8 @@ - - + + diff --git a/examples/RigidCube_CarvingWithRefinement.scn b/examples/RigidCube_CarvingWithRefinement.scn index b8e44fe..898930b 100644 --- a/examples/RigidCube_CarvingWithRefinement.scn +++ b/examples/RigidCube_CarvingWithRefinement.scn @@ -8,7 +8,7 @@ - + @@ -30,7 +30,7 @@ - + - + - + @@ -48,8 +48,8 @@ - - + + diff --git a/examples/VirtualTools.xml b/examples/VirtualTools.xml index dd3775e..0af897f 100644 --- a/examples/VirtualTools.xml +++ b/examples/VirtualTools.xml @@ -28,7 +28,7 @@ - + @@ -47,7 +47,7 @@ - + @@ -68,7 +68,7 @@ - + @@ -85,7 +85,7 @@ - + diff --git a/extensions/MeshRefinement/README.md b/extensions/MeshRefinement/README.md index a313b48..f2da7b8 100644 --- a/extensions/MeshRefinement/README.md +++ b/extensions/MeshRefinement/README.md @@ -61,7 +61,7 @@ modifier and the geometry algorithms. It finds them by itself; there is nothing ```xml - + diff --git a/extensions/MeshRefinement/tests/TetrahedronSubdivisionController_test.cpp b/extensions/MeshRefinement/tests/TetrahedronSubdivisionController_test.cpp index 6e2d901..7627bb2 100644 --- a/extensions/MeshRefinement/tests/TetrahedronSubdivisionController_test.cpp +++ b/extensions/MeshRefinement/tests/TetrahedronSubdivisionController_test.cpp @@ -77,7 +77,7 @@ class TetrahedronSubdivisionController_test : public sofa::testing::BaseTest "Sofa.Component.Mapping.Linear", "Sofa.Component.Mass", "Sofa.Component.MechanicalLoad", - "Sofa.Component.ODESolver.Backward", + "Sofa.Component.IntegrationScheme.Backward", "Sofa.Component.SceneUtility", "Sofa.Component.SolidMechanics.FEM.Elastic", "Sofa.Component.StateContainer", diff --git a/extensions/MeshRefinement/tests/scenes/SimpleCubeRefinement.scn b/extensions/MeshRefinement/tests/scenes/SimpleCubeRefinement.scn index 5dcc31e..ede9643 100644 --- a/extensions/MeshRefinement/tests/scenes/SimpleCubeRefinement.scn +++ b/extensions/MeshRefinement/tests/scenes/SimpleCubeRefinement.scn @@ -4,8 +4,8 @@ - - + + diff --git a/extensions/MeshRefinement/tests/scenes/TetrahedronCutting_Advanced_01.scn b/extensions/MeshRefinement/tests/scenes/TetrahedronCutting_Advanced_01.scn index 6b9e13a..18e6f11 100644 --- a/extensions/MeshRefinement/tests/scenes/TetrahedronCutting_Advanced_01.scn +++ b/extensions/MeshRefinement/tests/scenes/TetrahedronCutting_Advanced_01.scn @@ -16,8 +16,8 @@ - - + + diff --git a/extensions/MeshRefinement/tests/scenes/headers.xml b/extensions/MeshRefinement/tests/scenes/headers.xml index af78ba1..ec443f0 100644 --- a/extensions/MeshRefinement/tests/scenes/headers.xml +++ b/extensions/MeshRefinement/tests/scenes/headers.xml @@ -11,7 +11,7 @@ - + diff --git a/scripts/changeComponentName_script.py b/scripts/changeComponentName_script.py index 7c30efc..ebf8344 100644 --- a/scripts/changeComponentName_script.py +++ b/scripts/changeComponentName_script.py @@ -7,7 +7,7 @@ print (str(sys.argv[1])) #CollisionGroup DefaultCollisionGroupManager -#EulerImplicit EulerImplicitSolver +#EulerImplicit EulerImplicitIntegrationScheme #TriangleModel TriangleCollisionModel #LineModel LineCollisionModel #PointModel PointCollisionModel diff --git a/scripts/oglLoader_script.py b/scripts/oglLoader_script.py index 0ec1491..e7728a9 100644 --- a/scripts/oglLoader_script.py +++ b/scripts/oglLoader_script.py @@ -44,7 +44,7 @@ for key, value in includes.items(): print("----------------") print("Before: ", key, value) - line = value.replace("SofaExplicitOdeSolver", "Sofa.Component.ODESolver.Forward") + line = value.replace("SofaExplicitOdeSolver", "Sofa.Component.IntegrationScheme.Forward") #line = value.replace(" Date: Mon, 5 Oct 2026 10:03:39 +0200 Subject: [PATCH 2/6] add other scene --- examples/Barycentric_Carving.scn | 69 ++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 examples/Barycentric_Carving.scn diff --git a/examples/Barycentric_Carving.scn b/examples/Barycentric_Carving.scn new file mode 100644 index 0000000..61fd784 --- /dev/null +++ b/examples/Barycentric_Carving.scn @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 660b74caa724c204369decb410f4ab6d6c5ddf1e Mon Sep 17 00:00:00 2001 From: epernod Date: Mon, 5 Oct 2026 16:09:10 +0200 Subject: [PATCH 3/6] up python version --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 52e4bd8..04bf16b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -191,7 +191,7 @@ jobs: - name: Setup Python uses: actions/setup-python@v5 with: - python-version: '3.10' + python-version: '3.13' - name: Install dependencies shell: bash From 7b9d1daffa611e6293bb4daa98d77e5230a5c775 Mon Sep 17 00:00:00 2001 From: epernod Date: Wed, 14 Oct 2026 11:33:06 +0200 Subject: [PATCH 4/6] add debug log --- .github/workflows/ci.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 04bf16b..5f675e1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -215,6 +215,27 @@ jobs: echo "SOFAPYTHON3_ROOT=$SP3" >> $GITHUB_ENV fi + - name: Debug python environment + shell: bash + run: | + set +e + echo "--- interpreter" + which python; python --version + python -c "import sys, sysconfig; print(sys.executable); print('EXT_SUFFIX =', sysconfig.get_config_var('EXT_SUFFIX'))" + echo "--- env" + echo "SOFA_ROOT=$SOFA_ROOT" + echo "SOFAPYTHON3_ROOT=$SOFAPYTHON3_ROOT" + echo "PYTHONPATH=$PYTHONPATH" + echo "--- sys.path" + python -c "import sys; print('\n'.join(sys.path))" + echo "--- compiled modules shipped in the Sofa package" + ls -la "$SOFA_ROOT/plugins/SofaPython3/lib/python3/site-packages/Sofa/" | grep -Ei '\.(so|pyd)' + echo "--- python libs shipped with / linked by SofaPython3" + ls "$SOFA_ROOT/plugins/SofaPython3/bin" "$SOFA_ROOT/plugins/SofaPython3/lib" 2>/dev/null | grep -i python + echo "--- direct import attempt" + python -c "import Sofa.Helper; print('Sofa.Helper OK:', Sofa.Helper.__file__)" + exit 0 + ################### Regression tests ################### - name: Fetch SofaRegressionProgram shell: bash From 488a54c95ce51aee6bc61dae94ab8ea4ddc506c0 Mon Sep 17 00:00:00 2001 From: epernod Date: Wed, 14 Oct 2026 11:43:23 +0200 Subject: [PATCH 5/6] up python version to match the SOFA one --- .github/workflows/ci.yml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5f675e1..b09e83c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -188,10 +188,25 @@ jobs: echo "LD_LIBRARY_PATH=$LP:${LD_LIBRARY_PATH:-}" >> $GITHUB_ENV ####################### Setup Python ####################### + # SofaPython3's compiled modules only load in the exact python version SOFA + # was built against (ABI tag in their filename: cpython-312 / cp312), so read + # it from the binaries instead of hardcoding it. + - name: Detect SOFA python version + id: pyver + shell: bash + run: | + set -euo pipefail + SP="$SOFA_ROOT/plugins/SofaPython3/lib/python3/site-packages/Sofa" + TAG=$(ls "$SP" | grep -oE '^Helper\.(cpython-|cp)3[0-9]+' | grep -oE '3[0-9]+$' | head -n1) + [[ -n "$TAG" ]] || { echo "::error::Could not detect python ABI tag from $SP"; ls -la "$SP"; exit 1; } + VERSION="3.${TAG:1}" + echo "SOFA was built against python $VERSION" + echo "version=$VERSION" >> $GITHUB_OUTPUT + - name: Setup Python uses: actions/setup-python@v5 with: - python-version: '3.13' + python-version: ${{ steps.pyver.outputs.version }} - name: Install dependencies shell: bash From 9498da39d8cab0f2490f1aeae3cdeb86f7a5f953 Mon Sep 17 00:00:00 2001 From: epernod Date: Wed, 14 Oct 2026 12:06:29 +0200 Subject: [PATCH 6/6] log issue --- .github/workflows/ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b09e83c..9f93997 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -267,6 +267,11 @@ jobs: - name: Run regression shell: bash + env: + # The regression program captures each scene's output with + # subprocess.run(text=True), which decodes with the locale encoding: + # cp1252 on Windows, which chokes on SOFA's UTF-8 logs. + PYTHONUTF8: '1' run: | set -euo pipefail cd "$WORKSPACE_SRC_PATH"