Task: Verify country CLI commands post-NATS

Table of Contents

This page documents a task in the Commission: country story. It captures the goal, current status, acceptance, and any notes or results.

Goal

Verify the four country CLI recipes (help, list, add, delete) against a live provisioned database post-NATS. Fix stale argument names; add .env and explicit-db-args variants to each recipe; refresh captured results from a live run.

Status

Field Value
State DONE
Parent story Commission: country
Now All four CLI recipes verified and updated.
Waiting on Nothing.
Next Nothing.
Last touched 2026-06-25

Acceptance

  • All four CLI recipes (help, list, add, delete) execute correctly against a live Barclays-provisioned database.
  • Each recipe shows two variants: using .env and explicit db args.
  • Captured results reflect real current runs.
  • Fixed: --recorded-by--modified-by in add recipe.
  • Notes: ORES_TENANT not in .env by default; must be exported separately.

Plan

Notes

Barclays provisioning was required to seed countries data. DB recreation (from prior SQL verification) left the DB empty; provisioning services with compass services start + compass shell -f barclays_system_provision.ores was needed. Cascading issue: other environments (local1/2/3) had idle connections consuming all PostgreSQL slots; terminated via SELECT pg_terminate_backend(pid) FROM pg_stat_activity WHERE usename LIKE 'ores_local%' before services would start cleanly.

A backlog task for compass db provision to automate the post-recreate provisioning step was filed on the "Consolidate standalone scripts into compass" story (task).

PRs

PR Title
   

Review

Comment summary File Decision Notes
       

Result

All four CLI commands verified working against live Barclays DB:

Command Result
refdata countries --help ✓ Shows help with entity listing
refdata countries list --help ✓ Shows all flags including --tenant
refdata countries list --format table ✓ 249 active countries
refdata countries list --format json --key GB ✓ Returns GB record with full JSON
refdata countries add ✓ Successfully adds XX (fixed flag: --modified-by)
refdata countries delete --key XX ✓ Soft-deletes XX

Fix found: --recorded-by in the add recipe was wrong; correct flag is --modified-by. All four recipes updated with two variants and refreshed results.

Emacs 29.1 (Org mode 9.6.6)