biosimulators / Biosimulators_tellurium

tellurium biochemical network simulation program via BioSimulators-compliant command-line interface and Docker container
https://docs.biosimulators.org/Biosimulators_tellurium
MIT License
1 stars 2 forks source link

Tests not run with latest roadrunner #11

Closed luciansmith closed 1 year ago

luciansmith commented 1 year ago

The tests are failing, even when I run a new github action telling it to use tellurium 2.2.8, and updating the requirements.txt file to point to roadrunner 2.4.0:

https://github.com/biosimulators/Biosimulators_tellurium/actions/runs/4704781270/jobs/8344706457

but the reason they're failing is because of something I fixed in September of 2021: allowing negative start times in a simulation run. This means that something isn't being updated somewhere, despite everything claiming that roadrunner 2.4.0 is being used. Somehow, it's not?

The error message in the tests is:

E       RuntimeError: duration, startTime and steps must be non-negative

and in September of 2021, I changed that message to:

"duration and steps must be non-negative"

I can confirm that if I load roadrunner and tellurium on Python 3.9, and run the following, I get no errors:

import tellurium as te
rr = te.loada("species S1=3")
rr.simulate(-3, 10, 10)

while I do get the revised error with:

import tellurium as te
rr = te.loada("species S1=3")
rr.simulate(-3, -10, 10)
RuntimeError: duration and steps must be non-negative

@jonrkarr @bilalshaikh42 , any hints? Thank you!

jonrkarr commented 1 year ago

The tests do seem to be using tellurium 2.2.8 and libroadrunner 2.4.0. Here's the lines from the log that confirm this

Requirement already satisfied: tellurium>=2.2.1 in /opt/hostedtoolcache/Python/3.9.16/x64/lib/python3.9/site-packages (from biosimulators-tellurium==0.1.25) (2.2.8) Requirement already satisfied: libroadrunner>=2.1.2 in /opt/hostedtoolcache/Python/3.9.16/x64/lib/python3.9/site-packages (from biosimulators-tellurium==0.1.25) (2.4.0)

luciansmith commented 1 year ago

I know! But the error message doesn't exist in libroadrunner 2.4.0. So I don't know what's going on.

luciansmith commented 1 year ago

I tried today to put in a message in the error that would tell us the version number of roadrunner... only to be thwarted by github actions itself no longer working. Something got updated somewhere, and now everything is broken:

Friday run, which fails at the tests: https://github.com/biosimulators/Biosimulators_tellurium/actions/runs/4704819940/jobs/8344775168

First run today, which fails much earlier, at 'install the package': https://github.com/biosimulators/Biosimulators_tellurium/actions/runs/4722113676/jobs/8376265185

The first error message is ' /opt/hostedtoolcache/Python/3.9.16/x64/bin/python: No module named pip'. This is truly bizarre, as the previous command literally uses pip!

Weirdly, I noticed that the 'install pip and setuptools' line first updated pip, which installed v23.1. Then it installs setuptools... and complained about pip only being at v22.0.4. I added the line 'python -m pip --version' which claimed it was 23.1 I added a second 'pip install --upgrade pip', which re-installed 23.1, replacing 22.0.4. Again. On Friday, that same step said that pip was at 23.0.1, and didn't complain about being out of date when installing setuptools. So pip now how 23.1 (higher than 23.0.1), but also somehow downgraded to 22.0.4. Argh.

I feel like this must mean that there are multiple python install directories, which are semi-randomly getting used. Alternatively, github might be trying to run things in parallel, and confusing itself? I tried combining and breaking apart the pip installs to see if that changed anything, but it didn't.

I knew that 'biomodels-qc' had been run recently, so I re-ran that, and confirmed that it now breaks:

Original ('Attempt #1'): https://github.com/biosimulations/biomodels-qc/actions/runs/4641088733/jobs/8213701498 Today ('Attempt #2'): https://github.com/biosimulations/biomodels-qc/actions/runs/4641088733/jobs/8376894388

If there are multiple versions of python showing up, that might also explain how roadrunner is one version in one place, and a different version somewhere else?

I also can't find anything relevant on google, though I would have imagined that if multiple repositories are breaking for us that used to work, other people would have the same problem? Maybe google isn't good enough for late-breaking bug reports.

Any insights/workaround ideas appreciated!

luciansmith commented 1 year ago

OK, original problem fixed: because rrplugins was listed in the requirements, it was installing an ancient version of rrplugins that not only didn't work, but also managed to override roadrunner itself with an equally old version. Dropping it from the requirements list fixed everything.

The other problem is that pip 23.1 breaks things, but if we don't upgrade it, we don't hit the problem.