Files
Dario LipicarandClaude Opus 5 a5d4790809 conformance(ext): the consumer axis, and what it found (#50)
* conformance(ext): the consumer axis, and what it found

The ext table ran 44 cases x 2 providers x ONE consumer. Its own comment said
so. Everything the lossless Qt mapping widened lives in THIS contract and was
measured by nobody: `full_api` has no record, no typed container and no
optional in it, so `FullApiExt::Blob`, `QList<Blob>`, `QMap<QString, Blob>`,
`QList<QByteArray>`, `QList<QList<qlonglong>>`,
`QMap<QString, QList<QByteArray>>` and `std::optional<QString>` are reachable
from `full_api_ext` and from nowhere else — and each of them is emitted as an
element LOOP rather than handed to the codec whole, i.e. a body of generated
code the two existing qtproxy points cannot execute.

test-fullapi-ext-qtproxy-module is the same two-key shape as
test-fullapi-qtproxy-module against that contract: `interface: universal` for
the provider half (a header-first cdylib whose records are C++ structs in the
impl header) and `codegen.consumer_api_style: "qt"` for the consumer half, so
`modules().bind_full_api_ext(name)` is the Qt-typed, origin-bound wrapper. All
15 contract methods and the one event are forwarded, in both call modes.

WHAT IT FOUND. 44 x 2 x 3 = 264 cells: 217 pass, 47 xfail, 0 fail.

  * every widened spelling ROUND-TRIPS. Blob, Wrapper, Opt, [Blob], [Opt],
    {tstr: Blob}, {tstr: bstr}, {tstr: int}, {tstr: tstr}, {tstr: [bstr]},
    [[int]] and [bstr] are green on all six provider x consumer surfaces.
  * `hostile/Optional/scalar/wrong-type` on test_fullapi_ext_cpp is the sharp
    one, and it is new: the provider's class-E REJECTION arrives through the Qt
    wrapper as a successful call returning
    {"success": false, "value": null, "error": null} — the same value its three
    well-formed inputs produce. Registered as
    ext-optional-return-shape-through-the-qt-proxy, with the cause (the two
    providers still disagree about echoOptional's return) and the two halves of
    the fix kept apart.
  * the table's one DECLARED divergence stops diverging through a proxy: the hop
    canonicalises `["hi"]` to tagged bytes before the Rust provider is offered
    it, so its leniency is never exercised. Registered rather than smoothed with
    a per-consumer expectation, which would pin an accident as a contract.
  * pre-99-null-is-not-an-error and B-arity-overflow reproduce IDENTICALLY on
    both new consumers, which is the expected result and is why they were
    widened rather than given entries of their own. B-arity-overflow gains a
    fifth module and a third contract: the proxy's own derived dispatch drops
    the extra argument too.

Requires the logos-qt-sdk fix described in the accompanying report: the
generated record codecs (`recToWire_Blob` / `recFromWire_Blob`) are unqualified
file-scope statics, and the umbrella amalgamates every `<name>_api.cpp` into one
translation unit — so a module holding three wrappers for one record-bearing
contract does not compile. A proxy is exactly that shape.

* conformance(ext): name the generator prerequisite where it will be hit

A reader who builds this module against logos-qt-sdk 4ab78a1 gets forty
'ambiguating new declaration' errors inside generated code, with nothing in
this repo to point at. Say what the collision is, why this module is the shape
that triggers it, and why it cannot be worked around here.

* conformance(ext): replace two claims about the proxy consumers with measurements

Two of the things this table now says about its new consumer axis were argued
rather than measured, and one of them is false.

FALSE: pre-99-null-is-not-an-error claimed failure/A answers METHOD_FAILED
"IDENTICAL on extqtproxy-sync and extqtproxy-async, on both providers". It does
not. Run three times at this fixture rev — the nix check, then the same driver
standalone twice — exactly ONE of the six proxy coordinates answered RPC_FAILED
each time, and a different one each time: extqtproxy-async/cpp, then
extqtproxy-async/rust, then extqtproxy-sync/rust. Never on py (0 of 6 samples
against 3 of 12 proxy samples). The entry now names the flake and says why the
gate is unaffected: an xfail is keyed by (case, provider, consumer), both shapes
are the same class-A defect, and neither is the `object_unavailable` that would
retire the entry, so there is no xpass risk either. failure/C is separated out
because it IS deterministic. A registry that claims a determinism it does not
have is worse than one that names the flake.

ARGUED: the two new entries ruled out cross-case pollution from call_status and
the sync/async agreement. That is suggestive, not decisive — the last round of
this work nearly registered four phantom cells that one `isolate: true` made
behave. So it was measured as an A/B with one variable: the same driver, modules
and registry, the table re-run with `isolate: true` added to the four Optional
cases and to [bstr]/lenient-plain-string and nothing else changed. All 50 cells
of those five cases are identical between the runs — same status, same value, on
all three consumers and both providers.

No case, expectation or registry KEY moves; this is the `measured` and `note`
text catching up with what was actually run.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* conformance(ext): a case for the nested int range hole, found by probing the widened path

The consumer axis landed green, so the nested widened containers were probed by
hand instead — {tstr:[bstr]} and [[int]] are the least-exercised shapes in the
system and a green table is not evidence about the inputs it does not contain.

FOUND, and now a case: `echoNestedInts([[18446744073709551615]])`.
test_fullapi_ext_cpp rejects it and names the coordinate — `expected signed
integer in range at arg0[0][0], got number`. test_fullapi_ext_rust ACCEPTS it
and echoes the exact value back, so the decode never went through an i64.
`int` is i64, this table already pins the u64 end separately in a `uint` field,
and the neighbouring positive control ([[-9007199254740993, 9007199254740993]],
both edges outside double precision, at depth 2) round-trips on all six
surfaces — so the hole is the RANGE check, not the depth.

Both proxy consumers PASS it: the proxy decodes into std::vector<std::vector<
int64_t>> before calling out, so the Rust provider is never offered the value.
The cell therefore prints as py disagreeing with both proxy points, which is the
consumer axis earning its keep in the other direction — the hop HIDES a provider
defect, and only a table carrying both surfaces can say so. Spelled as a plain
`expect`, not expect_by_provider: one contract, one of the two is wrong.

RECORDED BUT NOT GIVEN CASES, on the entry that owns [bstr] leniency: three more
shapes of the same provider disagreement, one container deeper than the case
that is registered. `{"k": ["hi"]}` and `{"k": [42]}` into {tstr:[bstr]}, and
`[[1,2]]` into [bstr]. The middle one is not leniency but a coercion — the
number 42 comes back as the two ASCII bytes of its decimal spelling — and
whether a bstr slot should coerce, reject or stay lenient is a contract decision
the ext table's owner has not made. Writing an expectation would make it by
accident. The positive control passes everywhere: 0x00/0x80/0xFF and an empty
bstr, two containers deep, byte-identical on all six surfaces.

Measured: conformance-matrix-ext at 45 x 2 x 3 — 222 pass / 48 xfail / 0 fail /
0 xpass, exit 0.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* conformance(ext): replace the falsified determinism claim with the samples

The entry said the class-A flake hit 'exactly ONE of the six proxy
coordinates each time' and 'never on py'. Across 42 samples (7 runs x 6
coordinates) both are false: 3 of 7 runs had zero, and 1 of 14 py samples
hit it.

The py sample also refutes the explanation the claim rested on — it was
attributed to a daemon holding the proxy plus both providers, and the py
daemon holds no proxy. What is established is that the ~20s acquire can
outrun the core_service RPC deadline under load, on any coordinate; the
entry no longer claims a mechanism beyond that.

Two consecutive drafts made this error, in an entry whose own last sentence
argues that a registry claiming a determinism it does not have is worse
than one that names the flake.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* chore(deps): relock module-builder for the record-codec qualification

Picks up module-builder 236a409, which pins logos-qt-sdk 3ab7421 (#43).
The ext qtproxy fixture cannot compile without it — a proxy over a
record-bearing contract collides on every record.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
2026-08-23 22:55:34 -03:00

29 lines
1.3 KiB
JSON

{
"name": "test_fullapi_ext_qtproxy",
"version": "1.0.0",
"type": "core",
"category": "testing",
"interface": "universal",
"description": "Qt-typed consumer/proxy for the full_api_ext contract — the CONSUMER axis the ext table never had. Mirrors test_fullapi_qtproxy against the composite contract: the PROVIDER surface is a header-first cdylib (`interface: universal`, std-typed impl header with the three records declared as C++ structs), and the CONSUMER surface is selected independently by `codegen.consumer_api_style: \"qt\"`, so `modules().bind_full_api_ext(name)` is the Qt-typed wrapper — generated record structs, QList<Blob>, QMap<QString, QList<QByteArray>>, QList<QList<qlonglong>>, std::optional<QString>. Forwards every full_api_ext method to the bound provider and re-emits its event, so the ext matrix replays ext-cases.json through it unchanged.",
"main": "test_fullapi_ext_qtproxy_plugin",
"dependencies": ["test_fullapi_ext_cpp", "test_fullapi_ext_rust"],
"interface_dependencies": [
{ "name": "full_api_ext", "file": "interfaces/full_api_ext.lidl" }
],
"codegen": {
"consumer_api_style": "qt"
},
"nix": {
"packages": {
"build": [],
"runtime": ["nlohmann_json"]
},
"external_libraries": [],
"cmake": {
"find_packages": [],
"extra_sources": []
}
}
}