12 Commits
Author SHA1 Message Date
github-actions[bot] acd7a5c514 chore: release main 2026-06-14 09:35:08 +00:00
Itamar Zand 59ca9f67ac feat: publish the CLI fleet to PyPI (per-CLI + umbrella)
Wire every cli-web-<app> CLI and a new cli-anything-web umbrella package
into release-please + PyPI Trusted Publishing, so users can install each
CLI individually (pip install cli-web-<app> / uvx cli-web-<app>) or the
whole fleet at once (pip install cli-anything-web).

- release-please-config.json / manifest: add the 20 CLIs + meta umbrella
- meta/: new cli-anything-web metapackage (unpinned deps on all CLIs)
- publish.yml: single generic resolver (tag -> dir) covers every package
- docs.py + README + per-CLI docs + skills: show the published install
- docs/PUBLISHING.md: one-time Trusted Publisher setup for all 22 projects
2026-06-14 12:29:19 +03:00
‪Itamar Zand‬‏ ded200af9d Merge pull request #30 from ItamarZand88/claude/about-cli-count
feat(devkit): keep the GitHub About CLI count in sync with the fleet
2026-06-10 15:25:45 +03:00
Itamar Zand 80a0c83519 fix(devkit): parametrize CompletedProcess[str] in about.py for mypy 2026-06-10 15:23:45 +03:00
Itamar Zand b9d8352fdd feat(devkit): keep the GitHub About CLI count in sync with the fleet
The repo "About" description embeds a count ("... N CLIs and counting.")
that was hand-maintained and had drifted (said 17; the registry has 19).
registry.json is the fleet source of truth, so the count should derive
from it.

- cli-web-devkit about: renders the count from registry.json and reconciles
  it with the live GitHub description (gh API). `--check` fails on drift
  (read-only, CI-safe); `--apply` rewrites just the count, preserving any
  reworded prose. Editing repo metadata needs Administration:write, which
  the default GITHUB_TOKEN lacks, so --apply is a maintainer/PAT step while
  --check is the CI guardrail.
- tests.yml lint job runs `about --check` (no-ops if gh metadata is
  unavailable, so it never flakes CI).
- standards Step 6 runs `about --apply` alongside the other registry-driven
  generators when a CLI is added.
- unit tests cover the count templating (replace/idempotent/append/
  reworded-prose/first-only) and registry counting.

Also corrected the live description to 19 CLIs.
2026-06-10 15:19:03 +03:00
github-actions[bot] 3c0b96b06c chore: release main 2026-06-10 11:18:22 +00:00
Itamar Zand b70aa65007 fix: eliminate all remaining fleet and tooling bugs from the review
Quality gate (validate-checklist.py):
- --auth-type now defaults to auto, resolved from registry.json with
  core/auth.py fallback — no-auth CLIs no longer fail auth checks
- 4.3/10.2 are N/A for browser-rendered clients, count status mapping
  across client.py + exceptions.py (raise_for_status pattern), and use
  an auth-aware threshold; 7.3 accepts the :cli entry function

Fleet CLIs (all 19 now pass the checklist with zero failures):
- to_dict() on base exceptions: booking, chatgpt, codewiki, futbin,
  gai, notebooklm, stitch, unsplash
- context-manager protocol on clients: booking, codewiki, gh-trending,
  notebooklm, pexels, stitch
- stderr UTF-8 fix: gai, gh-trending, stitch, unsplash
- futbin: group-level --json with ctx.obj propagation + resolve_json_mode
- gai: complete exception hierarchy (AuthError/ServerError/NotFoundError)
- chatgpt: utils/output.py as the real home of output helpers
- tripadvisor: README.md + mocked unit tests (65 passing, no network)
- youtube: full test_e2e.py (27 tests incl. TestCLISubprocess), pytest.ini
- headless token auto-refresh (3-attempt contract) wired into
  hackernews, chatgpt, and booking clients with mocked retry tests

Templates (fresh scaffolds are now lint-clean and import-clean):
- auth-dependent client code guarded for --auth-type none
- exception import members rendered sorted for any app name
- B904 exception chaining; unused imports removed/guarded
- e2e template: usage-error exit-2 test + exit-code contract FILL_IN

devkit: resync --app prints a notice that plugin-internal copies are
only synced on full-fleet runs.
2026-06-10 14:02:23 +03:00
Itamar Zand 06988a0266 fix: address code-review findings in shared runtime, pipeline, and quality gate
Shared modules (cli-web-core, resynced into all 60 vendored copies):
- doctor: honor group-level --json via ctx.obj; skip chmod warning on non-POSIX
- mcp_server: expose multiple=True/nargs=-1 params as array schemas and
  expand them item-by-item into argv (was Python-repr stringification)
- repl_skin: create history dir lazily in create_prompt_session() with
  InMemoryHistory fallback (read-only HOME broke even --help); add the 8
  missing fleet accent hex entries
- polling: treat any non-None result as complete (falsy payloads no longer
  poll until timeout)

Pipeline & devkit:
- run-pipeline validate: pass agent-harness dir + required --app-name
  (was an unconditional argparse error)
