precice / precice/tutorials

Improve error when executing `run.sh` from wrong directory

Open
#605 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
142
Forks
167
Avg merge
20h 24m
Merged PRs (30d)
11

Description

I think for every (?) run.sh file it is necessary to run it from the folder of the participant (e.g. partitioned-heat-conduction/dirichlet-fenics). Running ./dirichlet-fenics/run.sh from partitioned-heat-conduction is incorrect and results in the error:

ERROR: Could not open requirements file: [Errno 2] No such file or directory: '../solver-fenics/requirements.txt'

Is it possible to improve this error? Basically we have to make sure that we always execute run.sh from its parent directory.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the participant run.sh files, especially partitioned-heat-conduction/dirichlet-fenics/run.sh, and reproduce the command from partitioned-heat-conduction. Determine how the scripts handle being launched outside their parent directory. Done means an incorrect invocation produces a clearer error explaining the required working directory.

Written by the indexing model from the issue text.

Assessment

Tech stack
shell
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.