Prompt Details
Model
(claude-5-sonnet)
Token size
2,665
Example input
[FIRST_LOOK_NOTES]: WooCommerce site with 47 active plugins. Several plugins have not been updated in more than two years. Checkout customization is stored inside the active theme’s functions.php file. No staging environment exists. The client wants the checkout redesigned before a seasonal campaign. Payment processing currently works, but no one knows which custom hooks control tax and shipping calculations.
[AUDIT_FORMAT]: client-facing summary
[CLIENT_PRIORITY]: Redesign the checkout flow without disrupting payments, tax calculations, or shipping rules.
[HANDOFF_CONTEXT]: The previous freelance developer stopped responding.
Example output
# FIRST-WEEK TRIAGE — WooCommerce Checkout Redesign
## STEP 1 — INVENTORY
- **O1**: WooCommerce site with 47 active plugins.
- **O2**: Several plugins have not been updated in more than two years.
- **O3**: Checkout customization code is stored inside the active theme's `functions.php` file.
- **O4**: No staging environment exists.
- **O5**: Payment processing currently works.
- **O6**: No one knows which custom hooks control tax calculations.
- **O7**: No one knows which custom hooks control shipping calculations.
`Total observations: 7`
## STEP 2 — CLASSIFY RISK
| ID | Risk Class | Reason |
|---|---|---|
| O1 | NEEDS-INVESTIGATION | Interactions among 47 plugins are undocumented; scope and dependency map unknown |
| O2 | NEEDS-INVESTIGATION | Unclear which outdated plugins touch checkout/payment paths |
| O3 | DO-NOT-TOUCH-YET | Checkout logic mixed into theme file with no tests/docs; may affect payment processing |
| O4 | NEEDS-INVESTIGATION | Absence of a safe validation environment; must be established before other work proceeds |
| O5 | DO-NOT-TOUCH-YET | Currently working, but mechanism is undocumented; may affect payment processing |
| O6 | DO-NOT-TOUCH-YET | Hook location unknown; may alter production data (tax calculations) |
| O7 | DO-NOT-TOUCH-YET | Hook location unknown; may alter production data (shipping calculations) |
`SAFE-TO-MODIFY: 0`
`NEEDS-INVESTIGATION: 3`
`DO-NOT-TOUCH-YET: 4`
## STEP 3 — SILENT-BREAK SCAN
| ID | Hidden Dependency/Failure Path | What a Naive Fix Would Miss | Earliest Failure Signal | Investigation Method |
|---|---|---|---|---|
| O3 | Checkout markup, logic, and possibly payment/tax/shipping hooks share one file | A "cosmetic" redesign could delete or reorder a hook silently | Broken checkout during real traffic, not in a quick manual test | Trace callers/imports; reproduce in staging |
| O5 | Payment flow depends on undocumented logic elsewhere in the stack | Assuming the gateway integration is self-contained | Failed or duplicate charges under specific cart/discount conditions | Inspect runtime logs; review deployment history |
| O6 | Tax hook location and trigger conditions unknown | Redesign could remove or bypass tax logic without visible error | Wrong tax charged for specific regions/product types, caught late (compliance/audit) | Search configuration references; trace callers/imports |
| O7 | Shipping hook location and trigger conditions unknown | Redesign could break rate calculation for edge-case zones/weights | Incorrect shipping cost on uncommon carrier/zone combos | Search configuration references; reproduce in staging |
| O1 | Plugin-to-plugin interactions undocumented | Assuming plugins are independent of checkout markup changes | Conflict surfaces only when two specific plugins fire on the same checkout event | Trace callers/imports; inspect deployment history |
| O2 | Stale plugins may rely on deprecated hooks/APIs | Assuming "still active" means "still compatible" | Failure appears only after a WooCommerce/PHP version bump | Review deployment history; audit plugin changelogs |
`Silent-break candidates: 6`
## STEP 4 — EMIT THE AUDIT (Client-Facing Summary)
### A. Context
- **Requested audit format:** Client-facing summary
- **Client priority:** Redesign the checkout flow without disrupting payments, tax calculations, or shipping rules.
- **Handoff context:** The previous freelance developer stopped responding.
- **Evidence limitations:** No plugin names, code excerpts, hosting environment, or payment gateway details were provided. This audit is based solely on the notes above.
### B. Triage Table
| Observation ID | Observation | Risk Class | Evidence-Based Reason | Client-Priority Relevance |
|---|---|---|---|---|
| O1 | 47 active plugins | NEEDS-INVESTIGATION | Interaction map absent | Any could affect checkout rendering or logic |
| O2 | Plugins unpatched 2+ years | NEEDS-INVESTIGATION | Compatibility/security status unverified | May include checkout-adjacent plugins |
| O3 | Checkout code lives in theme `functions.php` | DO-NOT-TOUCH-YET | No isolation, no tests, no docs | Directly is the file the client wants redesigned |
| O4 | No staging environment | NEEDS-INVESTIGATION | No safe place to validate changes | Blocks safe testing of any redesign |
| O5 | Payment processing currently works | DO-NOT-TOUCH-YET | Mechanism undocumented | Client explicitly wants payments undisturbed |
| O6 | Tax-calculation hooks unknown | DO-NOT-TOUCH-YET | No visibility into logic location | Client explicitly wants tax undisturbed |
| O7 | Shipping-calculation hooks unknown | DO-NOT-TOUCH-YET | No visibility into logic location | Client explicitly wants shipping undisturbed |
### C. Silent-Break Register (highest danger)
- **O3** — Hypothesis: checkout redesign work could unknowingly remove or reorder logic that tax/shipping/payment hooks depend on. Naive fix risk: treating the file as pure front-end markup. Likely consequence: broken calculations discovered in live orders. Investigation: trace all functions/hooks in the file before any edit; reproduce checkout in staging first. Evidence required: a documented map of every hook the file registers.
- **O5** — Hypothesis: payment success today may rely on code paths not visible in the notes. Naive fix risk: assuming the gateway is decoupled from checkout markup. Likely consequence: failed/duplicate charges. Investigation: review payment logs and gateway webhook delivery records. Evidence required: confirmation of which files/hooks the gateway integration touches.
- **O6 / O7** — Hypothesis: tax and shipping totals are computed by custom hooks embedded somewhere in the theme or a plugin, location currently unknown. Naive fix risk: assuming WooCommerce defaults apply. Likely consequence: silently wrong totals on specific regions, product types, or carriers — likely to surface in a customer complaint or a reconciliation report, not in a manual test. Investigation: search the codebase for `woocommerce_calculate_totals`, `woocommerce_package_rates`, and related filter/action names; confirm behavior in staging before touching checkout.
### D. Week-One Safe List
`No modification is currently cleared as SAFE-TO-MODIFY.`
### E. Audit Dossier
**Project State:** A WooCommerce store running 47 active plugins, several unpatched for 2+ years, with checkout customization embedded in the active theme's `functions.php`. No staging environment exists. Payment processing works today, but the hooks controlling tax and shipping calculations are unmapped. The previous developer is unreachable.
**Primary Client Priority:** Redesign the checkout flow without disrupting payments, tax calculations, or shipping rules.
**Confirmed Findings:** O1 (NEEDS-INVESTIGATION), O2 (NEEDS-INVESTIGATION), O3 (DO-NOT-TOUCH-YET), O4 (NEEDS-INVESTIGATION), O5 (DO-NOT-TOUCH-YET), O6 (DO-NOT-TOUCH-YET), O7 (DO-NOT-TOUCH-YET).
**Critical Constraints:**
- O3 — may affect payment processing (checkout logic co-located with unrelated theme code).
- O5 — may affect payment processing (working mechanism undocumented).
- O6 — may alter production data (tax hooks unmapped).
- O7 — may alter production data (shipping hooks unmapped).
**Unknowns Requiring Investigation:** Plugin interaction map (O1); which outdated plugins are checkout-relevant (O2); no validated staging path exists to test changes safely (O4).
**Security and Credential Findings:** None explicitly stated in these notes (no exposed credentials mentioned here — the sample scenario had one, this one does not).
**Safe Week-One Scope:** None confirmed.
**Excluded Commitments:** A redesign delivery date; any direct edit to `functions.php`; any change to tax or shipping logic; any plugin removal/update without a compatibility check.
**Required Discovery Actions:** Map all hooks/functions in `functions.php` tied to checkout, tax, and shipping; stand up a staging environment; identify which of the 47 plugins interact with checkout; audit outdated plugins for checkout-relevant dependencies.
**Risk Counts:**
- Total observations: 7
- SAFE-TO-MODIFY: 0
- NEEDS-INVESTIGATION: 3
- DO-NOT-TOUCH-YET: 4
- Silent-break candidates: 6
## STEP 5 — VERDICT GATE
**Timeline-Safety Verdict: INVESTIGATE-FIRST**
**Decision Basis:** The client's requested work (checkout redesign) sits directly on top of four DO-NOT-TOUCH-YET items (O3, O5, O6, O7) — the exact code and logic the client wants untouched (payments, tax, shipping) is co-located with the code the client wants redesigned, and none of it has tests, documentation, or a mapped hook structure. Three further NEEDS-INVESTIGATION items (O1, O2, O4) mean there is currently no safe environment to even validate a change. Zero items are cleared SAFE-TO-MODIFY. A bounded discovery pass can resolve most of this uncertainty rather than requiring an outright refusal.
**Safe Promise:** No redesign timeline can be committed yet. What can be promised now is a scoped discovery phase: map the hooks governing tax and shipping, confirm what governs payment behavior, stand up a staging environment, and flag which of the 47 plugins are checkout-relevant.
**Required Before Reassessment:** Completed hook map for `functions.php` (tax, shipping, payment-adjacent logic); a working staging environment where checkout can be tested without touching production; a short list of plugins confirmed to interact with checkout. Once these exist, a redesign timeline can be quoted with confidence instead of a guess.
By purchasing this prompt, you agree to our terms of service
CLAUDE-5-SONNET
You just took over a codebase from a developer who left, an agency that got fired, or a founder who built it alone for three years. The client wants a timeline by Friday. You have no idea yet what's structurally sound and what's a landmine wrapped in working code.
...more
Added 4 days ago
