Skip to content

Pin the generated commands for every analysis #420

Done

Description

@jtklein-agents

Parent

#419

What to build

Command pins for today's Run: tests that fix the exact argument lists a run produces, before any command building moves. No file under src/app/store/ other than the new test files changes.

One table of cases, shared by two test files, run through Vitest file snapshots (toMatchSnapshot). Each case builds a real Run with its real option objects (prior art: makeRun in src/app/store/Run.computeds.test.ts), sets the seed through setRandomSeed, a fixed output folder and a fixed thread count, and snapshots run.args.

Cases:

  • Every analysis, 8 for RAxML and 6 for RAxML-NG, in three variants:
    • Bare: a binary without the threads flag where one exists (raxmlHPC), every option off, default partition.
    • Full: a threaded binary, a loaded partition file, an outgroup, both constraint trees, branch lengths, SH-like values, a starting tree: whatever that analysis accepts.
    • Alternate: a non-default partition with no partition file, and SH-like values without branch lengths.
  • ModelTest-NG for a nucleotide, a protein and another data type.
  • ASTRAL with and without a loaded tree.
  • run.command and run.settingsFileContent once per binary (RAxML, RAxML-NG, ModelTest-NG, ASTRAL).

The first test file runs the table as the test setup has it (host not Windows, paths like /out). The second sets the host to Windows before importing the store and uses Windows-style paths (C:\out); Run.ts reads the Windows flag once at import. The binary list differs on Windows, so the table picks binaries that exist on the platform it runs for. Prior art for a Windows host: src/app/store/host.test.ts.

Check once, with a coverage provider installed temporarily, that every branch in raxmlArgs, raxmlNgArgs, modeltestNgArgs, astralArgs, the args getter and the command getter is hit by the two pin files. package.json and yarn.lock do not change. Add cases until it is. The RAxML-NG ancestral-states builder chooses its partition by "more than one alignment" (Run.ts:792); pin it as it is.

Acceptance criteria

  • One shared table of cases and two test files, one per platform
  • Every RAxML and RAxML-NG analysis has a bare, a full and an alternate pin on both platforms
  • ModelTest-NG has three pins (nucleotide, protein, other) and ASTRAL two (with and without a tree) on both platforms
  • run.command and run.settingsFileContent are pinned once per binary
  • Every pin uses a real Run with real option objects, a fixed seed, output folder and thread count; two runs of the suite produce identical snapshots
  • Every branch in the four builders, the args getter and the command getter is hit; the pull request states the coverage figures from the one-off run
  • package.json and yarn.lock are unchanged
  • No source file other than the new test files and their snapshots changes
  • yarn verify passes

Activity

  1. added
    ready-for-agent
    on Nov 27, 2026
  2. jtklein-agents commented on Nov 27, 2026

    @jtklein-agents
    OwnerAuthor

    Merged into spec/419-split-command-building-out-of-run-ts via #423 (97e7041). Open point: the one-off coverage run did not happen, so the branch-coverage criterion rests on two code readings; the commands to get the figures are in the pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ready-for-agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions