Skip to content

Commit 7e397c5

Browse files
Merge branch 'develop' into feature/25-use-dev-docs-container
2 parents 9ee8899 + 04adb3a commit 7e397c5

13 files changed

Lines changed: 132 additions & 185 deletions

File tree

.github/workflows/ci-push.yml

Lines changed: 0 additions & 29 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
# ---------------------------------------------------------------------------
3232

3333
security-and-standards:
34-
uses: wphillipmoore/standard-actions/.github/workflows/ci-security.yml@develop
34+
uses: wphillipmoore/standard-actions/.github/workflows/ci-security.yml@v1.3
3535
permissions:
3636
contents: read
3737
security-events: write
@@ -127,18 +127,7 @@ jobs:
127127
- name: Run pip-licenses (license compliance)
128128
run: >-
129129
uv run pip-licenses
130-
--allow-only="Apache-2.0;
131-
Apache-2.0 OR BSD-2-Clause;
132-
Apache Software License;
133-
BSD License;
134-
BSD-2-Clause;
135-
BSD-3-Clause;
136-
GPL-3.0-or-later;
137-
MIT;
138-
MIT License;
139-
Mozilla Public License 2.0 (MPL 2.0);
140-
PSF-2.0;
141-
Python Software Foundation License"
130+
--allow-only="$(grep -v '^#' .pip-licenses-allowlist | grep -v '^$' | paste -sd ';' -)"
142131
143132
# ---------------------------------------------------------------------------
144133
# Integration tests
@@ -156,7 +145,7 @@ jobs:
156145
uses: actions/checkout@v6
157146

158147
- name: Set up Python
159-
uses: wphillipmoore/standard-actions/actions/python/setup@develop
148+
uses: wphillipmoore/standard-actions/actions/python/setup@v1.3
160149
with:
161150
python-version: ${{ matrix.python-version }}
162151

@@ -218,7 +207,7 @@ jobs:
218207

219208
- name: Version divergence gate (PRs targeting develop)
220209
if: github.event_name == 'pull_request' && github.base_ref == 'develop'
221-
uses: wphillipmoore/standard-actions/actions/release-gates/version-divergence@develop
210+
uses: wphillipmoore/standard-actions/actions/release-gates/version-divergence@v1.3
222211
with:
223212
head-version-command: python3 -c "import tomllib; from pathlib import Path; print(tomllib.loads(Path('pyproject.toml').read_text())['project']['version'])"
224213
main-version-command: git show origin/main:pyproject.toml | python3 -c "import sys, tomllib; print(tomllib.loads(sys.stdin.read())['project']['version'])"

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
run: uv sync --frozen --group docs
3030

3131
- name: Deploy docs
32-
uses: wphillipmoore/standard-actions/actions/docs-deploy@develop
32+
uses: wphillipmoore/standard-actions/actions/docs-deploy@v1.3
3333
with:
3434
version-command: uv run python -c "from importlib.metadata import version; v=version('pymqrest'); print('.'.join(v.split('.')[:2]))"
3535
mike-command: uv run mike

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ permissions:
1313

1414
jobs:
1515
publish:
16-
uses: wphillipmoore/standard-actions/.github/workflows/publish-release.yml@develop
16+
uses: wphillipmoore/standard-actions/.github/workflows/publish-release.yml@v1.3
1717
permissions:
1818
attestations: write
1919
contents: write

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,3 +206,4 @@ cython_debug/
206206
marimo/_static/
207207
marimo/_lsp/
208208
__marimo__/
209+
.worktrees/

CLAUDE.md

Lines changed: 86 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,80 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
55
<!-- include: docs/standards-and-conventions.md -->
66
<!-- include: docs/repository-standards.md -->
77