- canary: accept legacy bare-array/object JSON and leading spinner noise;
  still fail on error envelopes and success=false
- scaffold-cli: abort on missing vendored runtime file instead of shipping
  an import-broken CLI

Quality gate:
- promote auth-security checks (4.4, 4.4b, 4.6) to Tier 1 in code, markers,
  and tests; broaden 4.4b refresh detection to fleet spellings
  (_refresh_tokens, headless login_browser)

Docs:
- fix stale exit-code map in exceptions template and two committed CLIs
- repoint dangling HARNESS.md "Token Auto-Refresh" references to
  CONVENTIONS.md §Auth Rules; correct "75-check checklist" and the
  fleet exit-code note
2026-06-10 13:42:36 +03:00
Claude 6170131dca feat: refactor pipeline skill content to authoring/prompting best practices
Applies Anthropic's official workflow patterns to the four phase skills and
fixes content that had gone stale against the platform itself.

Workflow patterns (official best practices):
- Copyable progress checklists added to capture/methodology/testing/standards
  (the recommended pattern for complex multi-step workflows)
- Every phase now closes by marking phase-state complete (capture and
  standards were missing it; the validator feedback loops were already there)

Progressive disclosure:
- capture: the --mitmproxy variant (interleaved 4x through the default path)
  extracted to references/mitmproxy-mode.md as step substitutions — the
  default path reads clean
- testing: VCR cassette guide extracted to references/vcr-testing.md;
  helper-test and client-side-operation code blocks moved into
  test-code-examples.md (398 -> 332 lines, rules stay inline)
- TOCs added to all 11 reference files over 100 lines (incl. CONVENTIONS,
  RECOVERY); traffic-patterns.md nested reference chain flattened to one
  level

Stale content fixed (skills now match the platform):
- standards: 'Create setup.py' -> install-and-verify (scaffold generates it);
  'add CLI to tests.yml matrix' -> registry-driven flow (matrix and README
  table are GENERATED from registry.json — cli-web-devkit registry
  validate/docs/resync/drift + contract suite); doctor added to install
  verification; smoke-test items renumbered out of the broken 5-9 scheme
- testing: handle_errors exit-code example updated to the v2.1 contract
  (auth=3, unknown=1) with explicit legacy-CLI guidance
- methodology: versioned 'v1.3.0' analysis note rephrased as
  capability-conditional (time-sensitive content rule)

Real pipeline gap found and fixed while verifying:
- Newly scaffolded CLIs did not get mcp_server.py/doctor.py vendored or
  registered: sync.py now vendors both into the plugin's scripts/ (canon:
  cli-web-core), scaffold copies all three runtime files, cli_entry.py.tpl
  registers mcp-serve + doctor
- scaffold flags unified: --resource (repeatable) is canonical and renders
  command modules; --resources kept as comma alias (the skill documented an
  interface the script rejected — proven by scaffolding end-to-end)
- E2E verified: fresh scaffold installs, MCP handshake works, doctor green

Durable enforcement extended: test_skill_quality.py now also checks
reference files (TOC required over 100 lines, one-level reference depth).

Verified: 691 plugin/devkit/core tests, 114 contract tests, 19/19 CLI
suites, verify-plugin 28/28, drift 60/60, ruff+format+mypy clean, README
freshness green.

https://claude.ai/code/session_017wCNXuLy6UpGJ1jcPdsD5i
2026-06-10 07:09:52 +00:00
Claude 5c2f4032b1 feat: fleet-wide doctor command (self-diagnosis) via vendored core module
- cli_web_core/doctor.py: read-only environment diagnosis — Python version,
  entry point on PATH, config dir, auth file presence/permissions/format
  (auth-bearing CLIs only, detected via the auth module), playwright and
  prompt_toolkit availability. Human output + --json envelope; exit 1 only
  on fail-level findings (missing auth is a warn with the exact next step).
- Vendored to all 19 CLIs (SHARED_FILES + resync, sha256 provenance in
  manifests); doctor command wired into every entry point alongside
  mcp-serve.
- Fleet contract test: doctor --json envelope + no fail-level checks x19.
- README: doctor blurb in the agent-native section.

Verified: 425 plugin tests, 210 contract/core/devkit tests, 19/19 CLI
suites, drift 58/58 ok, ruff+format+mypy clean, verify-plugin 28/28.

https://claude.ai/code/session_017wCNXuLy6UpGJ1jcPdsD5i
2026-06-09 22:58:59 +00:00
Claude 61caad16cb feat: Phases 3-5 — generation v2, fleet ops, api-spec IR, MCP serve fleet-wide
Phase 3 (Generation v2):
- scaffold-cli.py migrated to Jinja2 (${} delimiters preserve existing
  templates; StrictUndefined; TEMPLATE_VERSION 2.0.0; .manifest.json
  provenance emission)
- auth.py.tpl unified (google-sso via {% if %} block; auth_google_sso.py.tpl
  deleted); anchor-based method injection replaced by template conditionals
- New scaffolds: command_group.py.tpl (--resource flag), test_e2e.py.tpl
  (canonical subprocess fixtures), README.md.tpl + SKILL.md.tpl (replace
  dead Handlebars .template files, now actually rendered)
- 21-profile golden test matrix (protocol x http_client x auth) — compile-
  clean, no placeholder leaks, profile-correct deps/files
- Skills consolidation: skills/shared/CONVENTIONS.md (single definition of
  every implementation rule) + RECOVERY.md (per-gate failure decision
  trees); boilerplate skill 829 -> 106 lines; HARNESS.md now navigational;
  reviewer agents de-overlapped; gap-analyzer mandatory first step of
  /refine; quality checklist tiered (38 Tier-1 critical checks) with
  --tier1-only/--strict in validate-checklist.py

Phase 4 (Fleet ops):
- cli-web-devkit canary: registry-declared read-only live-site smoke
  commands (12 no-auth CLIs) + daily canary.yml workflow that auto-files
  site-breakage issues
- contract.yml workflow: fleet contract suite + vendored-file drift on PR
- release-please switched to manifest/monorepo mode (root + cli-web-core +
  devkit packages, per-package changelogs); publish.yml with PyPI trusted
  publishing (setup guide in docs/PUBLISHING.md)
- cli-web-devkit docs: README fleet table + install block generated from
  registry.json between markers, --check freshness gate in CI (caught the
  install list missing linkedin)

Phase 5 (Product leaps):
- MCP SERVE FLEET-WIDE: cli_web_core/mcp_server.py adapter (vendored to all
  19 CLIs, synced by resync) exposes every Click command as a typed MCP
  tool over stdio; mcp-serve wired into all 19 entry points;
  contract-tested handshake x19
- api-spec.json IR: evidence-required endpoint schema + cli-web-devkit
  spec validate; wired into methodology Phase 2 (structural enforcement of
  never-invent-endpoints)
- cli-web-devkit gaps: deterministic captured-vs-implemented-vs-exposed
  diff (AST-based), wired into gap-analyzer skill Step 0
- Capture quality scoring (0-100) in validate-capture report

Fleet contract fixes found by the new gates:
- gh-trending emitted bare JSON arrays instead of the success envelope
  (fixed + e2e updated; stale version assertion fixed)
- notebooklm/stitch/codewiki/chatgpt lacked --version (fixed in Phase 2
  commit); booking registry commands corrected

Verified: 514 plugin/devkit/core tests, 95 fleet contract tests (incl. 19
MCP handshakes), 19/19 CLI unit suites, gh-trending e2e live, ruff+format
clean (512 files), mypy strict clean, verify-plugin 28/28, drift 39/39 ok,
registry + README freshness gates green.

https://claude.ai/code/session_017wCNXuLy6UpGJ1jcPdsD5i
2026-06-09 22:54:20 +00:00
Claude bbb6a88276 feat: Phase 1+2 — quality gates, cli-web-devkit, cli-web-core, fleet sync
Phase 1 (Foundations):
- Root pyproject.toml: ruff lint+format (whole monorepo), pytest, coverage,
  strict mypy on the new packages; .pre-commit-config.yaml with ruff +
  hygiene hooks + registry validation
- Repo-wide lint/format pass: 274 files reformatted, ~1,700 violations
  fixed (unused imports, import order, pyupgrade, exception chaining
  B904 x55, dead assignments, ambiguous names); futbin quoted-annotation
  imports hoisted to module level
- devkit/ (cli-web-devkit package, stdlib-only, mypy --strict):
  registry.json loader + two-way fleet validation, GitHub Actions matrix
  generation, typed TrafficEntry / PipelineState models mirroring the
  pipeline scripts' schemas
- CI rewrite: lint+format+registry job, plugin/devkit test job with
  coverage and mypy, dynamic 19-CLI test matrix generated from
  registry.json, crossed with Python 3.10 + 3.12

Phase 2 (Core runtime):
- cli-web-core/ package: canonical exceptions hierarchy (+ raise_for_status,
  error codes), --json envelope, exponential-backoff polling, REPL skin,
  subprocess test fixtures (resolve_cli/run_cli/parse_json_output) and
  fleet contract assertions; py.typed, zero hard deps
- repl_skin canon v2.0.0: back-ported display_name (gh-trending/hackernews
  variant), accent override + fleet brand colors (amazon variant), robust
  prompt_toolkit fallback (airbnb variant)
- Vendoring-with-provenance: cli-web-devkit drift/resync keep all 20
  vendored repl_skin copies byte-identical to canon; per-CLI
  .manifest.json records source + sha256 (+ override escape hatch)
- Fleet contract test suite (tests/contract): --help/--version/REPL-exit/
  no-protocol-leaks/registry-vs-help for all 19 CLIs, offline
- Fixed contract violations it caught: notebooklm/stitch/codewiki/chatgpt
  had no --version; booking registry entry described nonexistent commands

Verified: ruff check+format clean (482 files), mypy strict clean,
242 plugin/devkit/core tests, 76 contract tests, 19/19 CLI unit suites.

https://claude.ai/code/session_017wCNXuLy6UpGJ1jcPdsD5i
2026-06-09 22:28:58 +00:00