Closed HTJense closed 2 months ago
Thanks for the report! I'd swear I tested it thoroughly with 3.9 and 3.11, including the -h command. But obviously not... Will fix soon. Is your test above for 3.9?
We encountered this error on 3.9.2 (on our cluster, where we initially found that trying to run chains did nothing), and the example above provided no output for me in version 3.10.12 (on my work device).
Probably just missing call to run_command, try https://github.com/CobayaSampler/cobaya/commit/374b6f31cf3e05a5ccab57ae2df8ccfb93537866 ?
Closing assuming OK, please reopen if not.
I referred before in #348 that invocation of
python -m cobaya run
instead ofcobaya-run
was not working in 3.9 (due to setup problems on our cluster, the latter doesn't always seem to work in our case).This commit seems to be designed to re-create the invocation option through python, and the comment in the main file indicates that
python -m cobaya <command> [args]
should have the same effect ascobaya-<command> [args]
.This seems however, not to be the case, and using
python -m cobaya <command>
appears to have no effect at all.Example steps to reproduce:
python -m pip install cobaya==3.4.1
python -m cobaya run -h
python -m pip install cobaya==3.5
python -m cobaya run -h
Step 2 will produce a help message as output for v3.4.1, whereas step 4 will not do so for v3.5, despite the code of the main file indicating that it should. Similar actions such as attempting to run a yaml file will cause the program to exit gracefully without running any code, it seems.