Jadpo is experimental and not ready for production. These docs follow the compiler's main branch as of 5 Nov 2026. What's built · Install 0.3.0
jadpo
ReferenceErrors

ErrorsProject layout and modules · rule

visibility.private_cross_domain

On this page

Code in one domain uses an action, type or other declaration that another domain keeps private, because it isn't marked public.

Area 1, Project layout and modules; not declinable; the next step is usually the human's.

Why Jadpo refuses it

A domain is the boundary of what other code can see. Everything in it is private unless it is marked public, so a domain can change its private code without breaking another domain. A public action is how other domains change its data; anything else stays its own.

Jadpo won't mark the declaration public for you. Making it public is the owning domain's promise to keep offering it to every other domain.

What it looks like

domains/inventory/actions/reserve_stock.jadpo:

example
use shared/types { Quantity }action reserve_stock(quantity: Quantity) -> Unit {}

domains/ordering/actions/checkout.jadpo:

example
use shared/types { Quantity }use inventoryaction checkout(quantity: Quantity) -> Unit {    inventory.reserve_stock(quantity)}
jadpo checkcheck failed: 1 error, 4 files

error reserve_stock is private to domain inventory

--> domains/ordering/actions/checkout.jadpo:5:15

  |5 |     inventory.reserve_stock(quantity)  |               ^^^^^^^^^^^^^ private
reason
Another domain may use only what a domain marks public; reserve_stock is an action in domains/inventory/actions/reserve_stock.jadpo.
next
Mark reserve_stock public if inventory should offer it to other domains (human)
rule
visibility.private_cross_domain
help
https://jadpo.dev/docs/errors/visibility.private_cross_domain

(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: it decides whether inventory offers reserve_stock to other domains.

A fixture is private to its domain too. Another domain's tests call it only when it is public:

domains/reminders/actions/send_reminders.test.jadpo:

example
use planningtest "reminders start from planning's open todos" {    send_reminders()    assert planning.two_open_todos() == 2}
jadpo checkcheck failed: 1 error, 5 files

error two_open_todos is private to domain planning

--> domains/reminders/actions/send_reminders.test.jadpo:5:21

  |5 |     assert planning.two_open_todos() == 2  |                     ^^^^^^^^^^^^^^ private
reason
Another domain may use only what a domain marks public; two_open_todos is a fixture in domains/planning/fixtures/two_open_todos.jadpo.
next
Mark two_open_todos public if planning should offer it to other domains' tests (human)
rule
visibility.private_cross_domain
help
https://jadpo.dev/docs/errors/visibility.private_cross_domain

How to fix it

The question is whether the owning domain should offer the declaration to other domains.

If inventory should offer reserve_stock, mark it public. In domains/inventory/actions/reserve_stock.jadpo:

example
public action reserve_stock(quantity: Quantity) -> Unit {}

checkout can now call inventory.reserve_stock(quantity), and both domains' changes commit or roll back together, in one database transaction. Every type in a public action's signature must be public or shared too; Quantity is shared.

If planning should offer two_open_todos to other domains' tests, mark the fixture public, and the type it returns as well. In domains/planning/fixtures/two_open_todos.jadpo:

example
public fixture two_open_todos() -> TodoCount {    ...}

The reminders test can now call planning.two_open_todos(). A public fixture is still offered to tests, fixtures and seeds only, never to application code.

When the declaration should stay private, the other domain stops using it: it calls a public action of the owning domain instead, or keeps a declaration of its own.

Markdown for agents: /docs/errors/visibility.private_cross_domain.md.Built from Jadpo main at aee2e8f.