InstituteforDiseaseModeling / malaria-model_validation

1 stars 2 forks source link

Test failed with ValueError: You set param Infectious_Period_Distribution but it was disabled and is not being used. #37

Closed YeChen-IDM closed 2 years ago

YeChen-IDM commented 2 years ago
======================================================================
ERROR: test_submit_sim_demog (test_run_sims.RunSimsTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/malaria-model_validation/malaria-model_validation/tests/test_run_sims.py", line 73, in test_submit_sim_demog
    task.gather_transient_assets()
  File "/opt/hostedtoolcache/Python/3.9.13/x[64](https://github.com/InstituteforDiseaseModeling/malaria-model_validation/runs/7681212239?check_suite_focus=true#step:8:65)/lib/python3.9/site-packages/emodpy/emod_task.py", line 548, in gather_transient_assets
    self.config.parameters.finalize()
  File "/opt/hostedtoolcache/Python/3.9.13/x64/lib/python3.9/site-packages/emod_api/schema_to_class.py", line 1[67](https://github.com/InstituteforDiseaseModeling/malaria-model_validation/runs/7681212239?check_suite_focus=true#step:8:68), in finalize
    raise ValueError( f"You set param {nuke_key} but it was disabled and is not being used." )
ValueError: You set param Infectious_Period_Distribution but it was disabled and is not being used.
YeChen-IDM commented 2 years ago

Workaround provided from Jonathan: In the meantime, if one didn't want to wait for that change to come through, you can avoid the latest emod-api (1.26.x). Stick with 1.25.x.

The actual fix could be in Emod: https://github.com/InstituteforDiseaseModeling/DtkTrunk/blob/Malaria-Ongoing/Eradication/Infection.cpp#L60 https://github.com/InstituteforDiseaseModeling/DtkTrunk/blob/Malaria-Ongoing/Eradication/Infection.cpp#L55

YeChen-IDM commented 2 years ago

This test is fixed with the latest Emodpy-Malaria 2.3.6. Closed this ticket as resolved.