Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
93 changes: 7 additions & 86 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
branches: [main]

jobs:
# Single offline gate entry point — same as local `make ci-local`.
validate:
runs-on: ubuntu-latest

Expand All @@ -17,46 +18,15 @@ jobs:
with:
python-version: "3.11"

- uses: actions/setup-node@v4
with:
node-version: "22"

- name: Install test dependencies
run: python -m pip install -e '.[dev]'

- name: Validate skills
run: python scripts/skill_integrity_check.py

- name: Check hardcoded pricing
run: python scripts/no_hardcoded_pricing.py

- name: Check reference scope
run: python scripts/reference_scope_check.py

- name: Check provider scope
run: python scripts/provider_scope_check.py

- name: Check output contract
run: python scripts/contract_check.py

- name: Check eval coverage floor
run: python scripts/coverage_check.py

- name: Validate golden cases
run: python skills/storageops-eval-golden-cases/scripts/golden_case_validator.py skills/storageops-eval-golden-cases/cases

- name: Validate routing contract
run: python scripts/routing_contract_check.py

- name: Check repository size gates
run: python scripts/repo_size_gate.py

- name: Evaluate baseline outputs
run: |
python skills/storageops-eval-golden-cases/scripts/eval_all.py \
--cases skills/storageops-eval-golden-cases/cases \
--outputs skills/storageops-eval-golden-cases/baseline-outputs \
--only-with-outputs \
--json-out /tmp/storageops-eval.json

- name: Run tests
run: python -m pytest
- name: Run offline quality gates (make ci-local)
run: make ci-local

package:
runs-on: ubuntu-latest
Expand All @@ -74,37 +44,6 @@ jobs:
- name: Validate wheel and sdist contents
run: python scripts/package_check.py

check-extension:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Validate extension
run: |
echo "=== Checking extension file ==="
if [ ! -f storageops_cli/extensions/storageops.ts ]; then
echo "ERROR: Extension file not found at storageops_cli/extensions/storageops.ts"
exit 1
fi
if ! grep -q "scan_secrets" storageops_cli/extensions/storageops.ts; then
echo "ERROR: scan_secrets tool not found in extension"
exit 1
fi
if ! grep -q "detect_domain" storageops_cli/extensions/storageops.ts; then
echo "ERROR: detect_domain tool not found in extension"
exit 1
fi
if ! grep -q "search_memory" storageops_cli/extensions/storageops.ts; then
echo "ERROR: search_memory tool not found in extension"
exit 1
fi
if ! grep -q "capture_http_trace" storageops_cli/extensions/storageops.ts; then
echo "ERROR: capture_http_trace tool not found in extension"
exit 1
fi
echo "Extension validated."

check-docs:
runs-on: ubuntu-latest

Expand Down Expand Up @@ -212,21 +151,3 @@ jobs:
# missing required evidence, or forbidden/unsafe output).
python skills/storageops-eval-golden-cases/scripts/eval_runner.py \
--case "$CASE" --output /tmp/diag.md

