Skip to content

feat[next]: name program and static args in "no program compiled" error - #2734

Draft
havogt wants to merge 1 commit into
fix-compiled-program-error-surfacingfrom
improve-compiled-program-miss-message
Draft

feat[next]: name program and static args in "no program compiled" error#2734
havogt wants to merge 1 commit into
fix-compiled-program-error-surfacingfrom
improve-compiled-program-miss-message

Conversation

@havogt

@havogt havogt commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Description

Draft — stacked on #2733, which is the actual fix. Split out of #2731 (now closed) because this
part is a message improvement and can be dropped independently.

When no compiled variant matches a call, the error said only

RuntimeError: No program compiled for this set of static arguments.

— neither which program, nor which arguments, nor that the offset provider takes part in the
selection. In a model with hundreds of programs that is not enough to act on.

Changes

RuntimeError: No program compiled for this set of static arguments of 'prog': cond=False. Note
that a variant is also selected by the identity of the 'offset_provider' entries and, for
generic programs, by the argument types.

_describe_argument_descriptors renders the key's descriptor values against the expressions
they were extracted from, so it covers both StaticArg (cond=False) and
FieldDomainDescriptor ((out).domain=Domain(...)), and yields an empty string when the pool
has no argument descriptors at all.

It deliberately does not use zip(..., strict=True): this runs while building an error
message, so a length mismatch must degrade to a shorter description rather than replace the
error the user actually needs — which is the failure mode #2733 exists to remove.

Open question

Is naming the arguments worth the ~15 lines? The "Note that ..." sentence about
offset_provider identity carries most of the debugging value on its own and would be a
two-line change.

Requirements

  • All fixes and/or new features come with corresponding tests.
    Three unit tests in tests/next_tests/unit_tests/otf_tests/test_compiled_program.py:
    static arg, static domain, and no argument descriptors.
  • Important design decisions have been documented in the appropriate ADR.

The error raised when no compiled variant matches a call only said
"No program compiled for this set of static arguments." — neither which
program nor which arguments. Add both, plus a note that the variant is also
selected by the identity of the 'offset_provider' entries, which is the
other common cause of an unexpected miss.
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.

1 participant