Repository F# setup
open System
open System.IO
open System.Threading
open System.Threading.Tasks
open Axial
open Axial.Console
open Axial.FileSystem
open Axial.Hosting
open Axial.Hosting.Browser
open Axial.Hosting.Node
open Axial.State
open Axial.Telemetry
open Axial.Telemetry.JavaScript
open Axial.Guardrails
open Axial.ToolGuardrail diagnostics
Each AXG diagnostic has a narrow contract: the effect or convention it detects, the service or form that replaces
it, and the suppression directive that allows an intentional boundary. The adoption guide covers
install, severity, and suppression choices; this page is the per-diagnostic reference.
AXG001: Use explicit effect services
AXG001 detects direct calls to ambient .NET effects.
| Category | Detects | Use instead |
|---|---|---|
random |
Construction of System.Random |
IRandom, Random.service, or Random.nextDouble |
guid |
Guid.NewGuid() |
IGuid, Guid.service, or Guid.newGuid |
clock |
Ambient date and time properties, Stopwatch, and Task.Delay |
IClock, Clock.service, Clock.utcNow, Clock.timed, Flow.sleep, or Schedule |
environment |
Ambient environment variables, machine or process properties, and TimeZoneInfo.Local |
IEnvironment or a value passed through 'env; an explicit TimeZoneInfo for conversions; Parallelism.ofProcessors for ProcessorCount |
console |
Any System.Console member |
Axial.Console.IConsole |
filesystem |
Any System.IO.File or System.IO.Directory member |
Axial.FileSystem.IFileSystem |
process |
System.Diagnostics.Process.Start |
Axial.Process.IProcess |
sleep |
Thread.Sleep |
Flow.sleep or Schedule |
http |
Construction of HttpClient |
Axial.HttpClient.IHttp, with Http.live over one shared client |
blocking |
Async.RunSynchronously, Task.Wait()/Wait(timeout), task/value-task .Result, and .GetAwaiter().GetResult() outside flows; task .Result and .GetAwaiter().GetResult() inside flows |
Await asynchronously outside flows; let! on the task inside flows |
scope |
A direct Cache.make*, Hub.make/bounded, or Queue.bounded/unbounded returned by a run |
Use the service before the scope closes |
Reads of .Result or .GetAwaiter().GetResult() on a task or value task are exempt when the same value's completion state is tested in the enclosing if branch or when guard, or when the value is the parameter of a ContinueWith callback. Other waits remain findings. Blocking waits outside flows can deadlock UI synchronization contexts.
TimeZoneInfo.ConvertTimeFromUtc(utc, zone) is allowed when zone is supplied explicitly; reading
TimeZoneInfo.Local to supply that argument is not. Pass the desired zone through configuration or 'env.
The analyzer matches resolved System.* symbols, not source text. It does not flag an application type named Random or a local value named now.
Allow an intentional effect boundary
First replace the ambient call with the service named by the diagnostic. An automatic fix is not offered because introducing an explicit service usually changes the containing function's environment and often its return type.
A normal live implementation belongs in a file assigned the capabilities role and needs no suppression:
[files]
capabilities = ["src/App/Capabilities/**"]
For an exceptional one-off boundary outside that role, declare the exact file in policy and give each suppression a non-empty reason:
[boundaries]
files = ["src/App/LiveClock.fs"]
let live : IClock =
let stopwatch = System.Diagnostics.Stopwatch.StartNew() // axial-allow-AXG001: live clock implementation
{ new IClock with
member _.UtcNow() = DateTimeOffset.UtcNow // axial-allow-AXG001: live clock implementation
member _.Elapsed() = stopwatch.Elapsed
member _.Sleep(delay, token) = Task.Delay(delay, token) }
live: IClockAxial.IClockSupplies wall time, monotonic time, and cancellable delays from one source. Wall time is for timestamps. Use differences between Elapsed readings for durations.
stopwatch: Diagnostics.StopwatchSystemStartNew: unit -> Diagnostics.StopwatchInitializes a new instance, sets the elapsed time property to zero, and starts measuring elapsed time. A that has just begun measuring elapsed time.
DiagnosticsSystem.Diagnostics.StopwatchProvides a set of methods and properties that you can use to accurately measure elapsed time.
_: IClockUtcNow: unit -> DateTimeOffsetSystem.DateTimeOffsetRepresents a point in time, typically expressed as a date and time of day, relative to Coordinated Universal Time (UTC).
UtcNow: DateTimeOffsetGets a object whose date and time are set to the current Coordinated Universal Time (UTC) date and time and whose offset is . An object whose date and time is the current Coordinated Universal Time (UTC) and whose offset is .
Elapsed: unit -> TimeSpanElapsed: TimeSpanGets the total elapsed time measured by the current instance. A read-only representing the total elapsed time measured by the current instance.
Sleep: TimeSpan * CancellationToken -> Taskdelay: TimeSpantoken: CancellationTokenSystem.Threading.Tasks.TaskRepresents an asynchronous operation.
Delay: TimeSpan * CancellationToken -> TaskCreates a cancellable task that completes after a specified time interval. The time span to wait before completing the returned task, or to wait indefinitely. A cancellation token to observe while waiting for the task to complete. represents a negative time interval other than . -or- The argument's property is greater than 4294967294 on .NET 6 and later versions, or Int32.MaxValue on all previous versions. The task has been canceled. The provided has already been disposed. A task that represents the time delay.
Requires & types
Requires: open Axial; open System; open System.Threading.Tasks (packages: Axial)val live: IClockThe file-wide form belongs in the leading comment block:
// axial-allow-file-AXG001: this file provides the live console implementation
A rule-specific suppression allows only that diagnostic. It does not allow other Guardrails findings in the file.
Capability-role globs are the normal home for raw I/O. [boundaries].files contains exact exceptional files; it is
not a second capability-folder mechanism. A forbid rule cannot be suppressed even in a declared boundary.
AXG002: Remove invalid suppressions
AXG002 validates every suppression. It reports legacy or malformed syntax, an unknown rule ID, a missing reason,
a file-wide suppression outside the leading comment block, a suppression outside a TOML-declared boundary file,
or a stale suppression that covers no finding. AXG009–013 allowances are invalid: these rules cannot be suppressed.
It also validates axial-note acknowledgements for guide findings (AXG010 and awaited-delay AXG013).
A note needs a non-empty reason and a live guide finding on the same or following line. For AXG010 put the note as
the first line inside the handler body, immediately before its first expression (not above with or the pattern).
Notes for block findings, unknown rule IDs, malformed notes, and stale notes warn during development and become
errors at checkpoints.
Valid notes leave their guide finding visible as Info; they never hide it.
Remove an invalid or unused directive. AXG002 offers an automatic removal when the directive occupies its own comment
line. For an intentional boundary, declare the file and use a rule-specific comment such as
// axial-allow-AXG001: <reason> with the ID of the finding being allowed.
AXG003: Return typed failures from workflows
A Flow<'env, 'error, 'value> represents expected failures through its 'error channel. Raising an exception inside flow { } creates an unhandled defect instead, so callers cannot handle it as an expected error.
AXG003 detects direct calls to raise, failwith, failwithf, invalidOp, invalidArg, and reraise inside flow { }. It also checks nested conditionals, matches, bindings, and lambdas.
Use return! Flow.fail error for an expected failure. Use Flow.die when the failure is an unrecoverable defect.
For a standalone raise, failwith, failwithf, or invalidOp, AXG003 offers a return! Flow.fail ... fix. Calls
embedded in a larger expression need a manual rewrite because inserting return! there would be invalid.
If a nearby try/with catches and translates the exception, declare the file as a boundary and add a reason:
let start (proc: System.Diagnostics.Process) =
if not (proc.Start()) then raise (Exception "Process did not start") // axial-allow-AXG003: caught and translated by caller
start: Diagnostics.Process -> unitproc: Diagnostics.ProcessSystemSystem.Diagnostics.ProcessProvides access to local and remote processes and enables you to start and stop local system processes.
Diagnostics``not``: bool -> boolNegate a logical value. Not True equals False and not False equals True The value to negate. The result of the negation. not (2 + 2 = 5) // Evaluates to true // not is a function that can be compose with other functions let fileDoesNotExist = System.IO.File.Exists >> not
Start: unit -> boolStarts (or reuses) the process resource that is specified by the property of this component and associates it with the component. No file name was specified in the component's . -or- The member of the property is while , , or is . There was an error in opening the associated file. The process object has already been disposed. Method not supported on operating systems without shell support such as Nano Server (.NET Core only). if a process resource is started; if no new process resource is started (for example, if an existing process is reused).
raise: Exception -> 'TRaises an exception The exception to raise. The result value. open System.IO exception FileNotFoundException of string let readFile (fileName: string) = if not (File.Exists(fileName)) then raise(FileNotFoundException(fileName)) File.ReadAllText(fileName) readFile "/this-file-doest-exist" When executed, raises a FileNotFoundException.
``.ctor``: string -> unitInitializes a new instance of the class with a specified error message. The message that describes the error.
Requires & types
val start: Diagnostics.Process -> unitUse this directive only when the same local boundary catches and translates the exception.
AXG004: Create fresh test fixtures
A module-level let value is initialized once and shared by every test in the module. Mutable or stateful values can therefore make parallel xUnit tests interfere with each other.
AXG004 checks modules that contain an xUnit [<Fact>] or [<Theory>], or an FsCheck [<Property>]. It reports module-level values but not functions such as let fixture () = ....
The analyzer excludes constants and point-free function definitions because they do not create the shared-state risk.
Create fixtures inside each test or expose a function that returns a fresh fixture. There is no automatic fix because changing a value to a function requires updating all call sites. For a safe immutable value in a declared boundary test file, add a reason:
let private syntheticTime = DateTimeOffset(2026, 1, 1, 0, 0, 0, TimeSpan.Zero) // axial-allow-AXG004: immutable timestamp
syntheticTime: DateTimeOffset``.ctor``: int * int * int * int * int * int * TimeSpan -> unitInitializes a new instance of the structure using the specified year, month, day, hour, minute, second, and offset. The year (1 through 9999). The month (1 through 12). The day (1 through the number of days in ). The hours (0 through 23). The minutes (0 through 59). The seconds (0 through 59). The time's offset from Coordinated Universal Time (UTC). does not represent whole minutes. is less than one or greater than 9999. -or- is less than one or greater than 12. -or- is less than one or greater than the number of days in . -or- is less than zero or greater than 23. -or- is less than 0 or greater than 59. -or- is less than 0 or greater than 59. -or- is less than -14 hours or greater than 14 hours. -or- The property is earlier than DateTimeOffset.MinValue or later than DateTimeOffset.MaxValue.
System.TimeSpanRepresents a time interval.
Zero: TimeSpanRepresents the zero value. This field is read-only.
Requires & types
Requires: open Systemval syntheticTime: DateTimeOffsetAXG005: Preserve cancellation tokens
Task adapters receive Flow's cancellation token. Discarding that token prevents cancellation from stopping the underlying operation.
AXG005 checks ColdTask, ColdTask.create, Flow.fromTask, and Flow.fromTaskResult. It reports a single-argument lambda when the argument is a bare discard, such as fun _ -> ....
Use the cancellation-aware overload of the wrapped operation and pass the token to it.
No automatic fix is offered because the analyzer cannot choose the foreign API's cancellation-aware overload or know where its token belongs. If a legacy API has no such overload, declare the adapter file as a boundary and add a reason:
/// An API with no cancellation support.
let legacyCall () : Task<int> = Task.FromResult 42
let legacy = ColdTask(fun _ -> legacyCall ()) // axial-allow-AXG005: legacy API has no token overload
legacyCall: unit -> Task<int>System.Threading.Tasks.Task`1Represents an asynchronous operation that can return a value. The type of the result produced by this .
intAn abbreviation for the CLI type . Basic Types
System.Threading.Tasks.TaskRepresents an asynchronous operation.
FromResult: 'TResult -> Task<'TResult>Creates a that's completed successfully with the specified result. The result to store into the completed task. The type of the result returned by the task. The successfully completed task.
legacy: ColdTask<int>ColdTaskRequires & types
Requires: open Axial; open System.Threading.Tasks (packages: Axial)val legacyCall: unit -> Task<int>val legacy: ColdTask<int>This check is omitted from the declared test project's default analyzer set. Test adapters often wrap completed
tasks that have no work to cancel. AxialGuardrailsInTests=all enables it; IsTestProject does not select the set.
AXG006: Format without reflection
F# unions and records get a compiler-generated ToString() that calls sprintf "%+A". %A walks the value with
FSharp.Reflection, and FSharp.Core's option, voption, list, Result, Choice, Map, and Set print their
contents the same way. NativeAOT and full trimming remove the metadata this needs. The call then throws or prints the
wrong text, and the build gives no specific warning because the reflection happens inside FSharp.Core.
AXG006 reports these formatting sites in typed code:
x.ToString(),string x, and interpolation holes such as$"{x}"whenxis an F# union, record, anonymous record, exception, or one of the FSharp.Core types above, and the type has no hand-writtenToStringoverride- the same forms on a type parameter, whose substituted type may be a union or record
%Aon any value other than a primitive, even when its type overridesToString- a boxed value of those types passed to
String.Format,String.Concat,StringBuilder.Append,TextWriter.Write,Console.Write,Trace.WriteLine, orDebug.WriteLine
Render the value explicitly instead. Match on the cases, call a describe function, or give the type a hand-written
override:
type OrderError =
| OutOfStock of sku: string
| InvalidQuantity of int
override this.ToString() =
match this with
| OutOfStock sku -> $"Out of stock: {sku}"
| InvalidQuantity quantity -> $"Invalid quantity: {quantity}"
FsLiveDocsGeneratedPage0_176065419729.OrderErrorOutOfStocksku: stringstringAn abbreviation for the CLI type . Basic Types
InvalidQuantityintAn abbreviation for the CLI type . Basic Types
this: OrderErrorToString: OrderError -> unit -> stringquantity: intWith that override, $"{error}", string error, and %O are safe. %A is not.
Axial's own public unions render themselves this way, including Exit, Cause, FiberStatus, FiberId, and the
Process, HttpClient, FileSystem, and PlatformService error types. A payload inside Exit or Cause is still
rendered with its own ToString, so give your error types an override too. Cause.prettyPrint also accepts an
explicit error renderer.
No automatic fix is offered because rendering is domain-specific. If code never runs trimmed, such as a script or a test helper, declare the file as a boundary and add a reason:
let printDiagnostics (diagnostics: Map<string, int list>) =
printfn "%A" diagnostics // axial-allow-AXG006: diagnostic helper never runs trimmed
printDiagnostics: Map<string,int list> -> unitdiagnostics: Map<string,int list>Microsoft.FSharp.Collections.FSharpMap`2Immutable maps based on binary trees, where keys are ordered by F# generic comparison. By default comparison is the F# structural comparison function or uses implementations of the IComparable interface on key values. See the module for further operations on maps. All members of this class are thread-safe and may be used concurrently from multiple threads.
stringAn abbreviation for the CLI type . Basic Types
intAn abbreviation for the CLI type . Basic Types
listThe type of immutable singly-linked lists. See the module for further operations related to lists. Use the constructors [] and :: (infix) to create values of this type, or the notation [1; 2; 3]. Use the values in the List module to manipulate values of this type, or pattern match against the values directly. See also F# Language Guide - Lists.
printfn: Printf.TextWriterFormat<'T> -> 'TPrint to stdout using the given format, and add a newline. The formatter. The formatted result. See Printf.printfn (link: ) for examples.
Requires & types
val printDiagnostics: Map<string,int list> -> unitAxial's packable libraries are compiled with F#'s --reflectionfree option. This prevents the compiler from
emitting reflection-based structural ToString() implementations and rejects %A in those libraries. A NativeAOT
application can apply the same option:
<PropertyGroup>
<OtherFlags>$(OtherFlags) --reflectionfree</OtherFlags>
</PropertyGroup>
The option does not make FSharp.Core's printf implementation reflection-free. An application that uses printf,
including formats without %A, can still produce the aggregate IL2104 and IL3053 warnings for FSharp.Core and
can fail at run time after trimming. Use explicit rendering with System.Console.WriteLine or another non-printf
output API on NativeAOT paths.
scripts/run-aot-probe.sh publishes a NativeAOT probe that renders these types and dumps a fiber registry, so the
release checks catch a regression that the analyzer cannot see. The probe itself uses printf to label checks, so
its publish currently reports the two aggregate FSharp.Core warnings above; it reports no such warning for an Axial
assembly.
AXG007: Keep resources acquired by a fiber
A forked fiber owns the scoped resources it acquires and releases them when it
settles. Fiber.join returns the fiber's value after that, so a resource the fiber returns is already released:
let connection : Resource<unit, Never, MemoryStream> =
Resource.create
(Flow.ok (new MemoryStream()))
(fun stream -> Flow.delay (fun () -> stream.Dispose(); Flow.ok ()))
/// Reported: the connection is released before join returns it.
let releasedBeforeUse =
flow {
let! fiber = Flow.scopeResource connection |> Flow.fork
return! Fiber.join fiber
}
connection: Resource<unit,Never,MemoryStream>Axial.Resource`3Describes acquisition of a value together with registration of its release in the current Flow scope. The release is a flow that cannot fail with a typed error. It runs without interruption, with the environment the value was acquired with; a defect it raises becomes a defect of the flow that closes the scope. The environment required to acquire the value. The typed acquisition failure. The acquired value.
unitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
Axial.NeverRepresents an error channel that cannot occur.
System.IO.MemoryStreamCreates a stream whose backing store is memory.
Axial.ResourceModulecreate: Flow<'env,'error,'value> -> ('value -> Flow<'env,Never,unit>) -> Resource<'env,'error,'value>Describes acquisition together with a release flow registered in the current Flow scope. The release runs when the scope closes, without interruption and with the environment captured at acquisition. It cannot fail with a typed error; a defect it raises becomes a defect of the flow that closes the scope, after the scope's other releases have run. Resource.create openConnection (fun connection -> Flow.delay (fun () -> connection.Close(); Flow.succeed ()))
Axial.Flowok: 'value -> Flow<'env,'error,'value>Creates a successful synchronous flow. The value to wrap in a successful flow. A flow that always succeeds with the provided value.
stream: MemoryStreamdelay: (unit -> Flow<'env,'error,'value>) -> Flow<'env,'error,'value>Defers flow construction until execution time. A function that returns the flow to execute. Recursive calls deferred here are consumed by the executor without growing a chain of parent tasks. Work that must run after the recursive call still needs storage until that call finishes. A flow that lazily evaluates the factory when executed. let flow = Flow.delay (fun () -> Flow.succeed 42)
Dispose: unit -> unitReleases all resources used by the .
releasedBeforeUse: Flow<unit,Never,MemoryStream>flow: FlowBuilderThe universal flow { } computation expression.
fiber: Fiber<Never,MemoryStream>scopeResource: Resource<'env,'error,'value> -> Flow<'env,'error,'value>Acquires a described resource and registers its release with the current runtime scope. The resource is a scoped resource: it stays open until the current scope closes. Inside a forked fiber that is the fiber's own scope, which closes when the fiber settles; inside a branch of zipPar, race, sequencePar, or traversePar, the resource moves to the caller's scope if the caller receives the branch's value. Use forkResource to acquire it in the background and keep it. A flow that finishes acquiring after its scope has closed, such as a race loser, releases the resource at once and is interrupted. The acquisition and release description. A flow that succeeds with the acquired value.
(|>): 'T1 -> ('T1 -> 'U) -> 'UApply a function to a value, the value being on the left, the function on the right The argument. The function. The function result. let doubleIt x = x * 2 3 |> doubleIt // Evaluates to 6
fork: Flow<'env,'error,'value> -> Flow<'env,'none,Fiber<'error,'value>>Starts a flow in a new fiber without waiting for it to complete. Forking turns a cold flow description into hot child work and returns a handle that can later be joined or interrupted. Prefer zipPar or race when the caller only needs a simple parallel composition. Wait for the handle with Fiber.join or Fiber.awaitExit, and stop it with Fiber.interrupt. The fiber runs in its own scope and releases its scoped resources (anything registered with a scope, such as scopeResource, scopeFinalizer, or a hub subscription) when it settles, whether or not anyone joins it. A value the fiber returns therefore outlives the scoped resources the fiber acquired: a resource returned through Fiber.join has already been released. Use forkResource to acquire a resource in the background and keep it, or zipPar and sequencePar to acquire several in parallel. The flow to fork. A flow that produces a handle.
Axial.FiberModuleOperations on a running , the handle returned by Flow.fork. Every operation returns a flow; nothing waits or interrupts until that flow runs. Reading a fiber's outcome through join, await, or interrupt marks it observed, so a defect it died with is not also reported as unobserved.
join: Fiber<'error,'value> -> Flow<'env,'error,'value>Waits for a fiber and returns its value, failing the same way the fiber failed. Joining preserves the child's error channel: a Cause.Fail becomes the same typed error, and interruption and defects remain interruption and defects. Use awaitExit to inspect the outcome instead. The fiber to join. A flow that completes with the fiber's value. let loadProfile : Flow<unit, string, string> = Flow.ok "profile" let loadOrders : Flow<unit, string, int list> = Flow.ok [ 1; 2 ] let page = flow { let! fiber = Flow.fork loadProfile let! orders = loadOrders let! profile = Fiber.join fiber return profile, orders }
Requires & types
Requires: open Axial; open System.IO (packages: Axial)val connection: Resource<unit,Never,MemoryStream>val releasedBeforeUse: Flow<unit,Never,MemoryStream>The code compiles and reads like ZIO, where a forked fiber shares its parent's Scope. In Axial the forked
fiber's own scope closes when it settles, so the release runs before Fiber.join returns: the stream is
already disposed, and the first use after the join throws ObjectDisposedException.
AXG007 reports a Flow.fork, forkNamed, forkGraceful, forkDetached, forkReplacing, or forkReplacingKey of
a flow that is a Flow.scopeResource or Flow.scopeAcquireRelease call, or a flow { } that returns what it acquired
with one of them. Acquire the resource with Flow.forkResource to keep it in the caller's scope, or with Flow.zipPar
or Flow.sequencePar to acquire several in parallel:
let keptForUse =
flow {
let! connecting = Flow.forkResource connection
return! Fiber.join connecting
}
keptForUse: Flow<unit,Never,MemoryStream>flow: FlowBuilderThe universal flow { } computation expression.
connecting: Fiber<Never,MemoryStream>Axial.FlowforkResource: Resource<'env,'error,'value> -> Flow<'env,'none,Fiber<'error,'value>>Starts acquiring a resource in a new fiber, keeping the resource in the caller's scope. A fiber started with fork releases its scoped resources when it settles, so a resource it acquires is already released by the time Fiber.join returns it. forkResource runs only the acquisition in the fiber and registers the release with the caller's scope, so Fiber.join returns a live resource that is released when the caller's scope closes, as if the caller had used scopeResource. If the caller's scope closes before the acquisition finishes, the fiber is interrupted, and a resource that was acquired anyway is released straight away. Scoped resources that the acquiring flow itself registers along the way belong to the fiber and are released when it settles; only the described resource moves to the caller. To acquire several resources in parallel and use them together, use zipPar or sequencePar. The acquisition and release description. A flow that produces a fiber whose value is the acquired resource. flow { let! connecting = Flow.forkResource databaseConnection let! config = loadConfig let! connection = Fiber.join connecting // still open return! migrate connection config } |> Flow.scoped // the connection is released here
connection: Resource<unit,Never,MemoryStream>Axial.FiberModuleOperations on a running , the handle returned by Flow.fork. Every operation returns a flow; nothing waits or interrupts until that flow runs. Reading a fiber's outcome through join, await, or interrupt marks it observed, so a defect it died with is not also reported as unobserved.
join: Fiber<'error,'value> -> Flow<'env,'error,'value>Waits for a fiber and returns its value, failing the same way the fiber failed. Joining preserves the child's error channel: a Cause.Fail becomes the same typed error, and interruption and defects remain interruption and defects. Use awaitExit to inspect the outcome instead. The fiber to join. A flow that completes with the fiber's value. let loadProfile : Flow<unit, string, string> = Flow.ok "profile" let loadOrders : Flow<unit, string, int list> = Flow.ok [ 1; 2 ] let page = flow { let! fiber = Flow.fork loadProfile let! orders = loadOrders let! profile = Fiber.join fiber return profile, orders }
Requires & types
Requires: open Axial (packages: Axial)val keptForUse: Flow<unit,Never,MemoryStream>Concurrency and scoped resources explains which scope owns a resource in each concurrent combinator.
No automatic fix is offered because forkResource, zipPar, and keeping ownership inside the fiber have different
semantics. If the fiber intentionally owns and consumes the resource, declare the file as a boundary and use
// axial-allow-AXG007: <reason>.
AXG013: Wait for facts, not time
In policy role test, AXG013 reports Thread.Sleep as an error and directly awaited
Task.Delay or Async.Sleep (do! or let!) as guide warnings. The legacy test.wait-for-facts
level does not change these tiers. A guessed pause does not prove
that background work reached the point an assertion needs.
Reported:
open System.Threading.Tasks
let guessedWait (assertReady: unit -> unit) = task {
do! Task.Delay 10
assertReady ()
}
SystemThreadingTasksguessedWait: (unit -> unit) -> Task<unit>assertReady: unit -> unitunitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
task: TaskBuilderBuilds a task using computation expression syntax.
System.Threading.Tasks.TaskRepresents an asynchronous operation.
Delay: int -> TaskCreates a task that completes after a specified number of milliseconds. The number of milliseconds to wait before completing the returned task, or -1 to wait indefinitely. The argument is less than -1. A task that represents the time delay.
Requires & types
Requires: open System.Threading.Tasksval guessedWait: (unit -> unit) -> Task<unit>Fixed: the worker completes the gate at the point the test needs to observe. The timeout is only a failure deadline.
open System
open System.Threading.Tasks
let waitForReady (ready: TaskCompletionSource<unit>) (assertReady: unit -> unit) = task {
let! completed = Task.WhenAny(ready.Task :> Task, Task.Delay(TimeSpan.FromSeconds 30.))
if not (obj.ReferenceEquals(completed, ready.Task)) then
raise (TimeoutException("Worker did not become ready"))
do! ready.Task
assertReady ()
}
SystemThreadingTaskswaitForReady: TaskCompletionSource<unit> -> (unit -> unit) -> Task<unit>ready: TaskCompletionSource<unit>System.Threading.Tasks.TaskCompletionSource`1Represents the producer side of a unbound to a delegate, providing access to the consumer side through the property. The type of the result value associated with this .
unitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
assertReady: unit -> unittask: TaskBuilderBuilds a task using computation expression syntax.
completed: TaskSystem.Threading.Tasks.TaskRepresents an asynchronous operation.
WhenAny: Task * Task -> Task<Task>Creates a task that will complete when either of the supplied tasks have completed. The first task to wait on for completion. The second task to wait on for completion. or was . A new task that represents the completion of one of the supplied tasks. Its is the task that completed first.
Task: Task<unit>Gets the created by this . Returns the created by this .
Delay: TimeSpan -> TaskCreates a task that completes after a specified time interval. The time span to wait before completing the returned task, or to wait indefinitely. represents a negative time interval other than . -or- The argument's property is greater than 4294967294 on .NET 6 and later versions, or Int32.MaxValue on all previous versions. A task that represents the time delay.
System.TimeSpanRepresents a time interval.
FromSeconds: float -> TimeSpanReturns a that represents a specified number of seconds, where the specification is accurate to the nearest millisecond. A number of seconds, accurate to the nearest millisecond. is less than TimeSpan.MinValue or greater than TimeSpan.MaxValue. -or- is . -or- is . is equal to . An object that represents .
``not``: bool -> boolNegate a logical value. Not True equals False and not False equals True The value to negate. The result of the negation. not (2 + 2 = 5) // Evaluates to true // not is a function that can be compose with other functions let fileDoesNotExist = System.IO.File.Exists >> not
objAn abbreviation for the CLI type . Basic Types
ReferenceEquals: obj * obj -> boolraise: Exception -> 'TRaises an exception The exception to raise. The result value. open System.IO exception FileNotFoundException of string let readFile (fileName: string) = if not (File.Exists(fileName)) then raise(FileNotFoundException(fileName)) File.ReadAllText(fileName) readFile "/this-file-doest-exist" When executed, raises a FileNotFoundException.
``.ctor``: string -> unitInitializes a new instance of the class with the specified error message. The message that describes the error.
Requires & types
Requires: open System; open System.Threading.Tasksval waitForReady: TaskCompletionSource<unit> -> (unit -> unit) -> Task<unit>A Deferred completed by the worker serves the same purpose. For scheduling behavior, step a test clock instead.
Task.WhenAny(work, Task.Delay duration) (including array arms or a locally bound deadline), fact-based
Wait(timeout) / WaitAsync(timeout), and SpinWait.SpinUntil(predicate, timeout) are allowed.
An infinite Async.Sleep, or Task.Delay with an explicit cancellation-token parameter, is also allowed
(Timeout.Infinite, Timeout.InfiniteTimeSpan, or literal -1). Async workflows supply their own cancellation
token. A tokenless infinite Task.Delay and any Thread.Sleep, even an infinite one, remain reported. A bare sleep inside a while or for loop is still
reported: counting iterations is a guessed duration, and unbounded polling can hang. In Axial's own tests,
Axial.Tests.TestSupport.waitUntil condition deadline is the approved bounded polling helper; only its
implementation may contain polling sleeps. Its TimeSpan deadline is a failure bound and it returns false
on expiry. Axial.Tests.TestSupport.occupyThread duration is the one approved way to simulate work by blocking a
thread (a slow handler, a loaded pool); it is never a wait for a fact. Finite waits elsewhere remain reported even
when they generate load or schedule cancellation.
The analyzer checks direct awaited delay calls, not aliases or data flow through helper functions.
Flow.sleep and Clock.sleep are out of scope: their syntax does not establish whether the environment supplies
live or controlled time. Manual-clock advance operations are also allowed. No automatic fix is offered because
only the test author knows which fact must be observed. For an intentional awaited delay, put
// axial-note AXG013: <reason> on the finding's line or the preceding line. It stays visible as Info,
including at checkpoints. Thread.Sleep cannot be acknowledged or suppressed.
AXG008: Keep scope-owned services inside their run
Flow.run, Flow.runSync, Flow.RunSynchronously, and StartAsTask close their scope after completion. Returning Queue.makeScoped, Hub.makeScoped, or Hub.subscribe directly leaves a shut-down service. Caches made by Cache.make, makeBounded, makeBoundedWithExpiry, or makeRec capture the creating runtime; closing its scope interrupts lookups. Use these services inside the flow or keep their owning scope open. Queue.make (and its bounded, unbounded, dropping, and sliding shorthands) and Hub.make do not register with the scope and may be returned. The syntax check sees direct calls and pipelines ending in a scoped constructor; the result-type check catches composed cache flows but does not flag Queue or Hub by type because it cannot distinguish scoped from unscoped construction. No automatic fix is offered because the correct lifetime depends on the caller. At an intentional boundary, declare the file and use // axial-allow-AXG008: <reason>.
AXG009: Keep raw concurrency inside the runtime
Reports Task, TaskCompletionSource, and CancellationTokenSource construction, Task.Run,
Task.Factory.StartNew, ContinueWith, Thread construction, and ThreadPool calls outside runtime files
and the capabilities role. Prefer Flow concurrency; raw coordination belongs at an OS bridge, not throughout
an adapter. Interlocked, F# lock, and Monitor are reported as warnings outside declared runtime files,
including in capability, host-tooling, and test code.
// Reported: scheduling bypasses Flow ownership.
let rawWork () = System.Threading.Tasks.Task.Run(fun () -> 1)
// Fixed: the caller runs and owns the workflow.
let ownedWork () = Flow.succeed 1
rawWork: unit -> Task<int>SystemRun: Func<'TResult> -> Task<'TResult>Queues the specified work to run on the thread pool and returns a object that represents that work. A cancellation token allows the work to be cancelled if it has not yet started. The work to execute asynchronously. The return type of the task. The parameter is . A task object that represents the work queued to execute in the thread pool.
ThreadingTasksSystem.Threading.Tasks.TaskRepresents an asynchronous operation.
ownedWork: unit -> Flow<'a,'b,int>Axial.Flowsucceed: 'value -> Flow<'env,'error,'value>Same as ok. The value to wrap in a successful flow. A flow that always succeeds with the provided value. let result = Flow.succeed 42 |> Flow.run () // result = Success 42
Requires & types
Requires: open Axial (packages: Axial)val rawWork: unit -> Task<int>val ownedWork: unit -> Flow<'a,'b,int>Raw task findings are errors and cannot be acknowledged or suppressed; move bridges into capability-role modules.
lock, Monitor and Interlocked are not reported: use Ref or STM where they fit, but the analyzer does not require it.
Exact repository-relative paths in [runtime].files exempt runtime implementations from AXG009 only.
Additions to this list appear in axial policy review; ordinary policy drift warns rather than blocking builds.
[boundaries].files does not exempt raw concurrency.
AXG010: Do not silently swallow exceptions
Reports only catch-all try/with handlers (_, a bound exception, or a type test for exn / System.Exception)
that neither use the exception nor call raise or reraise. Handlers for narrower exception types are not reported;
type abbreviations are resolved. When the exception value is irrelevant, narrow the catch to the specific type(s),
for example | :? FileNotFoundException ->. A narrowed catch need not bind or use an exception value; do not add
an exception to a return value merely to silence this guide. Returning or recording the bound exception counts as use, including assignments,
error-record fields, and chained calls such as ExceptionDispatchInfo.Capture(error).Throw().
A guard that inspects the bound exception counts as classification. A reporting function's name alone does not
establish exception use. Wildcard handlers returning a fallback value are still reported; returning Error or
Exit.Failure alone does not prove the exception was handled.
let swallowed () = try failwith "failed" with _ -> ()
let narrowed () =
try raise (System.IO.FileNotFoundException())
with :? System.IO.FileNotFoundException -> ()
swallowed: unit -> unitfailwith: string -> 'TThrow a exception. The exception message. Never returns. let failingFunction() = failwith "Oh no" // Throws an exception true // Never reaches this failingFunction() // Throws a System.Exception
narrowed: unit -> unitraise: Exception -> 'TRaises an exception The exception to raise. The result value. open System.IO exception FileNotFoundException of string let readFile (fileName: string) = if not (File.Exists(fileName)) then raise(FileNotFoundException(fileName)) File.ReadAllText(fileName) readFile "/this-file-doest-exist" When executed, raises a FileNotFoundException.
System``.ctor``: unit -> unitInitializes a new instance of the class with its message string set to a system-supplied message.
IOSystem.IO.FileNotFoundExceptionThe exception that is thrown when an attempt to access a file that does not exist on disk fails.
Requires & types
val swallowed: unit -> unitval narrowed: unit -> unitThis is a guide warning. When an exception is intentionally irrelevant, put
// axial-note AXG010: <specific reason> as the first line inside the handler body, immediately before its first
expression. The note must not sit above with or the pattern.
let invalid () =
try
failwith "failed"
// axial-note AXG010: too far from the handler body
with _ ->
()
let acknowledged () =
try
failwith "failed"
with _ ->
// axial-note AXG010: best-effort cleanup; the failure is reported elsewhere
()
invalid: unit -> unitfailwith: string -> 'TThrow a exception. The exception message. Never returns. let failingFunction() = failwith "Oh no" // Throws an exception true // Never reaches this failingFunction() // Throws a System.Exception
acknowledged: unit -> unitRequires & types
val invalid: unit -> unitval acknowledged: unit -> unitThe finding stays visible as Info with the reason. An unacknowledged finding becomes an error at a checkpoint.
Host boundary projects may keep catch-alls under an explicit AXG010 project-path declaration in [exemptions].
The host role alone, or listing a file in [boundaries], is not an exemption.
AXG011: Explain uncancellable work
CancellationToken.None is an error everywhere except the runtime's single Cancellation.never definition. Pass the
owner's token; cleanup that must finish after cancellation belongs in the runtime's uninterruptible cleanup primitive.
let unownedToken = System.Threading.CancellationToken.None
let ownedToken (token: System.Threading.CancellationToken) = token
unownedToken: CancellationTokenSystemNone: CancellationTokenReturns an empty value. An empty cancellation token.
ThreadingSystem.Threading.CancellationTokenPropagates notification that operations should be canceled.
ownedToken: CancellationToken -> CancellationTokentoken: CancellationTokenRequires & types
val unownedToken: CancellationTokenval ownedToken: CancellationToken -> CancellationTokenNeither axial-allow nor axial-note exempts this finding. It is already an error, so checkpoints change nothing.
AXG012: Retain ownership of concurrent work
Reports discarded Task, ValueTask, and Fiber values in wildcard bindings, statements, and pipelines to ignore.
The typed check follows type abbreviations and catches aliased task factories. Both direct calls and pipelines
to F#'s ignore count; a same-named user function does not. Async.Start / Async.StartImmediate return unit and
are out of scope. Awaited let! / do! expressions and array/list elements retained in a collection are not
discarded statements. Explicit casts do not hide a discarded Task. A discarded Flow.fork description is cold:
without executing the returned Flow, no fiber starts, so AXG012 does not report it.
Retaining a value alone does not prove it will be
awaited: this rule detects local discards, not whole-program ownership.
let discarded () = System.Threading.Tasks.Task.FromResult 1 |> ignore
let retained () = System.Threading.Tasks.Task.FromResult 1
discarded: unit -> unitSystemFromResult: 'TResult -> Task<'TResult>Creates a that's completed successfully with the specified result. The result to store into the completed task. The type of the result returned by the task. The successfully completed task.
ThreadingTasksSystem.Threading.Tasks.TaskRepresents an asynchronous operation.
(|>): 'T1 -> ('T1 -> 'U) -> 'UApply a function to a value, the value being on the left, the function on the right The argument. The function. The function result. let doubleIt x = x * 2 3 |> doubleIt // Evaluates to 6
ignore: 'T -> unitIgnore the passed value. This is often used to throw away results of a computation. The value to ignore. ignore 55555 // Evaluates to ()
retained: unit -> Task<int>Requires & types
val discarded: unit -> unitval retained: unit -> Task<int>This is an error. Await the task or retain and join the fiber; neither axial-allow nor axial-note exempts it.
AXG014: Keep raw Task at the edge
AXG014 (TaskSurface) is guidance, never a gate. A raw Task escapes Flow's cancellation, supervision and
testability: nothing owns it, cancels it or replaces it in a test. The rule nudges code toward flow { } and keeps
the remaining Task use in thin, one-call bridges. Its findings are Info in every mode, including Full checkpoints and
axial check --full, and under warnings-as-errors.
What it reports depends on the file's resolved role ([files] overrides [projects]):
| Role | Reported |
|---|---|
domain, services |
Every task { } and backgroundTask { } expression, and every public function, value, member or abstract slot whose return type is Task, Task<'T>, ValueTask or ValueTask<'T> |
capabilities, host |
Only a task expression that composes: more than one let!/do!/use!/match!/return!, a loop, or an if/match that decides what to await (it contains an await or comes before the first one) in its own body |
[runtime].files |
Nothing: the runtime implements Flow on raw tasks |
test |
Nothing, unless AxialGuardrailsInTests=all; then the bridge rule applies |
Translating the one awaited result is what a bridge is for: a try/with that maps its exceptions, or a match on
its result, does not count as composition. Nor does argument validation before the await: an if without else
that contains no await. Class let bindings are private to the type and are not public signatures. Nested lambdas and computation expressions are judged on their own.
Overrides and interface implementations are not reported: a .NET interface dictates that signature. Private and internal declarations are not part of the public surface.
Reported in domain code:
open System.Net.Http
open System.Threading.Tasks
let fetchTitleTask (client: HttpClient) (url: string) : Task<string> =
task {
let! body = client.GetStringAsync url
return body.Trim()
}
SystemNetHttpThreadingTasksfetchTitleTask: HttpClient -> string -> Task<string>client: HttpClientSystem.Net.Http.HttpClientProvides a class for sending HTTP requests and receiving HTTP responses from a resource identified by a URI.
url: stringstringAn abbreviation for the CLI type . Basic Types
System.Threading.Tasks.Task`1Represents an asynchronous operation that can return a value. The type of the result produced by this .
task: TaskBuilderBuilds a task using computation expression syntax.
body: stringGetStringAsync: string -> Task<string>Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. The Uri the request is sent to. The must be an absolute URI or must be set. The request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation (or timeout for .NET Framework only). .NET Core and .NET 5 and later only: The request failed due to timeout. The provided request URI is not valid relative or absolute URI. The task object representing the asynchronous operation.
Trim: unit -> stringRequires & types
Requires: open System.Net.Http; open System.Threading.Tasksval fetchTitleTask: HttpClient -> string -> Task<string>Fixed: the logic is a flow, and the one .NET call is lifted with Flow.fromTask, which passes the flow's
cancellation token. In domain code, prefer a capability or service (Axial.HttpClient.IHttp here) over a raw client.
open System.Net.Http
open Axial
let fetchTitle (client: HttpClient) (url: string) : Flow<unit, string, string> =
flow {
let! body = Flow.fromTask (fun ct -> client.GetStringAsync(url, ct))
return body.Trim()
}
SystemNetHttpAxialfetchTitle: HttpClient -> string -> Flow<unit,string,string>client: HttpClientSystem.Net.Http.HttpClientProvides a class for sending HTTP requests and receiving HTTP responses from a resource identified by a URI.
url: stringstringAn abbreviation for the CLI type . Basic Types
Axial.Flow`3unitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
flow: FlowBuilderThe universal flow { } computation expression.
body: stringAxial.FlowfromTask: (CancellationToken -> Task<'value>) -> Flow<'env,'error,'value>Creates a flow from a cancellable task factory. The factory runs on each execution and receives the runtime's cancellation token, so the flow stays cold and cancellable. Thrown exceptions are recorded as defects (Cause.Die). Use attemptTask when expected exceptions should enter the typed error channel. Starts the operation, observing the supplied cancellation token. .NET only let flow = Flow.fromTask (fun token -> client.GetStringAsync(url, token))
ct: CancellationTokenGetStringAsync: string * CancellationToken -> Task<string>Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. The Uri the request is sent to. The cancellation token to cancel the operation. The is . The request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation (or timeout for .NET Framework only). .NET Core and .NET 5 and later only: The request failed due to timeout. The provided request URI is not valid relative or absolute URI. The task object representing the asynchronous operation.
Trim: unit -> stringRequires & types
Requires: open Axial; open System.Net.Http (packages: Axial)val fetchTitle: HttpClient -> string -> Flow<unit,string,string>Reported in a capability: the bridge sequences two calls inside the task.
open System.Net.Http
open Axial
let readBothInOneTask (client: HttpClient) (first: string) (second: string) : Flow<unit, string, string> =
Flow.fromTask (fun ct ->
task {
let! a = client.GetStringAsync(first, ct)
let! b = client.GetStringAsync(second, ct)
return a + b
})
SystemNetHttpAxialreadBothInOneTask: HttpClient -> string -> string -> Flow<unit,string,string>client: HttpClientSystem.Net.Http.HttpClientProvides a class for sending HTTP requests and receiving HTTP responses from a resource identified by a URI.
first: stringstringAn abbreviation for the CLI type . Basic Types
second: stringAxial.Flow`3unitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
Axial.FlowfromTask: (CancellationToken -> Task<'value>) -> Flow<'env,'error,'value>Creates a flow from a cancellable task factory. The factory runs on each execution and receives the runtime's cancellation token, so the flow stays cold and cancellable. Thrown exceptions are recorded as defects (Cause.Die). Use attemptTask when expected exceptions should enter the typed error channel. Starts the operation, observing the supplied cancellation token. .NET only let flow = Flow.fromTask (fun token -> client.GetStringAsync(url, token))
ct: CancellationTokentask: TaskBuilderBuilds a task using computation expression syntax.
a: stringGetStringAsync: string * CancellationToken -> Task<string>Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. The Uri the request is sent to. The cancellation token to cancel the operation. The is . The request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation (or timeout for .NET Framework only). .NET Core and .NET 5 and later only: The request failed due to timeout. The provided request URI is not valid relative or absolute URI. The task object representing the asynchronous operation.
b: string(+): ^T1 -> ^T2 -> ^T3Overloaded addition operator The first parameter. The second parameter. The result of the operation. 2 + 2 // Evaluates to 4 "Hello " + "World" // Evaluates to "Hello World"
Requires & types
Requires: open Axial; open System.Net.Http (packages: Axial)val readBothInOneTask: HttpClient -> string -> string -> Flow<unit,string,string>Fixed: each bridge is one awaited call, and the composition is a flow.
open System.Net.Http
open Axial
let get (client: HttpClient) (url: string) : Flow<unit, string, string> =
Flow.fromTask (fun ct -> client.GetStringAsync(url, ct))
let readBoth (client: HttpClient) (first: string) (second: string) : Flow<unit, string, string> =
flow {
let! a = get client first
let! b = get client second
return a + b
}
SystemNetHttpAxialget: HttpClient -> string -> Flow<unit,string,string>client: HttpClientSystem.Net.Http.HttpClientProvides a class for sending HTTP requests and receiving HTTP responses from a resource identified by a URI.
url: stringstringAn abbreviation for the CLI type . Basic Types
Axial.Flow`3unitThe type 'unit', which has only one value "()". This value is special and always uses the representation 'null'. Basic Types
Axial.FlowfromTask: (CancellationToken -> Task<'value>) -> Flow<'env,'error,'value>Creates a flow from a cancellable task factory. The factory runs on each execution and receives the runtime's cancellation token, so the flow stays cold and cancellable. Thrown exceptions are recorded as defects (Cause.Die). Use attemptTask when expected exceptions should enter the typed error channel. Starts the operation, observing the supplied cancellation token. .NET only let flow = Flow.fromTask (fun token -> client.GetStringAsync(url, token))
ct: CancellationTokenGetStringAsync: string * CancellationToken -> Task<string>Send a GET request to the specified Uri and return the response body as a string in an asynchronous operation. The Uri the request is sent to. The cancellation token to cancel the operation. The is . The request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation (or timeout for .NET Framework only). .NET Core and .NET 5 and later only: The request failed due to timeout. The provided request URI is not valid relative or absolute URI. The task object representing the asynchronous operation.
readBoth: HttpClient -> string -> string -> Flow<unit,string,string>first: stringsecond: stringflow: FlowBuilderThe universal flow { } computation expression.
a: stringb: string(+): ^T1 -> ^T2 -> ^T3Overloaded addition operator The first parameter. The second parameter. The result of the operation. 2 + 2 // Evaluates to 4 "Hello " + "World" // Evaluates to "Hello World"
Requires & types
Requires: open Axial; open System.Net.Http (packages: Axial)val get: HttpClient -> string -> Flow<unit,string,string>val readBoth: HttpClient -> string -> string -> Flow<unit,string,string>To hand a flow to a Task-based host, run it at the host boundary (flow.StartAsTask(env, ct)), not in domain code.
For an intentional Task surface, put // axial-note AXG014: <reason> on the finding's line or the preceding line;
the finding stays visible as acknowledged Info, logged below the minimal console verbosity. axial-allow-AXG014 is
not accepted.
Full resolves the builder's type, so an aliased builder (let t = task) is reported and a shadowing task value
of another type is not, and it follows type abbreviations and inferred return types. Fast matches the spellings
task/backgroundTask and annotated return types that name Task/ValueTask through the file's opens; it skips
names shadowed in the file and does not see aliases, abbreviations or unannotated return types. A file that opens
FSharp.Control.Tasks (Ply, TaskBuilder.fs) may rebind task: Full reports only FSharp.Core's builders, and Fast
does not claim task there. A binding such as let run () = task { ... } has one finding, the expression; its
inferred Task signature is not reported again. Both apply the same role and composition rules. axial check prints a per-project count of Fast's AXG014 findings (and of all raw task
sites), recorded by the latest build, so the trend stays visible; it never gates.
AXG009–AXG012 exempt the test role unless AxialGuardrailsInTests=all enables full test analysis. Host-role projects are exempt only when their
repository-relative project path matches that rule's [exemptions] list in Axial.Guardrails.toml.
The table accepts only AXG009, AXG010, AXG011, and AXG012, each an array of project-path globs.
Paths must stay inside the repository and match existing files. Other roles ignore these lists;
an ordinary host with no matching declaration is not exempt. For example:
[exemptions]
AXG009 = ["tools/**/*.fsproj"]
AXG010 = ["tools/**/*.fsproj"]
AXG012 = ["tools/**/*.fsproj"]
These lists do not change finding severities or exempt other rules.
AXG001–008 retain their boundary-allowance and baseline behavior. AXG009–013 do not accept allowances or baseline
severity downgrades. Only guide findings (AXG010, awaited-delay AXG013 and AXG014) accept axial-note; no boundary
membership or finding approval is needed. AXG002 warns about malformed, empty, unknown, misplaced, or stale notes,
and notes on block findings. Invalid notes become errors at checkpoints. No automatic fix is offered: choosing
ownership, cancellation, or exception reporting changes behavior.
The verification build and release workflow set AxialGuardrailsCheckpoint=true. Ordinary builds, including
ordinary Release builds, do not enable it automatically. At checkpoints, unacknowledged AXG010 and AXG013 guide findings become errors (AXG014 stays Info);
acknowledged findings remain Info with their reasons. Build output shows current findings; axial policy review
separately lists added notes and suppressions, changed reasons, and policy loosening since the reviewed commit.
Suppressions and notes stay active pending human review. axial check warns on policy drift; corrupt policy still
fails, as do analyzer errors. The lock is tamper-evident, not a security boundary; enforcement is the repository's
choice. Use axial policy review --check at a chosen release or merge point to reject unreviewed loosening.

