ErrorsExternal services · rule
connection.asks_not_granted
A package's service asks to reach a host that its connection's outbound: doesn't grant.
Area 11, External services; declinable; the next step is usually the human's.
Why Jadpo refuses it
A package can run its API as a container beside your app, a service run by
Jadpo (Services). Its runs:
lists the hosts the service needs to reach in asks:, but the service gets
none of them until your app's connection grants each with outbound:. A
grant is a new outside host your app's data can reach, so whether to give
it is a person's call. Until one is made, Jadpo names each host asked for
and the line that grants it.
What it looks like
/// Acme's PDF service, run beside the app.provider { protocol: Protocol.json_http runs: { image: "acme/pdf:1@sha256:4a2b7c1e9d0f3a5b6c8d7e2f1a0b9c8d7e6f5a4b3c2d1e0f9a8b7c6d5e4f3a2b" port: 3000 asks: ["fonts.example.com"] }}
application { connections: { pdfs: { package: AcmePdf.v1 domains: [printing] } }}
error AcmePdf.v1's service asks to reach fonts.example.com, which pdfs doesn't grant
--> app.jadpo:3:9
|3 | pdfs: { | ^^^^ not granted
- reason
- A service Jadpo runs reaches no host outside the machine until its connection grants it, and a new grant is a new outside host the app can send data to, which needs a person's acceptance.
AcmePdf.v1says its service needsfonts.example.comto work fully. - next
- Grant it with
outbound: ["fonts.example.com"]onpdfsonce a person agrees the service may reach it, or writedecline connection.asks_not_granted: "<why>"above it if this is deliberate (human) - rule
- connection.
asks_ not_ granted - help
- https://jadpo.
dev/docs/errors/connection. asks_ not_ granted
(human) at the end of the next: line tells your coding agent to stop and ask you which fix you want, because the choice is yours to make.
How to fix it
If the service may reach the host, grant it on the connection:
pdfs: { package: AcmePdf.v1 domains: [printing] outbound: ["fonts.example.com"] }
The host is then in the network report, and the change that grants it
needs a person's acceptance, pdfs: NetworkChange.host_added
(Acceptances).
If the service works without it, decline it with the reason:
application { connections: { decline connection.asks_not_granted: "Pages use the fonts the image carries." pdfs: { package: AcmePdf.v1 domains: [printing] } }}
The service then reaches nothing beyond the machine, and the reason stays beside the connection for whoever reviews it.
Related
Markdown for agents: /docs/errors/connection.asks_not_granted.md.Built from Jadpo's main branch at commit dfbeede.