Bug audit catalog: 165 entries across Qt client + WGS DB#15
Open
wgs4 wants to merge 2 commits into
Open
Conversation
…GS DB)
software-bug-audit-log.json contains a structured catalog of defects found
during a two-pass static + pattern-based audit of the Qt client
(guiclient/, common/, widgets/, scriptapi/) and the WGS PostgreSQL
database (public.* and wgs.* functions, plus a coitem trigger-ordering
pass).
Methodology:
- Pass 1: grep-driven pattern scan for unchecked .exec(), ignored
stored-proc return codes, EXCEPTION WHEN OTHERS, and known TODOs
(89 entries).
- Pass 2 continuation: focused module review of GL / inventory
displays, credit-card processors, CRM forms, purchaseOrder family,
errorReporter.cpp, and targeted plpgsql function audits including
financialreport, explodewo, shipshipment, voidpostedcheck,
convertquotetoinvoice, merge2crmaccts, plus 10 wgs.* functions
and a trigger-ordering analysis on coitem (76 more entries).
Priority distribution: P0: 1, P1: 31, P2: 70, P3: 63
Confidence distribution: confirmed: 89, likely: 58, suspected: 18
software-bug-audit-log.html is a self-contained single-file viewer
(no external deps, vanilla JS) with filter/search/sort and expandable
detail panels. Open locally with `open software-bug-audit-log.html`.
No source code modified.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Every bug now tags whether the fix lands in the Qt client, the Postgres DB, or both. Mapping: location.type=qt_code -> client; db_function / db_trigger / db_view / db_table -> database. BUG-0092 (dspRunningAvailability::sDeleteOrder) is the sole "both" — its suggested fix requires changing the deletePlannedOrder DB signature AND uncommenting the client-side check. Distribution: client 71, database 93, both 1 (total 165). HTML viewer gains a sortable Side column, a Side filter dropdown, a header chip summary, and the field in the detail panel. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a structured static-audit catalog of defects across the Qt client and the WGS PostgreSQL database, along with a self-contained local HTML viewer for triage.
software-bug-audit-log.json— 165 audit entries with full schema (id, priority, confidence, location, excerpt, description, reproduction, impact, suggested fix, tags)software-bug-audit-log.html— single-file interactive viewer (vanilla JS, no external deps). Open withopen software-bug-audit-log.html.No product source code was modified.
Scope
guiclient/,common/,widgets/,scriptapi/(excludingopenrpt/,csvimp/,hunspell/submodules)public.*andwgs.*functions + triggers oncoitem,cohead,gltrans,invhist,item,poitemMethod
Two passes:
.exec(), stored-proc return codes ignored, bareEXCEPTION WHEN OTHERS, TODO/FIXME clusters, duplicate connects on populate methods.dspGLTransactions,dspJournals,dspWoSchedule,dspRunningAvailability,dspInventoryAvailability)cybersourceprocessor,verisignprocessor,authorizedotnetprocessor,paymentechprocessor)incident.cpp,opportunity.cpp,contact.cpp,crmaccount.cpp)purchaseOrder.cpp,purchaseOrderItem.cpp,enterPoReceipt.cpp,poitemTableView.cpp,common/errorReporter.cpp)financialreport,explodewo,shipshipment,issuetoshipping,voidpostedcheck,voidapopenvoucher,convertquotetoinvoice,convertprospecttocustomer,merge2crmaccts,resetdbobjperms,changefkeypointers,copyfinancialgroup,deletepackage,calculatetaxdetailsummary,calcshipfreight,createpurchasetosale,returnshipmenttransactionwgs.*functions, including the_temp-table race inwgs.determine_shipto_idand duplicate variants (pull_emails*,clean_shipcomments*)coitemBEFORE chainDistribution
Notable findings
public.shipshipment) — writescoitem_qtyshippedwith no cap againstcoitem_qtyord. 148 live rows whereqtyshipped > qtyord. P1, confirmed via live data.public.merge2crmaccts) — purge branch comparesWHERE crmacct = pSourceId(whole-row reference to the table name) instead ofcrmacct_id. Source account never deleted on merge. P1, confirmed.public.determine_shipto_id/wgs.*_temp) —*_tempare permanent tables, not session-local, so concurrent callers race and corrupt each other. P1.public.explodewo) — phantom-BOMWHILE EXISTShas no cycle guard / depth counter → infinite loop on cyclic phantoms.public.enterPoReceipt-callingpostReceipt) — inverted logic treats-11(valid 'no inventory' return) as an error contrary to the inline comment.guiclient/verisignprocessor.cpp) — 38-line stub still selectable as a CC processor.How to review
software-bug-audit-log.htmlin a browser for triage (filter by priority / module / category / confidence; click a row to expand).software-bug-audit-log.jsonis the authoritative source if you want to grep/jq.Not in scope
wgs.*functions or everyapi.*view.Test plan
python3 -m json.tool software-bug-audit-log.json— valid JSONBUG-0001..BUG-0165Note
Low Risk
Adds only static audit artifacts (JSON + standalone HTML viewer) with no runtime/product code changes, so risk is limited to repo size and data exposure in the published catalog.
Overview
Adds a structured bug-audit catalog (
software-bug-audit-log.json) containing 165 entries spanning the Qt client and PostgreSQL/WGS database, including metadata/count breakdowns and per-bug details (location, reproduction, impact, suggested fix, tags).Includes a self-contained, dependency-free HTML viewer (
software-bug-audit-log.html) that embeds the JSON and provides local search/filter/sort and expandable detail panes for triage.Reviewed by Cursor Bugbot for commit f6be53a. Bugbot is set up for automated code reviews on this repo. Configure here.