# Behavioral unit tests for the 4 extension tools. Runs the real functions via
# node:test. The extension's only runtime import is `typebox` (used solely
# inside the default export, which these tests do not call), so a one-line local
# stub satisfies the import without any external dependency.
tool-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "22"
- name: Behavioral tests for extension tools
run: |
mkdir -p node_modules/typebox
printf '{"name":"typebox","version":"0.0.0","type":"module","exports":"./index.js"}' > node_modules/typebox/package.json
printf 'export const Type = {};\n' > node_modules/typebox/index.js
node --experimental-strip-types --test tests/extension/*.test.ts
9 changes: 6 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,18 @@ Packaging is the most fragile part of this repo. `storageops_cli.__init__._packa

```bash
make validate # fast skill/extension/doc gates (greps the extension only)
make ci-local # mirror CI validate job (offline; run before PR)
make ci-local # offline PR gate (mirrors CI validate job)
make validate-full # alias for ci-local
make test # alias for ci-local
make test-fast # pytest + extension tests + fast validate
make ci-full # ci-local + package-check (pre-release)
make dev # one-shot dev setup (venv, Node, storageops install)
```

`make validate` does not exercise the TypeScript extension — the routing,
provider, and trace logic is only covered by the extension behavioral tests, so
run `make ci-local` (or `make extension-tests`) when touching
`storageops_cli/extensions/storageops.ts`. `make package-check`, `install-smoke`,
run `make ci-local` (or `make test`) when touching
`storageops_cli/extensions/storageops.ts`. `make ci-full`, `install-smoke`,
and `diagnosis-smoke` need a wheel build or network/model key — see `docs/release.md`.

## Editing Skills
Expand Down
16 changes: 11 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
# Changelog

## Unreleased — Dev ergonomics (ci-local, dev_setup, doctor Node hints)
## 2026-06-29v0.7.1: Dev ergonomics & CI alignment

- **`make ci-local`** mirrors the CI `validate` job offline (provider/contract/coverage
gates, golden-case validation, pytest, extension tests, baseline eval). `make validate-full`
is now an alias.
- **`make ci-local`** mirrors the offline PR gate (provider/contract/coverage checks,
golden-case validation, pytest, extension tests, size/routing gates, baseline eval).
`make validate-full` and **`make test`** are aliases.
- **`make test-fast`** for a quicker loop (pytest + extension tests + fast `validate`).
- **`make ci-full`** runs `ci-local` plus `make package-check` (pre-release).
- **`make dev` / `scripts/dev_setup.sh`** one-shot setup: venv, editable install, Node
>= 22.19 (nvm fallback), `storageops install --force`, and `storageops doctor`.
- **`make package-check`** builds a wheel and runs `package_check.py` locally.
- **`storageops doctor`** suggests an nvm Node `PATH` prefix when the active Node is
< 22.19 (`node_path_hint` in `--json` output).
- **CI `validate` job** now runs `make ci-local` with Node 22 (drops duplicate
`check-extension` and `tool-tests` jobs; extension grep + behavioral tests live in
`make ci-local`).
- **Docs** unified to recommend `make ci-local` / `make dev` in getting-started,
skill-quality-guide, and quick-reference.

## 2026-06-21 — v0.7.0: Unify & Complete (major iteration)

Expand Down
9 changes: 5 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,13 @@ Edit `storageops_cli/__init__.py`. Be careful with:
Run these from the repository root before opening a PR:

```bash
make ci-local # mirrors CI validate job (offline)
make package-check # wheel build + package_check.py (needs network once)
make ci-local # offline PR gate (mirrors CI validate job)
make ci-full # optional pre-release: ci-local + package-check
```

`make ci-local` runs skill gates, provider/contract/coverage checks, golden-case
validation, pytest, extension tests, size/routing gates, and baseline eval.
`make test` is an alias for `make ci-local`. Use `make test-fast` for a quicker
edit loop (pytest + extension tests + fast `validate` only).

Individual scripts (for targeted debugging):

```bash
Expand Down
15 changes: 11 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
.PHONY: help validate validate-full ci-local extension-tests test install dev package-check
.PHONY: help validate validate-full ci-local ci-full extension-tests test-fast test install dev package-check

help:
@echo "StorageOps — Pi Coding Agent extension + skill pack"
@echo ""
@echo "Usage:"
@echo " make validate Fast skill/extension/doc gates (no tests run)"
@echo " make ci-local Mirror CI validate job (offline; run before PR)"
@echo " make ci-local Offline PR gate (mirrors CI validate job; run before PR)"
@echo " make validate-full Alias for ci-local"
@echo " make ci-full ci-local + package-check (pre-release)"
@echo " make test Alias for ci-local"
@echo " make test-fast pytest + extension tests + fast validate only"
@echo " make extension-tests Run the TypeScript extension behavioral tests"
@echo " make test Run pytest, extension tests, and validation"
@echo " make install Install thin CLI shim (pip install -e .)"
@echo " make dev One-shot dev setup (venv, Node, storageops install)"
@echo " make package-check Build wheel and run package_check.py (needs network once)"
Expand Down Expand Up @@ -51,11 +53,16 @@ ci-local: validate

validate-full: ci-local

test:
test: ci-local

test-fast:
python3 -m pytest
$(MAKE) extension-tests
$(MAKE) validate

ci-full: ci-local
$(MAKE) package-check

install:
pip install -e .

Expand Down
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,15 +184,18 @@ Run quality gates from a checkout:

```bash
make validate # fast skill/extension/doc gates (greps the extension)
make ci-local # mirror CI validate job (offline; run before PR)
make ci-local # offline PR gate (mirrors CI validate job)
make validate-full # alias for ci-local
make test # alias for ci-local
make test-fast # faster loop while editing
make ci-full # pre-release: ci-local + package-check
make dev # one-shot dev setup (venv, Node, storageops install)
```

`make validate` only *greps* the TypeScript extension; the routing, provider, and
trace behavior is covered by the extension tests, so run `make ci-local`
(or `make test`) before changing `storageops_cli/extensions/storageops.ts`.
`make package-check`, `install-smoke`, and `diagnosis-smoke` need a wheel build
`make ci-full`, `install-smoke`, and `diagnosis-smoke` need a wheel build
or network/model key — see [Release](docs/release.md).

## Documentation Map
Expand Down
2 changes: 1 addition & 1 deletion docs/ARCHITECTURE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Architecture

StorageOps v0.7.0 is a Pi Coding Agent extension and skill pack.
StorageOps v0.7.1 is a Pi Coding Agent extension and skill pack.

## Components

Expand Down
2 changes: 1 addition & 1 deletion docs/cli-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ from the older local package. Deployment provenance is written to
## `storageops --version`

```text
StorageOps v0.7.0 (pi: 0.78.0)
StorageOps v0.7.1 (pi: 0.78.0)
httpmon : /root/.storageops/bin/httpmon
api key : api-key file
independent install : yes (~/.storageops/agent)
Expand Down
17 changes: 13 additions & 4 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,10 +156,19 @@ v...` value before relying on the deployed skills.
## 6. Validate a Checkout

```bash
python3 scripts/skill_integrity_check.py
python3 skills/storageops-eval-golden-cases/scripts/golden_case_validator.py \
skills/storageops-eval-golden-cases/cases
make validate
make ci-local
```

For a faster edit loop while iterating on tests or the extension:

```bash
make test-fast
```

Before a release, also run:

```bash
make ci-full
```

## Troubleshooting
Expand Down
10 changes: 3 additions & 7 deletions docs/quick-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,7 @@ python3 skills/storageops-eval-golden-cases/scripts/eval_all.py \
## Validate

```bash
python3 scripts/skill_integrity_check.py
python3 scripts/routing_contract_check.py
python3 scripts/repo_size_gate.py
python3 scripts/package_check.py
python3 skills/storageops-eval-golden-cases/scripts/eval_all.py --cases skills/storageops-eval-golden-cases/cases --outputs skills/storageops-eval-golden-cases/baseline-outputs --only-with-outputs
make validate
.venv/bin/python -m pytest
make ci-local # PR gate (offline)
make test-fast # faster loop while editing
make ci-full # pre-release: ci-local + package-check
```
2 changes: 1 addition & 1 deletion docs/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Trusted Publisher.

```bash
make ci-local
make package-check # optional; wheel build + package_check.py
make ci-full # optional pre-release: + package-check
```

3. Merge the release PR to `main`.
Expand Down
17 changes: 8 additions & 9 deletions docs/skill-quality-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,16 @@ recompute — never by re-issuing the write. Live tracing stays read-only.

## Validation

Run:
Run before opening a PR:

```bash
python3 scripts/skill_integrity_check.py
python3 scripts/no_hardcoded_pricing.py
python3 scripts/reference_scope_check.py
python3 skills/storageops-eval-golden-cases/scripts/golden_case_validator.py \
skills/storageops-eval-golden-cases/cases
python3 scripts/routing_contract_check.py
make validate
.venv/bin/python -m pytest
make ci-local
```

For a faster loop while editing tests or the extension:

```bash
make test-fast
```

## Golden Cases
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "storageops"
version = "0.7.0"
version = "0.7.1"
description = "StorageOps — S3-compatible object storage diagnostic toolkit. A Pi Coding Agent extension + skill pack."
requires-python = ">=3.11"
readme = "README.md"
Expand Down
2 changes: 1 addition & 1 deletion skill-registry.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# StorageOps Skill Registry v0.7.0
# StorageOps Skill Registry v0.7.1

# Machine-readable metadata for all StorageOps skills.
# Skills are auto-discovered by Pi from the skills/ directory.
Expand Down
Loading