8+
## Auto-memory policy
9+
10+
**Do NOT use MEMORY.md.** Never write to MEMORY.md or any file under the
11+
memory directory. All behavioral rules, conventions, and workflow instructions
12+
belong in managed, version-controlled documentation (CLAUDE.md, AGENTS.md,
13+
skills, or docs/). If you want to persist something, tell the human what you
14+
would save and let them decide where it belongs.
15+
16+
## Parallel AI agent development
17+
18+
This repository supports running multiple Claude Code agents in parallel via
19+
git worktrees. The convention keeps parallel agents' working trees isolated
20+
while preserving shared project memory (which Claude Code derives from the
21+
session's starting CWD).
22+
23+
**Canonical spec:**
24+
[`standard-tooling/docs/specs/worktree-convention.md`](https://github.com/wphillipmoore/standard-tooling/blob/develop/docs/specs/worktree-convention.md)
25+
— full rationale, trust model, failure modes, and memory-path implications.
26+
The canonical text lives in `standard-tooling`; this section is the local
27+
on-ramp.
28+
29+
### Structure
30+
31+
```text
32+
~/dev/github/mq-rest-admin-python/ ← sessions ALWAYS start here
33+
.git/
34+
CLAUDE.md, src/, tests/, … ← main worktree (usually `develop`)
35+
.worktrees/ ← container for parallel worktrees
36+
issue-454-adopt-worktree-convention/ ← worktree on feature/454-...
37+
38+
```
39+
40+
### Rules
41+
42+
1. **Sessions always start at the project root.**
43+
`cd ~/dev/github/mq-rest-admin-python && claude` — never from inside
44+
`.worktrees/<name>/`. This keeps the memory-path slug stable and shared.
45+
2. **Each parallel agent is assigned exactly one worktree.** The session
46+
prompt names the worktree (see Agent prompt contract below).
47+
- For Read / Edit / Write tools: use the worktree's absolute path.
48+
- For Bash commands that touch files: `cd` into the worktree first,
49+
or use absolute paths.
50+
3. **The main worktree is read-only.** All edits flow through a worktree
51+
on a feature branch — the logical endpoint of the standing
52+
"no direct commits to `develop`" policy.
53+
4. **One worktree per issue.** Don't stack in-flight issues. When a
54+
branch lands, remove the worktree before starting the next.
55+
5. **Naming: `issue-<N>-<short-slug>`.** `<N>` is the GitHub issue
56+
number; `<short-slug>` is 2–4 kebab-case tokens.
57+
58+
### Agent prompt contract
59+
60+
When launching a parallel-agent session, use this template (fill in the
61+
placeholders):
62+
63+
```text
64+
You are working on issue #<N>: <issue title>.
65+
66+
Your worktree is: /Users/pmoore/dev/github/mq-rest-admin-python/.worktrees/issue-<N>-<slug>/
67+
Your branch is: feature/<N>-<slug>
68+
69+
Rules for this session:
70+
- Do all git operations from inside your worktree:
71+
cd <absolute-worktree-path> && git <command>
72+
- For Read / Edit / Write tools, use the absolute worktree path.
73+
- For Bash commands that touch files, cd into the worktree first
74+
or use absolute paths.
75+
- Do not edit files at the project root. The main worktree is
76+
read-only — all changes flow through your worktree on your
77+
feature branch.
78+
```
79+
80+
All fields are required.
81+
882
## Project Overview
983

1084
`pymqrest` is a Python wrapper for the IBM MQ administrative REST API. The project provides a Python mapping layer for MQ REST API attribute translations and command metadata experiments. The current focus is on attribute mapping and metadata modeling.
@@ -18,24 +92,26 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
1892
### Standard Tooling
1993

2094
```bash
21-
cd ../standard-tooling && uv sync # Install standard-tooling
22-
export PATH="../standard-tooling/.venv/bin:../standard-tooling/scripts/bin:$PATH" # Put tools on PATH
23-
git config core.hooksPath ../standard-tooling/scripts/lib/git-hooks # Enable git hooks
95+
git config core.hooksPath ../standard-tooling/scripts/lib/git-hooks # Enable git hooks
2496
```
2597

98+
Standard-tooling CLI tools (`st-commit`, `st-validate-local`, etc.) are
99+
pre-installed in the dev container images. No local setup required.
100+
26101
### Environment Setup
27102

28103
```bash
29104
# Install dependencies and sync environment
30105
uv sync --group dev
31106
```
32107

33-
### Three-Tier CI Model
108+
### Two-Tier CI Model
34109

35-
Testing is split across three tiers with increasing scope and cost:
110+
Testing is split across two tiers with increasing scope and cost:
36111

37112
**Tier 1 — Local pre-commit (seconds):** Fast smoke tests in a single
38-
container. Run before every commit. No MQ, no matrix.
113+
container. Enforced via the `.githooks` pre-commit gate on every commit.
114+
No MQ, no matrix.
39115

40116
```bash
41117
./scripts/dev/test.sh # Unit tests in dev-python:3.14
@@ -44,16 +120,14 @@ container. Run before every commit. No MQ, no matrix.
44120
./scripts/dev/audit.sh # pip-audit in dev-python:3.14
45121
```
46122

47-
**Tier 2 — Push CI (~3-5 min):** Triggers automatically on push to
48-
`feature/**`, `bugfix/**`, `hotfix/**`, `chore/**`. Single Python version
49-
(3.14), includes integration tests, no security scanners or release gates.
50-
Workflow: `.github/workflows/ci-push.yml` (calls `ci.yml`).
51-
52-
**Tier 3 — PR CI (~8-10 min):** Triggers on `pull_request`. Full Python
123+
**Tier 2 — PR CI (~8-10 min):** Triggers on `pull_request`. Full Python
53124
matrix (3.12, 3.13, 3.14), all integration tests, security scanners (CodeQL,
54125
Trivy, Semgrep), standards compliance, and release gates. Workflow:
55126
`.github/workflows/ci.yml`.
56127

128+
Push-CI was retired once `st-validate-local` reached parity with PR-CI.
129+
See wphillipmoore/standard-actions#176 for the parity audit and rationale.
130+
57131
### Validation
58132

59133
```bash

requirements-dev.txt

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# This file was autogenerated by uv via the following command:
2-
# uv export --no-hashes --group dev -o requirements-dev.txt
3-
-e .
2+
# uv export --no-hashes --only-group dev -o requirements-dev.txt
43
boolean-py==5.0
54
# via license-expression
65
cachecontrol==0.14.4
@@ -45,7 +44,7 @@ packaging==26.0
4544
# pytest
4645
pathspec==1.0.4
4746
# via mypy
48-
pip==26.0.1
47+
pip==26.1
4948
# via pip-api
5049
pip-api==0.0.34
5150
# via pip-audit
@@ -63,20 +62,19 @@ prettytable==3.17.0
6362
# via pip-licenses
6463
py-serializable==2.1.0
6564
# via cyclonedx-python-lib
66-
pygments==2.19.2
65+
pygments==2.20.0
6766
# via
6867
# pytest
6968
# rich
7069
pyparsing==3.3.2
7170
# via pip-requirements-parser
72-
pytest==9.0.2
71+
pytest==9.0.3
7372
# via pytest-cov
7473
pytest-cov==7.0.0
75-
requests==2.32.5
74+
requests==2.33.1
7675
# via
7776
# cachecontrol
7877
# pip-audit
79-
# pymqrest
8078
rich==14.3.3
8179
# via pip-audit
8280
ruff==0.15.4

requirements.txt

Lines changed: 4 additions & 91 deletions
Original file line numberDiff line numberDiff line change
@@ -1,100 +1,13 @@
11
# This file was autogenerated by uv via the following command:
2-
# uv export --no-hashes -o requirements.txt
2+
# uv export --no-hashes --no-dev -o requirements.txt
33
-e .
4-
boolean-py==5.0
5-
# via license-expression
6-
cachecontrol==0.14.4
7-
# via pip-audit
84
certifi==2026.2.25
95
# via requests
106
charset-normalizer==3.4.4
117
# via requests
12-
colorama==0.4.6 ; sys_platform == 'win32'
13-
# via pytest
14-
coverage==7.13.4
15-
# via pytest-cov
16-
cyclonedx-python-lib==11.6.0
17-
# via pip-audit
18-
defusedxml==0.7.1
19-
# via py-serializable
20-
filelock==3.25.0
21-
# via cachecontrol
228
idna==3.11
239
# via requests
24-
iniconfig==2.3.0
25-
# via pytest
26-
librt==0.8.1 ; platform_python_implementation != 'PyPy'
27-
# via mypy
28-
license-expression==30.4.4
29-
# via cyclonedx-python-lib
30-
markdown-it-py==4.0.0
31-
# via rich
32-
mdurl==0.1.2
33-
# via markdown-it-py
34-
msgpack==1.1.2
35-
# via cachecontrol
36-
mypy==1.19.1
37-
mypy-extensions==1.1.0
38-
# via mypy
39-
packageurl-python==0.17.6
40-
# via cyclonedx-python-lib
41-
packaging==26.0
42-
# via
43-
# pip-audit
44-
# pip-requirements-parser
45-
# pytest
46-
pathspec==1.0.4
47-
# via mypy
48-
pip==26.0.1
49-
# via pip-api
50-
pip-api==0.0.34
51-
# via pip-audit
52-
pip-audit==2.10.0
53-
pip-licenses==5.5.1
54-
pip-requirements-parser==32.0.1
55-
# via pip-audit
56-
platformdirs==4.9.2
57-
# via pip-audit
58-
pluggy==1.6.0
59-
# via
60-
# pytest
61-
# pytest-cov
62-
prettytable==3.17.0
63-
# via pip-licenses
64-
py-serializable==2.1.0
65-
# via cyclonedx-python-lib
66-
pygments==2.19.2
67-
# via
68-
# pytest
69-
# rich
70-
pyparsing==3.3.2
71-
# via pip-requirements-parser
72-
pytest==9.0.2
73-
# via pytest-cov
74-
pytest-cov==7.0.0
75-
requests==2.32.5
76-
# via
77-
# cachecontrol
78-
# pip-audit
79-
# pymqrest
80-
rich==14.3.3
81-
# via pip-audit
82-
ruff==0.15.4
83-
sortedcontainers==2.4.0
84-
# via cyclonedx-python-lib
85-
tomli==2.4.0
86-
# via pip-audit
87-
tomli-w==1.2.0
88-
# via pip-audit
89-
ty==0.0.19
90-
types-requests==2.32.4.20260107
91-
typing-extensions==4.15.0
92-
# via
93-
# cyclonedx-python-lib
94-
# mypy
10+
requests==2.33.1
11+
# via pymqrest
9512
urllib3==2.6.3
96-
# via
97-
# requests
98-
# types-requests
99-
wcwidth==0.6.0
100-
# via prettytable
13+
# via requests

scripts/dev/audit.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ set -euo pipefail
44
export DOCKER_DEV_IMAGE="${DOCKER_DEV_IMAGE:-dev-python:3.14}"
55
export DOCKER_TEST_CMD="${DOCKER_TEST_CMD:-uv sync --check --frozen --group dev && uv lock --check && uv run pip-audit -r requirements.txt -r requirements-dev.txt && uv run pip-licenses --allow-only=\"\$(grep -v '^\#' .pip-licenses-allowlist | grep -v '^\$' | paste -sd ';' -)\"}"
66

7-
if ! command -v docker-test >/dev/null 2>&1; then
8-
echo "ERROR: docker-test not found on PATH." >&2
9-
echo "Set up standard-tooling: export PATH=../standard-tooling/scripts/bin:\$PATH" >&2
7+
if ! command -v st-docker-test >/dev/null 2>&1; then
8+
echo "ERROR: st-docker-test not found on PATH." >&2
9+
echo "Set up standard-tooling: export PATH=../standard-tooling/.venv/bin:\$PATH" >&2
1010
exit 1
1111
fi
12-
exec docker-test
12+
exec st-docker-test

0 commit comments

Comments
 (0)