Tell agents to ask what a build can be probed with - #134
Merged
Conversation
`Mob.Test.capabilities/1` shipped documented only in the `Mob.Test` moduledoc,
which is the wrong place: the guide an agent reads before choosing how to drive
an app is `agentic_coding.md`, and choosing before discovering a probe is
unavailable is the entire problem it solves.
An adversarial review found three things wrong with the first version.
The example showed nine of sixteen keys behind a trailing `...`, and every
hidden one was `false` — including `sample_region`, which is what
`Mob.Test.sample_color/2` rides on and which has no Android NIF at all, so the
call raises rather than returning an error tuple. That is the precise misread
the feature was built to prevent, reintroduced by abridging the example that
demonstrates it. All seventeen entries are printed now.
It claimed `Mob.Test.tap/2` works "through the render tree". It does not — it
sends `{:tap, tag}` straight to the screen process over dist. The conclusion
was right and the mechanism was invented, and the invented mechanism implies a
guarantee the function does not offer: this same guide says two sections later
that `tap/2` returns `:ok` whether or not any screen matched.
And it sold the feature partly on iOS release builds, without saying that an
iOS release build drops `-name` entirely and so cannot answer at all — it
reports `dist_rpc: false` with everything false, indistinguishable from a bad
node name. The docstring says this; the guide had dropped exactly the sentence
that stops a reader misdiagnosing.
Also from the review: the section sat above the API it qualifies, so its code
block referenced a `node` bound twenty lines later; it named three outcomes
when `classify_capabilities/1` has four, omitting the one where `load_nif`
failed and the fix is a native rebuild rather than the bridge; it stated
"each harness NIF returns `{:error, :not_loaded}`" as a rule with two
exceptions inside the same probe set; and it never said what to do with the
answer, which is to drop to Layer 2 — two subsections below it.
Adds the CHANGELOG entry the implementation PR skipped, records the load
side effects in the docstring, and puts the question in the priming block that
readers actually paste into their AGENTS.md.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>GenericJamforce-pushed
the
docs/capabilities-in-guides
branch
from
September 5, 2026 15:01
9320d8d to
56f05ffCompareUh oh!
There was an error while loading. Please reload this page.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mob.Test.capabilities/1shipped documented only in theMob.Testmoduledoc, which is the wrong place for it. The guide an agent reads before choosing how to drive an app isagentic_coding.md, and choosing before discovering a probe is unavailable is the entire problem it solves.The example output is real, from a freshly generated Android app, and shows the uncomfortable part: no synthetic input at all, because the template's
MobBridge.ktships notapXyortypeText(MOB-160). Better an agent reads that here than finds it out four steps into a session.