Skip to content

ci: weekly Python matrix; cull the Nextflow runtime tests - #594

Merged
vjaganat90 merged 6 commits into
PolusAI:masterfrom
vjaganat90:ci/python-matrix-weekly
Nov 12, 2026
Merged

vjaganat90 merged 6 commits into
PolusAI:masterfrom
vjaganat90:ci/python-matrix-weekly

Conversation

@vjaganat90

@vjaganat90 vjaganat90 commented Nov 12, 2026 •

Copy link
Copy Markdown
Member

What

  • lint_and_test.yml can be called, with the Python and the OSes as inputs; a dispatch from Branch Dispatch runs as before, on 3.11, Ubuntu and Windows. Only a dispatch replies to its sender.
  • New lane, Python Matrix Weekly: on Fridays it calls Lint And Test on Ubuntu for Python 3.11, 3.12, 3.13 and 3.14. A pull request that edits it runs it.
  • The Nextflow runtime tests shrink from 50 test functions to 24: five deleted, ten folded into the scatter and staged-path properties as examples, ten moved to runs.yaml cases. The case runner reads scalar outputs and gains inputs, params and never.

Why

  • Every lane runs one Python, and Lint And Test needs no GPU. The deleted runs repeat Run Workflows' corpus or test Nextflow's own behaviour; the folded ones are fixed shapes of what the properties draw.

@vjaganat90
vjaganat90 force-pushed the ci/python-matrix-weekly branch from f3b05cc to 3576dee Compare November 12, 2026 02:57
@vjaganat90 vjaganat90 changed the title ci: a weekly lane runs Sophios on Python 3.11-3.14 ci: Lint And Test runs weekly on Python 3.11-3.14 Nov 12, 2026
@vjaganat90
vjaganat90 force-pushed the ci/python-matrix-weekly branch from 3576dee to cbf6740 Compare November 12, 2026 04:48
@vjaganat90 vjaganat90 changed the title ci: Lint And Test runs weekly on Python 3.11-3.14 ci: weekly Python matrix; cull the Nextflow runtime tests Nov 12, 2026

@darkclad darkclad left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CI restructuring looks good. Python Matrix Weekly passed on 3.11–3.14, and the Nextflow runtime step ran 64 tests on each, including the two Docker ones. The schema step's removal is backed by test_lang_schema.py, and test_run_workflows_on_push[test_rand_fail] passes under cwltool with --partial_failure_enable (run locally in WSL, since this PR's Run Workflows dispatch was cancelled).

Three places where the cull lost an assertion are inline. Two smaller notes:

  • docs/validation.md (the corpus bullet, ~line 57) still says a push skips run_partial_failures; after 2757275 the push runs them with --partial_failure_enable.
  • The dispatched Lint And Test for this head failed only because dispatches use master's workflow file, whose Validate sophios Python API Workflows step now selects no test (exit 5). Not a defect here; it clears once master carries the new file.

Comment thread tests/core/nextflow/test_runtime.py Outdated
}
assert places == {True: "container\n", False: "host\n"}
assert sorted(task.read_text(encoding="utf-8") for task in (tmp_path / "work").rglob("place.txt")) == [
"container\n", "host\n"]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The old assertion tied each place.txt to its task's .command.run ({True: "container ", False: "host "}). The sorted pair still passes if the lowering swaps the two, i.e. puts the plain tool in the container and the Docker tool on the host. The workflow already declares container_place and host_place, so reading them through _recorded(result.stdout) would restore the mapping without the .command.run scan.

@vjaganat90 vjaganat90 Nov 12, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. The sorted pair would pass if the lowering put the plain tool in the container. The test now reads container_place and host_place from the recorded outputs and compares them as a mapping to "container\n" and "host\n", so a swap fails it. The Docker test passes.

Fixed in b87d1bc.

