Skip to content
Centriu
Centriu Loop

Production Inventory Silent Partial-Failure Automation: A Green Exit Code Is Not the Same as a Complete Report

Centriu Loop runs a dedicated, read-only inventory script specifically to measure and report the real, current state of the module's own access configuration in production — a genuine verification step, not a guess from reading code. One specific section of that report joined a permissions table to a modules table using a column, `modules.slug`, that does not actually exist on that table — producing a real, raw database error (`ERROR: column "slug" does not exist`) printed directly into the middle of an otherwise fully successful, nine-section report, with the script's own exit code still reporting success (0). That report — containing one silently broken, error-printing section — had already been referenced elsewhere as evidence that production access configuration was fully measured and intact. The fix's own account is explicit about the lesson this specific failure teaches beyond the one broken query: an audit or inventory report containing even one dead, error-printing block trains whoever reads it to read past the noise as normal output — and the next broken block, whatever it measures, will pass unnoticed for the exact same reason. The underlying financial data was never actually at risk: every OTHER section of the same report — aggregate reconciliation, orphaned-record detection — ran correctly the entire time; only this one specific permissions-enumeration section was silently broken. The fix corrects the query to read a module's name from the column that actually holds it (the permissions table's own `module` text field, which stores the name directly, rather than joining out to a column that was never there) — the corrected section now reports real, specific figures instead of an unhandled database error.
SQL error, exit code 0
6 rows, 2 orgs, 5 roles
Production inventory report screen
A green exit code is not a complete report.

A report that keeps running after one section breaks is not the same as a report that finished correctly

A script built to produce several independent sections of a report — one query per section, printed in sequence — commonly continues to the next section even if one query fails, rather than aborting the entire run over a single broken part. That design choice is often the right one: a partial report with eight working sections and one error is more useful than no report at all. The risk specific to this design is what happens to the SCRIPT'S OWN exit code, and to whoever reads the report afterward: if the exit code still reports overall success, and the broken section's error message looks similar enough to ordinary diagnostic output, a report containing a genuine, unaddressed failure can be read, cited, and relied upon as if every section in it had actually succeeded.

How the underlying problem shows up before you fix it

A multi-section report or inventory script continues running after one section's query fails, printing that failure's raw error text in the position where a successful result would normally appear, without the script's own final exit status reflecting that partial failure.

A query fails because it references a column that does not actually exist on the table being queried — a defect a schema-aware type check would catch immediately, but a script that only ever RUNS against a live database (rather than being checked against the schema ahead of time) would not surface until that exact section is executed.

A report containing one dead, error-printing section, generated once, gets cited elsewhere afterward as evidence that a broader condition (here: production access being fully measured) holds — with nobody re-examining the specific section that never actually produced a real answer.

A read-only verification or audit script's own safety constraint (permitting only read queries, never a write) shapes not just what the script can do, but what an earlier, incorrect DRAFT of a proposed fix can even be tested with — a fix attempt that violates that constraint is correctly rejected by the same guard that makes the script trustworthy in the first place.

The actual, more consequential system the report was meant to verify (here: real financial data and its own reconciliation) can be functioning correctly for the entire time one specific, narrower section of the SAME report is silently broken — a broad "production is fine" conclusion drawn from a partially-broken report risks conflating what was actually verified with what merely appeared to run.

How a dead section in a nine-part report went from "exit 0" to a real answer

Centriu Loop maintains a dedicated, read-only production inventory script specifically to measure and report the real, live state of the module's own access configuration — a genuine, direct verification against the actual running database, deliberately built to answer questions about production with more certainty than reading migration files or application code alone could provide. The script's design produces several independent sections in sequence, each answering a distinct question.

One specific section, meant to enumerate which organizations and roles currently hold which module-level permissions, joined a permissions table to a separate modules table using a column named `modules.slug` — a column that, in the actual production schema, does not exist on that table at all. Running that query against the real database produced a genuine, specific SQL error (`ERROR: column "slug" does not exist`), and that raw error text was printed directly into the report, in the exact position where a working section's real results would otherwise have appeared — sitting among nine total sections, the other eight of which ran and reported correctly.

The script's own overall exit code still reported success (0) despite this one section's failure — a design consistent with letting a partial report through rather than aborting the entire run over one broken part, but one that gave no distinct signal, at the script's own top level, that anything inside the report actually required attention. The fix's own account is explicit about the more general lesson this specific incident is used to illustrate: a report or audit output containing even one dead, error-printing block — however it got there — trains whoever reads that report regularly to treat unfamiliar-looking output near the report's edges as ordinary noise rather than as a signal, and the very NEXT time a different section breaks in a similarly unfamiliar way, it will very plausibly be read past for the identical reason. This particular report had already been cited, before the defect was found, as evidence that production access configuration was fully and correctly measured — a claim the broken section could not actually support, regardless of what the other eight sections legitimately proved.

It is worth stating plainly what this defect did NOT put at risk: every other section of the same inventory — the ones reconciling aggregate financial totals and identifying orphaned records with no valid owner — ran correctly the entire time, and the underlying financial data itself was never shown to be, nor found to be, in any doubt. The defect was narrow and specific: one particular section, measuring who currently holds which module-level permission, silently failed to measure anything at all.

The fix itself is a one-line correction to the query's source of truth: rather than joining out to a `modules.slug` column that was never actually present in production, the corrected query reads the module's name directly from the permissions table's own `module` text column, which already stores that name without requiring any join at all. Run against the real database, the corrected section now reports concrete, specific figures — six matching rows, spanning two organizations, across five distinct roles (admin, client, executor, manager, and salesperson) — replacing what had been an unhandled database error with an actual, verifiable answer.

A smaller, specific detail shaped how the fix itself had to be diagnosed and verified: the inventory script carries its own standing safety rule requiring every query it runs to begin with `select` or `with`, specifically because the entire script is meant to be strictly read-only against production. That same guard correctly rejected an earlier, exploratory version of the corrected query that had been temporarily commented out for inspection during debugging — the identical safety mechanism that makes this script trustworthy to run directly against live production data also, correctly, refused to let a malformed draft of its own fix slip through unexamined.

What is actually built today

Centriu Loop's production access-permissions inventory section now reads a module's name directly from the permissions table's own `module` column, rather than joining out to a `modules.slug` column that does not exist in the production schema.

The corrected section reports concrete, verifiable figures measured directly against the live database — 6 matching rows, 2 organizations, 5 distinct roles — replacing what had previously been an unhandled, silently-printed database error.

The inventory script's standing read-only safety rule (every query must begin with `select` or `with`) remains unchanged and continues to guard against any write ever being introduced into this specific verification tool, including during the debugging of its own defects.

The other eight sections of the same inventory report (including aggregate financial reconciliation and orphaned-record detection) were unaffected by this defect and continue to run and report exactly as before.

The fix's own documentation explicitly retracts the earlier, broader claim that had cited the un-repaired report as proof production access configuration was fully measured — replacing it with the actual, now-correct measurement.

A raw SQL error, mistaken for a clean bill of health (illustrative framing of the actual measured finding)

Before the fix, running Centriu Loop's production inventory script produced a nine-section report in which one specific section — meant to enumerate current permissions by organization and role — printed the raw text `ERROR: column "slug" does not exist" instead of an actual answer, while the script's own final exit code still reported overall success. That exact report had already been referenced elsewhere as confirmation that production access configuration was fully measured and correct. After the fix, the identical section instead reports a specific, concrete answer — 6 rows, 2 organizations, 5 distinct roles — measured directly against the real production database, with no error printed anywhere in the report.

What changes operationally

Centriu Loop's production access-permissions inventory section now runs successfully against the real database, reporting concrete, specific figures instead of a silently-printed SQL error that had previously gone unnoticed inside an otherwise-successful, exit-0 report — correcting a report that had already been cited elsewhere as proof of full measurement, while confirming the OTHER eight sections of the same report, including financial reconciliation, had been running correctly the entire time.

When this is not the right fit

This automation governs the internal correctness of Centriu Loop's own read-only production-inventory verification script — it does not change any customer-facing feature, does not alter the actual permissions or financial data being measured, and is specific to a script's own single defective query; a monitoring or auditing approach that surfaces a query-level failure as a distinct, non-zero exit condition rather than embedding it inside a still-successful report would not be exposed to this exact class of silent partial failure.

A report that keeps going after a broken section vs. one that surfaces the break distinctly

Letting a multi-section report continue past one section's failure, printing that failure's raw error text and moving on, preserves the value of every OTHER section that does succeed — the alternative, aborting an entire report over one broken part, would have hidden the eight working sections along with the one broken one. The gap is specifically in the script's own FINAL exit status: continuing past a failure while still reporting overall success at the end removes the one signal that would have reliably told an automated caller, or a habitual reader skimming for a nonzero exit code, that something inside this specific report still needs a second look.

Related systems

Main system: Centriu Loop.

What it does NOT do

  • Does not indicate that Centriu Loop's actual financial data was ever incorrect or at risk — every other section of the same inventory report, including aggregate financial reconciliation, ran correctly throughout; only one specific permissions-enumeration section was silently broken.
  • Does not change what the inventory script measures or reports beyond correcting the one broken query — the same nine-section report structure remains, with the previously-broken section now producing a real answer instead of an error.
  • Does not retroactively verify every OTHER report or script in the codebase for the identical class of defect — this fix corrects the one specific query identified and measured in this commit; a team with a broader concern would need its own separate audit.
  • Does not change the inventory script's own read-only safety guarantee — every query the script runs must still begin with `select` or `with`, exactly as before, and that guard correctly rejected an early draft of this very fix during its own development.
  • Does not overlap with the deploy-guard fix from the same day (covered on a companion page) — that fix corrects a deploy-time PREVENTION scanner; this fix corrects a MEASUREMENT script. The two are architecturally unrelated beyond sharing a deploy date.

Security and governance

Centriu Loop's production access-permissions inventory section now measures real, live permissions data correctly, replacing a previously silent, unhandled SQL error with a concrete, verifiable answer — while the script's standing read-only safety guard (every query must begin with `select` or `with`) remains unchanged. Any personal or financial data referenced in inventory results remains subject to Brazil's LGPD (Law No. 13,709/2018). Full detail on access control lives at /governanca and /iso.

Pricing and contracting

Available by monthly subscription, with tiered plans. Values and terms come from the official pricing table at /precos (Centriu's central source — never restated here).

Frequently asked questions

Was any real financial data actually wrong or at risk because of this defect?

No — the defect was isolated to one specific permissions-enumeration section of a nine-section report. The other sections, including aggregate financial reconciliation and orphaned-record detection, ran correctly the entire time.

How did a broken query end up looking like a passing report?

The script continued to the next section after this one query failed, printing the raw database error in place of a real result, and the script's own final exit code still reported overall success (0) — giving no distinct signal that one section had actually failed.

Had the broken report actually been relied on for anything before this was found?

Yes — the fix's own account states the report had already been cited elsewhere as evidence that production access configuration was fully measured, a claim the broken section could not actually support.

What was the actual bug in the query?

It joined a permissions table to a separate modules table using a column, `modules.slug`, that does not exist in the production schema. The fix reads the module's name directly from the permissions table's own `module` column instead, which already stores that name without needing a join.

Why does the fix mention the script rejecting an earlier draft of itself?

The inventory script enforces that every query it runs must begin with `select` or `with`, since it is meant to be strictly read-only against production. That same guard correctly rejected a commented-out, malformed early draft of the corrected query during development — the same mechanism that makes the script trustworthy also caught a mistake in fixing it.

What does Centriu Loop cost?

It is sold by subscription with a published starting price — exact current values are on the central pricing page.

See how Centriu Loop verifies production access configuration for real

Reach our commercial team directly, or leave your details below — we'll follow up with guidance for your case.

Sources

  1. Centriu Loop — public product page — Centriu, 2026-07-20 · link(primária)
  2. Centriu Loop — public factsheet (API, JSON) — Centriu, 2026-07-21 · link
  3. Law No. 13,709/2018 — Brazil’s General Data Protection Law (LGPD) — Presidência da República (Brazil), 2018-08-14 · link

Last material update on .

By · AI-assisted production, with human review