Most example configs do not load as written: 361 hard-code bng_command to the original author's machine and 280 MSA configs have a comma in output_dir

未关闭
#1,003 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
半天
新手友好度
62/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
python
领域
devtools, testing

调研方向

Start with the bng_command lines in examples/COVID19forecasting_aMCMC/WindyCity/m3.conf and the comma-containing output_dir lines in examples/Mallela2022MSAs/. Run the config loader on one file from its own folder to reproduce the BNG2.pl and output_dir errors. Remove the bng_command lines, fix the output_dir and model = values, then find the four remaining failing configs (three Degranulation configs and one nested Louisville model path). Done when a new test that loads every examples/**/.conf from its own folder passes, with BNG2.pl required.

由索引模型根据 Issue 内容生成。

描述

Most of the example configs under examples/ cannot be loaded as written, on any machine but the one each was written on. Measured on main (68fb0d1d), with find examples -name '*.conf' giving 553 configs:

  1. 361 set bng_command to a path on the original author's machine.

    • 335 use bng_command = /usr/local/anaconda3/bin/BNG2.pl.
    • 26 use bng_command = /projects/posner_lab/BioNetGen-2.3.1/BNG2.pl.

    An explicit bng_command overrides BNGPATH, so each of these stops at load with "The BioNetGen simulator (BNG2.pl) was not found at the specified location". That's right for a user's own config, since a wrong explicit path should not be silently replaced, but it makes the examples unusable as shipped. Example: examples/COVID19forecasting_aMCMC/WindyCity/m3.conf.

  2. 280 (examples/Mallela2022MSAs/*) have a comma in output_dir. For example, output_dir = Akron, OH_output is refused by the parser: "output_dir should be specified in the format 'output_dir=s'". These also carry the bng_command above.

  3. 4 fail for other reasons: three Degranulation configs list their data files separated by spaces on the model = line, and one has a nested Louisville model path.

With bng_command and output_dir neutralized and each config loaded from its own folder, 549 of 553 load (the independent review of #1001 ran this sweep). So items 1 and 2 account for nearly every failure.

Expected

  • Remove the bng_command lines. BNGPATH, or bngsim under bngl_backend = auto, covers them.
  • Give the MSA examples output_dir values without commas, and check their model = lines too, since commas there also separate data files.
  • Fix the four remaining configs.
  • Add a test that loads every examples/**/*.conf from its own folder (BNG2.pl may be required), so the examples cannot drift again. The #994 and #1001 reviews each wrote such a sweep in their probes, so it could be lifted from there.
主要语言
Python
星标
25
派生
25
平均合并
4 小时 5 分钟
30 天内合并 PR
10

环境准备

  • 提供 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

lanl/PyBNF 的其他 Issue

查看 lanl/PyBNF 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。