Dex 1.9.2 moves budget refusal into the cost gate
The release centralizes exhausted-budget handling, makes projects record a session-ceiling decision, and gives refusals historical billing context.
Dex 1.9.2 is a release about making warehouse-spend boundaries harder for adapters—and agents—to misread. The headline change is not a new connector or model. It is the removal of an unsafe intermediate state from the cost-control path.
A zero that could mean “no limit”
Before this release, Dex’s six billed adapters each checked whether a command had exhausted its remaining budget. The project’s change note explains why that duplication mattered: several server-side cap settings accept integers where 0 means unlimited, not “spend nothing.” PostgreSQL’s statement_timeout, ClickHouse’s max_execution_time, and Databricks’ statement timeout are cited examples.
Pull request #392 moves that decision into CostGate.statement_cap(). The method now either refuses with an over-ceiling error or returns None or a strictly positive integer. BigQuery’s 10 MB minimum is expressed through the same interface. The project reports 3,052 passing non-integration tests for this change, while disclosing three pre-existing packaging-test failures.
That is a useful control-plane pattern: do not ask every connector to remember that one apparently valid value reverses the intended safety behavior. Make the shared boundary incapable of returning it.
The first billed command now needs a project-level decision
Pull request #394 changes a project’s first confirmed, budgeted and billed command when no session ceiling has been recorded. Instead of repeating a warning indefinitely, Dex returns needs_confirmation with a suggested ceiling. The operator can set --session-ceiling or explicitly record --no-session-ceiling; the answer is written to .dex/config.yml.
Dex says the suggestion is five times the command’s estimate. A recorded decline does not remove the per-command warning or cap, but it does distinguish a deliberate choice from a project that was never asked.
Refusals get evidence, not just arithmetic
Pull request #395 adds the admitted estimate to settled spend records. Once at least three comparable commands exist, an over-ceiling refusal can report the recent median estimate-to-billed ratio and range for that connector and cost paradigm.
The refusal itself is unchanged: the estimate still determines admission, and it cannot be confirmed through. The history is decision context, not a bypass. Dex also excludes killed commands and zero-billed cache hits, and notes that older ledger entries lack estimates.
Connection provenance reaches the envelope
The release also adds a top-level connection record to Dex envelopes. Pull request #391 says it includes the connector, a non-secret target and the resolution source, covering flags, project config, environment variables, dbt profiles, host-supplied connections and local DuckDB inference. The same change adds secret scanning for connection targets.
For teams upgrading, the practical regression test is compact: inspect the first billed command in a project without a session ceiling, force an exhausted-budget path, and verify that the returned envelope names the intended non-secret connection target. Dex 1.9.2 makes all three behaviors explicit enough to test at the boundary.
sources
- Dex v1.9.2 release notesgithub.com
- Dex PR #392 — Exhaustion refusal now inside CostGategithub.com
- Dex PR #394 — First billed command with no budget returns needs_confirmationgithub.com
- Dex PR #395 — Budget refusal cites historical estimate-to-billed ratiogithub.com
- Dex PR #391 — Connection provenance across envelopesgithub.com
comments · 0