← Journal

Cobra · Claude context & method

Claude context files for Cobra: update + CLAUDE-dev split


Claude · HL ·

Context

Three reference files feed the Claude project dedicated to Cobra Odoo dev (cobra_odoo_context.md, cobra_connexions_ecosysteme.md, CLAUDE-dev.md). Created in May 2026, they were already outdated on critical points: Odoo hosting (SaaS → Odoo.sh), GitHub repo name, deployment workflow (Irokoo-gated → Hugo autonomous since April 2026), number of custom modules (9 → 13). Without an update, Claude started every session with a wrong mental model of the infra.

Parallel need: CLAUDE-dev.md mixed generic conventions (valid for any HL Group dev project) with Cobra-specific rules. Splitting them let me share the generic core with other projects (Shopify, Haute Fidélité…) without dragging in the Cobra rules.

What was done

Run 1 — factual update

Scanned the ~/Cobra repo on main to establish the up-to-date facts: git ls-tree → 13 cobra_* modules (not 9); git log | grep CDC → last CDC in prod = CDC-19 (not 17); reading the __manifest__.py files → real versions and authors. Three files created in ~/Cobra/docs/ (didn't exist before), with the main corrections:

  • Odoo SaaS → Odoo.sh (cobrason: Shell / Editor / Logs / Builds / Backups);
  • GitHub repo: name corrected (private repo);
  • deployment: Hugo deploys to prod on his own since ~April 2026 (cherry-pick onto main);
  • preprod = Hugo's staging; preprod3 = Irokoo, never touch it;
  • prod branch = main (not master);
  • 9 → 13 modules; last CDC = CDC-19 (next = CDC-20);
  • Claude access: XML-RPC + Odoo.sh shell (env.cr.commit() mandatory).

Commit + PR #385 to preprod.

Run 2 — residual fixes + split + rename

  • Sogetronic: matching in prod is by supplier code (product.supplierinfo.product_code), not EAN-13 as stated. The populated-product count wasn't in the log → marked [to be confirmed by Hugo] rather than inventing a figure.
  • x_qty_paid: no backfill commit on historical POs → cobra_vendor_payment_confirm downgraded from ✅ to 🔄.
  • CDC-17/18: confirmed in the git log (field_security = CDC-17, purchasing dashboard = CDC-18). Nothing to fix.

Split of CLAUDE-dev.md: on one side the generic HL Group core ("Before coding", "Code discipline", "Deliverables" + a new Autonomous loops section: executable success criterion, max 5 iterations, PROGRESS.md, human checkpoint before any irreversible action, forbidden actions listed in the extension); on the other the Cobra extension (CLAUDE-dev-cobra.md: hard deployment rules + preprodmain sync, Odoo/Shopify/SEO stack, CDCs, ongoing topics, contacts).

Rename (git mv) toward the CLAUDE-* convention: cobra_odoo_context.mdCLAUDE-cobra-odoo-context.md; cobra_connexions_ecosysteme.mdCLAUDE-cobra-connexions.md; added CLAUDE-dev-cobra.md. Convention stated at the top of the renamed files: "CLAUDE-{domain}.md = generic, CLAUDE-{domain}-{project}.md = specific." All internal cross-references updated (old → new names), zero leftovers (verified by grep). Bonus: claude-cobra-bigquery_setup_summary.mdCLAUDE-cobra-bigquery.md.

Decisions and discarded alternatives

  • A new versioned docs/ folder rather than editing scattered files in place (Desktop, Downloads, archive): the only clean option — it versions the docs with the code.
  • Split now rather than later, to avoid a third round-trip; the risk of losing content between the two files was covered by a manual coverage diff.
  • 3 atomic commits intended but the order of the git add dropped everything into a single commit (b401829): not ideal for bisectability, but the content is correct.

Snags and how we fixed them

  • Files not found: cobra_connexions_ecosysteme.md found in ~/Downloads/ via find ~ -maxdepth 6; cobra_odoo_context.md in _archive/ on the Desktop.
  • Self-contradicting "mixed authors" section (listed 5 Cobra modules while saying "4") → fixed in run 2: 7 Irokoo + 5 Cobra + 1 mixed (cobra_purchase).
  • Sogetronic: the docs said "175 products matched by EAN-13"; the git log (bc18b4e) says "matching by supplier code". A double error (method + figure); the count isn't in the log → [to be confirmed].

Result & next steps

  • 4 files in ~/Cobra/docs/: CLAUDE-cobra-odoo-context.md, CLAUDE-cobra-connexions.md, CLAUDE-dev.md (core), CLAUDE-dev-cobra.md.
  • PR #385 opened to preprod; CLAUDE-* convention applied and documented; out-of-repo rename CLAUDE-cobra-bigquery.md.

Next: merge #385 onto preprod (Odoo.sh build for verification); re-upload to Claude.ai (Cobra Odoo project: 4 files, delete the old ones; other dev projects: CLAUDE-dev.md core only); confirm the populated Sogetronic product count + Merchant Center / Search Console BigQuery status; backfill x_qty_paid on historical POs; update the local ~/Cobra/CLAUDE.md (still references SaaS, master, 11 modules, CDC-18).