Comment thread tests/core/nextflow/test_runtime.py Outdated
output = f"stdout:\n{result.stdout}\nstderr:\n{result.stderr}"
if "fails" in case:
assert result.returncode != 0 and (case["fails"] is True or case["fails"] in output), output
assert not [name for name in case.get("never", []) if list((tmp_path / "work").rglob(name))]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

never is only read in the fails branch, so a passing case that lists it is silently unchecked. That matters for skipped_step_feeds_an_optional_input (runs.yaml:335), which replaced W8/W9: the old test asserted not _ran(tmp_path, "out.txt"), i.e. the skipped step made no task. A null produce~text doesn't prove that, since a task that ran with its output dropped also reads null. Moving this check after the if/else and adding never: [out.txt] to that case keeps the "no task" property.

@vjaganat90 vjaganat90 Nov 12, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. A null output also shows up when a task ran and dropped its output. The never check now runs for passing cases as well as failing ones, and skipped_step_feeds_an_optional_input lists out.txt, so the skipped step is shown to make no task.

Fixed in c437a43.

Comment thread tests/core/nextflow/test_runtime.py Outdated
@given(_staged_paths())
@example((False, True, [("source[0]*.txt", "alpha\n"), ("source[0]*.txt", "beta\n")], True))
@example((False, True, [], True))
@example((True, True, [("plain.txt", "inner\n"), ("plain.txt", "inner\n")], False))

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both directories hold inner , so staging element 0 twice, or reversing the order, still yields inner inner . The deleted test pinned distinct per-element staging names; here distinct texts (e.g. "first ", "second ") would make the oracle catch both.

@vjaganat90 vjaganat90 Nov 12, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Equal texts let a duplicate or reversed staging pass. The two directories in that example now hold "first\n" and "second\n", so either mistake changes the output.

Fixed in 638f956.

@vjaganat90
vjaganat90 force-pushed the ci/python-matrix-weekly branch from cbf6740 to 41ec9f7 Compare November 12, 2026 16:14
@vjaganat90

vjaganat90 commented Nov 12, 2026 •

Copy link
Copy Markdown
Member Author

Thanks. The three inline points are fixed in their threads. docs/validation.md now says the push runs the run_partial_failures workflows with --partial_failure_enable instead of skipping them. The Lint And Test failure comes from dispatches using master's workflow file, so I'm making no change for it.

Fixed in 7fc44a5.

@darkclad darkclad left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. The three inline fixes and the docs/validation.md update check out. Widening the Nextflow step to -m "not nextflow_corpus" also brings back the compile-side tests that nextflow.yml's 3.12 suite used to run: 1360+ pass on each of 3.11–3.14, in under 10 minutes.

@vjaganat90
vjaganat90 force-pushed the ci/python-matrix-weekly branch from 7fc44a5 to c937729 Compare November 12, 2026 18:31
Lint And Test takes its Python and OSes as inputs when called; the new weekly lane calls it on Ubuntu for each supported Python.
The deleted runs repeat Run Workflows' corpus or test Nextflow's own behaviour; the CLI target keeps its no-autogenerated check.
Ten hand-written pipelines become runs.yaml cases. The case runner now
reads scalar outputs and gains the inputs, params and never keys; the
recorded-output test stays hand-written.
The scatter property now draws int scatters, array broadcasts, merged and shared sources and shared output names; nine hand-written runs became its examples.
The staged-path property now carries the two-directory array as an example; its oracle reads every element, so the hand-written test and its staging-name assert were redundant.
The push lane runs run_partial_failures workflows with --partial_failure_enable.
@vjaganat90
vjaganat90 force-pushed the ci/python-matrix-weekly branch from c937729 to 1bbf470 Compare November 12, 2026 18:33
@vjaganat90
vjaganat90 merged commit f0a4850 into PolusAI:master Nov 12, 2026
3 checks passed
@vjaganat90
vjaganat90 deleted the ci/python-matrix-weekly branch November 12, 2026 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants