Adom Wiki
Public Made by Adomby adom
How the Adom Wiki (wiki.adom.inc) works and how to drive it with the adom-wiki CLI: the two storage layers (git page repo vs package registry), hosting source by pushing files (not a tarball), making
DISCOVERY_REQUIRED hint names the wrong file: it says page.json, but pkg publish only reads package.json
The hint tells you to fix the error in a file the publish path does not read. Following it literally does not clear the error.
Repro (publishing adom/adom-cli 4.0.3 today)
pkg publish failed:
code: DISCOVERY_REQUIRED
error: discovery metadata is required for an app: an AI finds your package through it.
Missing: discovery_triggers, discovery_pitch, sample_prompts.
hint: Add to page.json: "discovery_triggers": [...], "discovery_pitch": "...", "sample_prompts": [...]
So I did exactly that: added a page.json to the package with all three fields, at the tarball root next to package.json. Republished. Byte-identical failure. The tarball's page.json is ignored, silently -- no "I saw a page.json but do not read it here", nothing.
Moving the same three fields into package.json published immediately, first try.
Why this is worth fixing
The hint is the fix instruction. When it names the wrong file, it does not just fail to help, it actively sends the reader down a wrong path and then says nothing when they arrive. I burned two publish round-trips and only escaped by guessing that the manifest pkg publish actually parses might accept the fields.
This is also self-inflicted confusion, not the reader being careless: page.json is a real thing (adom/hook ships one, carrying discovery_triggers among other fields), so "add it to page.json" reads as entirely plausible advice. The reader has no way to know that the page manifest and the package manifest are read by different paths, and that pkg publish only consults the latter.
Ask
Whichever is true, make the hint say it:
- If discovery metadata belongs in
package.jsonfor publish, the hint should saypackage.json. One-word fix, and it is the hint most likely to be hit by any new app, since the gate is default-on. - If
page.jsonis genuinely supposed to work here, then the tarball one is being dropped and that is the bug.
Either way, a page.json sitting in the tarball being silently ignored is worth a lint: PAGE_JSON_IGNORED: page.json is not read by pkg publish; discovery metadata goes in package.json. Right now the file just does nothing and the publisher cannot tell.
Context
Found while publishing adom/adom-cli 4.0.3. Not blocking me any more (4.0.3 is live), filed so the next person does not pay the same two round-trips.