mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-03-22 06:10:51 -07:00
Merge pull request #23 from m-cahill/m08-snapshot-threading
docs(M07): closeout — run2, audit, summary, ledger, M08 seed
This commit is contained in:
commit
09a52ac2fe
7 changed files with 197 additions and 0 deletions
73
docs/milestones/M07/M07_audit.md
Normal file
73
docs/milestones/M07/M07_audit.md
Normal file
|
|
@ -0,0 +1,73 @@
|
|||
# M07 Audit — Opts Snapshot Introduction
|
||||
|
||||
**Milestone:** M07
|
||||
**Title:** Opts snapshot introduction
|
||||
**Branch:** m07-opts-snapshot
|
||||
**Audit date:** 2026-03-12
|
||||
**Mode:** DELTA AUDIT
|
||||
**Range:** 6744152a (M06) → 8ea50d35 (M07 merge)
|
||||
**CI Status:** Green (Quality 22983583947)
|
||||
**Refactor Posture:** Behavior-Preserving
|
||||
**Audit Verdict:** 🟢 Milestone objectives met. Infrastructure preparation; no runtime behavior change. Proceed to M08.
|
||||
|
||||
---
|
||||
|
||||
## 1. Executive Summary
|
||||
|
||||
M07 successfully introduced the opts snapshot mechanism for generation runs, establishing the third Phase II runtime seam.
|
||||
|
||||
**Wins:**
|
||||
* `create_opts_snapshot(opts)` returns a deterministic snapshot of opts.data
|
||||
* Snapshot captured in `process_images_inner` after `prepare_prompt_seed_state(p)` — post-override, post-prep
|
||||
* Full shallow copy of opts.data; no filtering (avoids omission risk)
|
||||
* Snapshot stored on `p.opts_snapshot`; write-only in M07 (no reads replaced)
|
||||
* Minimal blast radius: only `modules/opts_snapshot.py` (new) and `modules/processing.py` (modified)
|
||||
* txt2img and img2img smoke tests exercise the critical path
|
||||
|
||||
**Risks:** None identified.
|
||||
|
||||
**Next action:** Proceed to M08 (snapshot threading into process_images_inner).
|
||||
|
||||
---
|
||||
|
||||
## 2. CI Evidence
|
||||
|
||||
| Check | Result |
|
||||
|-------|--------|
|
||||
| Smoke Tests (PR #22) | 22920401686 ✓ |
|
||||
| Linter (PR #22) | 22920401661 ✓ |
|
||||
| Quality Tests (post-merge) | 22983583947 ✓ |
|
||||
| Coverage | ≥40% gate satisfied |
|
||||
| verify_pinned_deps | ✓ Passed |
|
||||
| pip-audit | Informational (M27) |
|
||||
| Artifacts | coverage.xml ✓, ci_environment ✓ |
|
||||
|
||||
---
|
||||
|
||||
## 3. Delta Map & Blast Radius
|
||||
|
||||
| Changed | Impact |
|
||||
|---------|--------|
|
||||
| modules/opts_snapshot.py | New — create_opts_snapshot(opts) |
|
||||
| modules/processing.py | Modified — capture snapshot after prepare_prompt_seed_state |
|
||||
| docs/milestones/M07/* | Plan, toolcalls, run reports |
|
||||
|
||||
**Blast radius:** Snapshot capture path only. No API/CLI/schema changes. Extensions and runtime continue reading shared.opts; p.opts_snapshot not yet consumed.
|
||||
|
||||
---
|
||||
|
||||
## 4. Category Scores
|
||||
|
||||
| Category | Score | Notes |
|
||||
|----------|-------|-------|
|
||||
| Refactor discipline | 5 | Infrastructure-only; boundaries respected |
|
||||
| Behavior preservation | 5 | No runtime drift; smoke + quality pass |
|
||||
| Test coverage | 5 | Existing smoke tests cover critical path |
|
||||
| CI integrity | 5 | All gates green |
|
||||
| **Overall** | **5.0** | |
|
||||
|
||||
---
|
||||
|
||||
## 5. Verdict
|
||||
|
||||
Milestone objectives met. Opts snapshot captured for generation runs. Third Phase II seam; enables M08 snapshot threading and removal of shared.opts dependency from the generation pipeline.
|
||||
48
docs/milestones/M07/M07_run2.md
Normal file
48
docs/milestones/M07/M07_run2.md
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
# M07 CI Run 2 — Post-Merge Quality Verification
|
||||
|
||||
**Date:** 2026-03-12
|
||||
**Branch:** main (post-merge)
|
||||
**Merge commit:** 8ea50d35
|
||||
**Trigger:** push (Merge PR #22)
|
||||
|
||||
---
|
||||
|
||||
## 1. Workflow Identity
|
||||
|
||||
| Workflow | Run ID | Trigger | Branch | Commit | Status |
|
||||
|----------|--------|---------|--------|--------|--------|
|
||||
| Quality Tests | **22983583947** | push | main | 8ea50d35 | ✓ success |
|
||||
| Linter | (push) | push | main | 8ea50d35 | ✓ success |
|
||||
|
||||
---
|
||||
|
||||
## 2. Quality Tests (22983583947)
|
||||
|
||||
| Job / Step | Required? | Purpose | Pass/Fail |
|
||||
|------------|-----------|---------|-----------|
|
||||
| Verify repository | Yes | Guardrail: m-cahill/serena only | ✓ |
|
||||
| Verify ref | Yes | Guardrail: push to main | ✓ |
|
||||
| Checkout Code | Yes | Fetch merge commit | ✓ |
|
||||
| Set up Python 3.10 | Yes | Runtime | ✓ |
|
||||
| Cache models | Yes | Deterministic model path | ✓ |
|
||||
| Install dependencies | Yes | torch, CLIP, requirements_versions | ✓ |
|
||||
| pip-audit | Informational | Dependency vuln scan | ⚠ (deferred M27) |
|
||||
| verify_pinned_deps | Yes | Pinned deps enforcement | ✓ |
|
||||
| Create stub repositories | Yes | CI fake inference | ✓ |
|
||||
| Setup environment | Yes | launch.py --exit | ✓ |
|
||||
| Start test server | Yes | Live server for API tests | ✓ |
|
||||
| **Run quality tests** | **Yes** | **pytest test** (coverage ≥40%) | **✓** |
|
||||
| Kill test server | Yes | Cleanup | ✓ |
|
||||
| Upload artifacts | No (always) | coverage.xml, htmlcov, output | ✓ |
|
||||
|
||||
**Duration:** ~4m
|
||||
|
||||
**Annotation:** pip-audit found vulnerabilities. Remediation deferred to M27. See M04_audit.md.
|
||||
|
||||
---
|
||||
|
||||
## 3. Verdict
|
||||
|
||||
**CI Status:** Green
|
||||
|
||||
All gates passed. M07 closeout verified. Ready for audit and summary generation.
|
||||
59
docs/milestones/M07/M07_summary.md
Normal file
59
docs/milestones/M07/M07_summary.md
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
# M07 Summary — Opts Snapshot Introduction
|
||||
|
||||
**Project:** Serena
|
||||
**Phase:** Phase II — Runtime Seam Preparation
|
||||
**Milestone:** M07 — Opts snapshot introduction
|
||||
**Status:** Closed
|
||||
**Branch:** m07-opts-snapshot
|
||||
**PR:** #22
|
||||
**Commit:** 8ea50d35 (merge)
|
||||
**Quality Run:** 22983583947 ✓
|
||||
|
||||
---
|
||||
|
||||
## Accomplished
|
||||
|
||||
| Item | Status |
|
||||
|------|--------|
|
||||
| Created `modules/opts_snapshot.py` | ✓ |
|
||||
| Added `create_opts_snapshot(opts)` | ✓ |
|
||||
| Snapshot capture in process_images_inner after prepare_prompt_seed_state | ✓ |
|
||||
| Full shallow copy of opts.data via SimpleNamespace | ✓ |
|
||||
| Snapshot attached to `p.opts_snapshot` | ✓ |
|
||||
| No runtime reads replaced (write-only for M07) | ✓ |
|
||||
| Preserved behavior (override logic, extension compatibility) | ✓ |
|
||||
|
||||
---
|
||||
|
||||
## CI Layout After M07
|
||||
|
||||
| Workflow | Trigger | Coverage | Security |
|
||||
|----------|---------|----------|----------|
|
||||
| Smoke Tests | pull_request (main) | No gate | None |
|
||||
| Linter | pull_request | — | — |
|
||||
| Quality Tests | push to main | ≥40% | pip-audit (informational) |
|
||||
|
||||
---
|
||||
|
||||
## Invariants Preserved
|
||||
|
||||
- Generation behavior unchanged
|
||||
- Override logic unchanged
|
||||
- Extension compatibility (shared.opts reads unchanged)
|
||||
- API compatibility (txt2img/img2img)
|
||||
- No opts reads replaced (M08 will thread snapshot)
|
||||
|
||||
---
|
||||
|
||||
## Blast Radius
|
||||
|
||||
| File | Change |
|
||||
|------|--------|
|
||||
| modules/opts_snapshot.py | New |
|
||||
| modules/processing.py | Modified |
|
||||
|
||||
---
|
||||
|
||||
## Refactor Result
|
||||
|
||||
Deterministic opts snapshot captured for generation runs. Third Phase II runtime seam; prepares for M08 snapshot threading into process_images_inner and M09 execution context.
|
||||
|
|
@ -15,3 +15,9 @@ Implementation toolcalls for Cursor execution.
|
|||
| 2026-03-10 | gh pr create | Create PR #22 | m-cahill/serena | ✓ |
|
||||
| 2026-03-10 | gh run list | Monitor CI (Linter, Smoke) | — | ✓ Linter 22920401661, Smoke 22920401686 |
|
||||
| 2026-03-10 | write | Create M07_run1.md | docs/milestones/M07/M07_run1.md | ✓ |
|
||||
| 2026-03-12 | gh pr merge | Merge PR #22 | m-cahill/serena | ✓ |
|
||||
| 2026-03-12 | write | Create M07_run2.md | docs/milestones/M07/M07_run2.md | ✓ |
|
||||
| 2026-03-12 | write | Create M07_summary.md, M07_audit.md | docs/milestones/M07/ | ✓ |
|
||||
| 2026-03-12 | search_replace | Update ledger with M07 | docs/serena.md | ✓ |
|
||||
| 2026-03-12 | run | Tag v0.0.07-m07 | 8ea50d35 | ✓ |
|
||||
| 2026-03-12 | run | Create m08-snapshot-threading branch | — | ✓ |
|
||||
|
|
|
|||
3
docs/milestones/M08/M08_plan.md
Normal file
3
docs/milestones/M08/M08_plan.md
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
# M08 Plan — Snapshot Threading into process_images_inner
|
||||
|
||||
(To be populated.)
|
||||
5
docs/milestones/M08/M08_toolcalls.md
Normal file
5
docs/milestones/M08/M08_toolcalls.md
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
# M08 Toolcalls — Snapshot Threading into process_images_inner
|
||||
|
||||
Implementation toolcalls for Cursor execution.
|
||||
|
||||
(To be filled during milestone execution.)
|
||||
|
|
@ -136,11 +136,14 @@ Core principles:
|
|||
| M04 | Coverage/security/reproducibility guardrails | Completed | m04-coverage-guardrails | #4 | 47439cac | Quality 22871471473 ✓ (coverage 40%, pip-audit, verify_pinned_deps) | 5.0 / 5 | 2026-03-09 |
|
||||
| M05 | Override isolation / temporary opts seam | Completed | m05-override-isolation | #18 (+ #19 fix) | ae161cbb | Quality 22888808682 ✓ | 5.0 / 5 | 2026-03-10 |
|
||||
| M06 | Prompt/seed prep extraction | Completed | m06-prompt-seed-prep | #20 | 6744152a | Quality 22890285319 ✓ | 5.0 / 5 | 2026-03-10 |
|
||||
| M07 | Opts snapshot introduction | Completed | m07-opts-snapshot | #22 | 8ea50d35 | Quality 22983583947 ✓ | 5.0 / 5 | 2026-03-12 |
|
||||
|
||||
**M05:** Introduced `temporary_opts()` context manager — first Phase II runtime seam. Isolates override_settings mutation from global `shared.opts`; preserves behavior (opts.set, setattr restore, k in opts.data). Model/VAE reload and token merging remain in process_images. Enables future opts snapshot injection (M07).
|
||||
|
||||
**M06:** Extracted `prepare_prompt_seed_state(p)` into `modules/prompt_seed_prep.py`. Second Phase II runtime seam. Populates p.all_seeds and p.all_subseeds; setup_prompts and fill_fields_from_opts unchanged. Enables M07 opts snapshot and M09 execution context.
|
||||
|
||||
**M07:** Introduced `create_opts_snapshot(opts)` in `modules/opts_snapshot.py`. Third Phase II runtime seam. Captures deterministic snapshot of opts.data in process_images_inner after prepare_prompt_seed_state; stored on p.opts_snapshot. Write-only in M07; enables M08 snapshot threading.
|
||||
|
||||
---
|
||||
|
||||
## 5. Standing Invariants
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue