Repository navigation
Description
Tested v0.3.0's container passthrough against a real pinned image on AWS. It fails in two stages, and the second one is structural rather than a detail.
Setup: one rule, threads: 2, resources: mem_mb=4000, --default-storage-provider s3, --spawn-ttl 10m, --spawn-cost-limit 0.03, image quay.io/aarchbio/seqkit@sha256:5478aaad… (a cosign-signed bioconda-layer arm64 image).
Stage 1 — docker:// is not stripped → invalid reference format
Snakemake's container: conventionally carries the scheme; its own docs write container: "docker://biocontainers/fastqc:v0.11.9_cv8", and apptainer requires it. v0.3.0 passes the value straight into spec.container, and Docker rejects it:
spawn: [2026-10-04T04:27:55Z] image pull start
invalid reference format
spawn: [2026-10-04T04:27:55Z] image pull done; command start
docker: invalid reference format.
spawn: [2026-10-04T04:27:55Z] command exit rc=125
completion.json: exit_code: 125, state: failed, retry_class: app_error.
That one is a one-liner — strip a leading docker:// (and probably reject or document shub:///library://, which have no Docker equivalent). But fixing it only exposes stage 2.
Stage 2 — with a bare reference, the image pulls and then the preamble runs inside it
Same workflow, container: written without the scheme. The pull now succeeds, and then:
Status: Downloaded newer image for quay.io/aarchbio/seqkit@sha256:5478aaad…
spawn: [2026-10-04T04:32:58Z] image pull done; command start
snakemake-spawn: installing snakemake==9.27.0 snakemake-storage-plugin-s3==0.3.6
snakemake-spawn: installing python3.11 + snakemake...
snakemake-spawn: python3.11 install failed
spawn: [2026-10-04T04:32:59Z] command exit rc=1
This is the architecture problem, not a bug in the preamble. build_command_string bundles the preamble unconditionally and run_job always passes one, so with spec.container set, spawn runs this inside the science image:
mkdir -p <jobdir> && cd <jobdir> && { sudo dnf install -y python3.11 … } && python -m snakemake --mode remote …
A bioconda/conda image has no dnf, no sudo, and does not run as root — so the install fails, and even if it somehow succeeded, python -m snakemake --mode remote needs Snakemake inside an image that exists to ship one tool. spec.command here is a Snakemake re-invocation, not the rule's shell, so putting the science image in spec.container puts the wrong program in the wrong container.
I think my retraction comment on #12 and the implementation crossed — #15's body cites my apptainer reasoning as supporting the spec.container route, whereas the point I was making with it was the opposite: AL2023 having no apptainer is what makes spec.container look attractive and is also why it can't work, because the thing that must go in the container is the rule's shell, which only Snakemake-on-the-node can arrange. Entirely my fault if that read ambiguously. Either way the run settles it, which is better than either of us arguing from the source.
What the shapes are, as I see them
- Preamble + remote command on the host; only the rule's shell in a container. That is what
--software-deployment-method apptaineralready does, and Snakemake already forwards the setting (general_argscarriesdeployment_settings.deployment_method/apptainer_prefix/apptainer_args). The missing piece is a container runtime on the node — apptainer publishesel9aarch64 RPMs that install on AL2023, pinnable so it doesn't reintroduce The documented install fails (not on PyPI), and the on-instance bootstrap resolves unpinned specs per job #13 a layer down. - Keep
spec.containerbut suppress the preamble and require the image to carry Snakemake. Coherent, but it rules out every single-tool image, which is the main population — our catalog is 79 recipes of one-tool-per-image. - Mount a host venv into the container. Avoids both, but couples the node's Python ABI to the image's, which I would not want to depend on.
(1) looks right to me, and it is bigger than a patch, which is why I'm filing rather than attempting it.
Two more from the same session, both sizing-adjacent
- A container job sized from
threads: 1with nomem_mblands ont4g.nano, which cannot host a container at all. My first probe declared onlythreads: 1; the adapter sizedt4g.nano(0.5 GiB) and the job hung indocker install— the console shows it reachAmazon Linux 2023 repository 56 MB/s | 80 MB, thenWaiting for process with pid 2213 to finish, and never progress. Sizing from the tool's needs is right when the job runs on the host; oncecontaineris set, the job also has to install Docker and pull an image, which has a floor the rule'sresourcesknow nothing about. A minimum whencontaineris set, or a warning, would have saved the run. - Observation, not a confident claim: on that wedged nano the TTL did not fire. 6m TTL, still
runningat 12m, nocompletion.jsonand nocommand.login the results prefix; I force-terminated. The likely reading is thatsporedcould not make progress on a 0.5 GiB box underdnf, and TTL is enforced in-instance so it cannot act when the instance is degraded — the same constraint spawn#640 names for FSx. Flagging it with the console evidence rather than asserting a TTL bug, since the box was in a state nothing is promised for. Worth knowing that the nano path can strand an instance, though.
For contrast, everything behaved correctly on the 4 GiB runs: both failures produced a completion.json with the right non-zero exit code and a full command.log, and the instance self-terminated on on_complete without my intervention. The cost cap and the pinned node-side specs both visibly did their jobs too — the log shows installing snakemake==9.27.0 snakemake-storage-plugin-s3==0.3.6, i.e. #13's fix working exactly as intended, pinned to my submitting environment.
Activity
fix: remove the container passthrough added in 0.3.0 — it cannot work (…
chore(release): v0.4.0
scttfrdmn commentedon Oct 4, 2026
Thank you for running it on real hardware — and sorry for the delay in replying here.
v0.4.0 removed both the
container:passthrough and--spawn-containerentirely. That shipped at 05:47Z, about an hour after you filed this, so your report and the removal crossed. Your stage-2 finding is the reason it is gone rather than patched: I had reached the same conclusion from re-readingformat_job_exec, but you proved it on a real pinned image, which is better than either of us arguing from the source.The correction I owe you
You were right that our reasoning crossed, and the fault is mine, not ambiguity in your writing. My PR #15 body says, in as many words:
That is backwards twice over. You had explicitly retracted the suggestion 42 minutes earlier — "Don't do that — it cannot work with this adapter's architecture, and I'd rather say so before someone implements it" — and split the half that does work into its own PR. And your apptainer point argued against
spec.container, not for it: AL2023 lacking apptainer is what makesspec.containerlook attractive and is simultaneously why it cannot work, because the thing that must go in the container is the rule's shell, which only Snakemake-on-the-node can arrange.The root cause on my side is simple and worth stating plainly: I read the issue body and never the comments or the repo's open PRs before implementing. I've recorded that in the v0.4.0 changelog entry rather than quietly deleting the feature, since a released version advertised something that could not work.
On the three shapes
(1) is right, and for the reason you give: the preamble and the
--mode remotere-invocation belong on the host, and only the rule's shell belongs in a container. That is also the shape Snakemake already expects — it forwardsdeployment_method/apptainer_prefix/apptainer_argsingeneral_args, so the adapter is not inventing semantics, it is declining to drop ones that already exist.(2) rules out single-tool images, which as you say is the whole catalog population — 79 recipes, one tool each. (3) couples the node's Python ABI to the image's, which I also would not want to rely on.
The apptainer
el9aarch64 RPM detail is the useful part of (1): it makes the node-side install pinnable, so it doesn't reintroduce #13 a layer down. Agreed it's bigger than a patch, and I'd rather it be designed than attempted — filing it rather than half-building it was the right call.Your two sizing findings
Both are real and I've split them out, because neither is about containers:
container:-bearing job sized fromthreads: 1lands ont4g.nano, which cannot host a container at all. You're right that the floor is invisible to the rule'sresources: oncecontaineris set the job must also install Docker and pull an image, which the tool's declared needs know nothing about. A minimum (or a refusal) whencontaineris set.sporedruns on the box, so a box too degraded to make progress is also too degraded to enforce its own lifetime. That is precisely what the out-of-band reaper exists for, and your run is the cleanest demonstration of it I've seen — worth having on the record even though nothing is promised for a 0.5 GiB box underdnf.Noting your contrast too, since negative results are easy to over-weight: on the 4 GiB runs everything did what it should — correct non-zero exit codes in
completion.json, fullcommand.log, self-termination onon_complete, andinstalling snakemake==9.27.0 snakemake-storage-plugin-s3==0.3.6showing #13's pinning working against your submitting environment.scttfrdmn commentedon Oct 4, 2026
Correction to my comment above: the TTL/wedged-nano observation is spawn#682, not spawn#683. (#683 turned out to be something else I found in the same session —
drainJobArrayfiltering on a tag that is never populated, so a failed MPI cohort leaked an instance. Unrelated to your report, but found while verifying on the same hardware you prompted.)Direct link: spore-host/spawn#682
scttfrdmn commentedon Oct 5, 2026
Closing — the substance of this shipped, and the issue has just been sitting open since.
Resolved in v0.4.0
The
container:passthrough and--spawn-containerwere removed entirely in v0.4.0, published 2026-10-04T05:47Z. Removed rather than patched, because your stage-2 finding showed the design could not work: the install preamble runs inside the science image, so the thing it needs to install is exactly the thing it cannot.Worth saying plainly that the release and your report crossed — v0.4.0 went out about an hour after you filed, so you may not have seen that your finding is why the feature is gone. v0.3.0 advertised a capability that could not function; that is now un-shipped rather than left to be discovered.
Where your other observation went
The wedged-
t4g.nanoTTL finding became spawn#682, and its preventable half shipped in spawn v0.121.0: a launch below 1 GiB now warns, before any AWS resource is created, that the box may be too small forsporedto enforce its own lifetime — naming the specific--ttlthat may not hold, and pointing atspawn doctorto check whether a reaper covers the account.I did not take the
--mpi-style refusal you suggested, and the reason is worth recording: the fatal ingredient was the Docker install inside your--command, which spawn cannot see. Refusing on memory alone would block working launches to prevent a combination it has no visibility into. So it warns, and the floor is 1 GiB because 0.5 GiB demonstrably failed and your 4 GiB runs demonstrably worked, with nothing in between tested — a test asserts the constant stays inside that evidence.The heartbeat half of #682 — making a starved instance visible rather than merely preventable — is still open. You were right that it is the bigger piece, and it belongs with the "who reaps the reapers" thread rather than bolted on.
Your report also prompted a deployment that matters more than either: an in-account TTL reaper is now armed in the account where an earlier 1.2 TiB filesystem leak happened, validated in both directions — it spares a live instance and reaps an expired one. Your run is cited in that reasoning as the live demonstration that in-instance enforcement has a floor.
Thanks for the hardware time, and for the detail. Four of the six bugs found in that session were only findable on real instances.