Skip to content

Adding code_aster as a new solver - #21

Merged
ulysse-bonneau-simvia merged 21 commits into
mainfrom
feat/add_codeaster
Aug 3, 2026
Merged

Adding code_aster as a new solver#21
ulysse-bonneau-simvia merged 21 commits into
mainfrom
feat/add_codeaster

Conversation

@maxime-simvia

Copy link
Copy Markdown
Collaborator

What

Implementation of the connector with the open-source FEA solver code_aster

Why

New possibility for DOE of finite element analysis engineer

How to test

  • pull code_aster docker image (link to Simvia Dockerhub5)
  • test/unit
  • test/integration
  • try to run examples/codeaster_cube

Checklist

  • Tests pass locally (pytest -q)
  • Frontend builds (cd frontend && pnpm build)
  • No linting errors (ruff check . && ruff format --check .)
  • frontend/dist/ is up-to-date (committed after pnpm build)

maxime-simvia and others added 21 commits July 28, 2026 16:18
Revert the loosening that defaulted docker_image to an empty string in
docker.py and blanked it for native/singularity selections: a missing
image should fail loudly at call time, not produce a broken docker run.
shared_dir_symlink_mounts skips entries that are not symlinks, so pairing
its result with shared_dir_names by index could bind a RESU target at the
case MESH path when only one of the two was a symlink.
Thread start_time through detect_outcome like the code_saturne adapter,
so a relaunch is not immediately marked DONE/FAILED from the stale
RESU/LOGS/run_solver.log of the prior run. Also replace the glob and the
unreachable bare raise with a direct path check.
find_setup_file no longer caches the export path on the memoized adapter
instance; build_run_command discovers it in the case directory instead,
so a case whose export is not named study.export launches correctly and
a missing export raises instead of silently creating an empty file. The
mess-file entry is only appended when the export does not already
declare one, so relaunches no longer accumulate duplicate lines.
Shell-quote host paths in the bash -c launch strings so runs
directories with spaces do not break or misdirect the docker/apptainer
invocations, collapse the cleanup into a single rm -rf (the previous
space-joined chain passed literal 'rm' and '-rf' as extra operands),
keep the apptainer tmp dir inside the case directory instead of the
user's home, and reject incomplete singularity selections explicitly.
Replace the module docstring copy-pasted from the stub adapter with one
describing the actual behavior, align cleanenv's default with the
SolverAdapter protocol, make the unused run_argv return an empty argv
fragment instead of [''], and drop leftover commented-out code.
The test drives a real docker run of the multi-GB code_aster image, so
it broke pytest -q everywhere the image was not already pulled,
including CI. It now runs only when CSAUTO_CODE_ASTER_DOCKER_TESTS=1 is
set, waits long enough for a real container run, and the module
docstring no longer claims the tests use a python stub. Also apply the
ruff formatting the lint job flagged and drop the misleading saturne_bin
argument, which the docker runtime ignores.
Fix README typos and the duplicated study.comm entry in the expected
layout, use the actual directory name codeaster-cube, correct the
csauto.toml comments to match the localhost binding, raise a ValueError
with a message in the demo failure case, and add missing trailing
newlines.
ruff 0.16 started formatting python code fences in markdown files and
dedents the intentionally indented snippets in docs/superpowers, which
breaks their paste-into-function-body meaning and fails the CI format
check on files this branch never touched. Keep prose docs out of ruff's
scope instead of pinning the version.
@ulysse-bonneau-simvia
ulysse-bonneau-simvia merged commit f7d205b into main Aug 3, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants