Osy#the first language built for agents
Agents firstAgentic appsWorkflowsDurable Execution — built inSecurityTestingThe editorThe UI modelOne program

Reference / Diagnostics

Diagnostics (saying something, and silencing something)

What your app says while it runs, and what the compiler says about it. The first-day mistake is reaching for a print statement — `Log.*` is dual-sided, so one call from a page lands in the browser console AND in `osy logs` under one correlation id spanning client and server.

stable1 example compiled by CIdiagnosticsloggingovervieworientation

Summary#

Two things live here: what your app says at run time, and what the compiler says at build time.

entity Order {
  [Required, MaxLength(40)] string Code;
  bool Shipped;
}

void ShipOrder(Order order) {
  Log.Information("Order {OrderCode} shipped", order.Code);
  order.Shipped = true;
}

Description#

Log.* is dual-sided and always available — no dependency to declare. Called from a page it reaches the browser console and the app's own log, under one correlation id that spans the client call and the server work it caused, which is what makes osy logs --tail the first move when a page misbehaves. Both the template form and an interpolated string capture searchable fields; the interpolated form is decomposed, not flattened. See Log.*.

A warning you have decided about is silenced where you decided it[SuppressWarning] — not by turning the rule off globally. A suppression names the rule and sits at the site, so the next reader sees the decision rather than an absence.

For what a run actually did, rather than what it said, the local area has the tools: Seeing what happened when your code ran opens a trace and jumps to the fault, and faults are captured even with tracing off.

See also#

Related

Log.*

Write a line to your app's structured log. Both a plain template (`"Order {OrderCode} shipped"`, order.Code`) and an…

[SuppressWarning]

Accept ONE named warning about ONE declaration. Put it on the component member the warning is about, naming the code…

Seeing what happened when your code ran

Opens a finished run and shows what it did — each step named and pointed at its source line, the values that crossed…