Batch mode silently drops --time-limit and --extra-flags
@namin
Summary
A source-backed CLI behavior needs a contract decision before implementation: batch invocations parse --time-limit=<seconds> and --extra-flags=<string>, but the batch dispatch path does not receive either value.
Evidence
At the current main baseline (299e6b057a5dfc7f255d3e06d998573918e6e429), tools/src/lsc.ts parses both flags and forwards them to runFile for an explicit source path. With no source path, it calls runBatch(cmd, backend, slow, configPath); each batch entry then uses only the timeout and flags from LemmaScript-files.txt. The parsed CLI values are therefore silently discarded in batch mode.
This is a static call-path finding; a fake-verifier argv-spy regression is still needed before a fix PR.
Contract question
Which behavior should be normative?
- Explicit CLI values override per-entry manifest values.
- CLI values provide defaults while manifest values remain authoritative.
- These flags are intentionally unsupported in batch mode and should be rejected clearly.
The existing --slow rule for entries above 60 seconds should be defined against the chosen effective timeout, and ordinary batch runs without these flags must remain unchanged.
Proposed acceptance criteria
- Exact downstream verifier argv is covered for manifest-only, CLI-only, and both-source cases.
- Invalid timeout input and unsupported commands remain clear errors.
- Precedence and repeated-flag behavior are documented.
- No verifier timing or proof correctness claims are inferred from an argv-only test.
No implementation PR is opened yet because choosing a precedence rule would otherwise be an unreviewed interface change.
Hmm, I am not sure. I think if no time is provided, then clearly the reading from LemmaScript-files.txt should win. If something is provided, then perhaps, it should override the txt file. WDYT?
Thanks so much for reporting all the issues, and for the fixes. I am happy if you want to contribute a fix here as well. Do you agree about how this should be handled (see previous comment)? I am open to suggestions.