Skip to content

retrofit: mint infrastructure-helpers capability (3 REQs / 6 methods)#297

Merged
rubenvdlinde merged 1 commit into
developmentfrom
retrofit/reverse-spec-mydash-infrastructure-helpers-2026-05-24
May 25, 2026
Merged

retrofit: mint infrastructure-helpers capability (3 REQs / 6 methods)#297
rubenvdlinde merged 1 commit into
developmentfrom
retrofit/reverse-spec-mydash-infrastructure-helpers-2026-05-24

Conversation

@rubenvdlinde
Copy link
Copy Markdown
Contributor

Retrofit — Reverse-Spec

Mints a new `infrastructure-helpers` capability covering 6 methods across 3 cross-cutting helper classes flagged Bucket 2b by the 2026-05-24 coverage scan (no owning capability).

Ghost change: `archive/2026-05-24-retrofit-infrastructure-helpers` (archived in this PR).

What this PR does

  • Creates a new `openspec/specs/infrastructure-helpers/spec.md` with `retrofit: true` frontmatter
  • Drafts 3 REQs (one per helper class):
    • REQ-INFRA-001 — SlugGenerator: slug grammar, transform pipeline, validation
    • REQ-INFRA-002 — UserAttributeResolver: 4 supported attributes + 5 comparison operators
    • REQ-INFRA-003 — RequestDataExtractor: tile + placement form data extraction
  • Creates tasks.md with one task per REQ (all `[x]` — code already exists)
  • Annotates 6 methods + 3 files with `@spec openspec/changes/archive/2026-05-24-retrofit-infrastructure-helpers/tasks.md#task-N` (Phase 2's existing `@spec` on `UserAttributeResolver::getUserAttributeValue` is preserved; new tag is appended)
  • Archives the change

Why a new capability rather than `--extend`?

Per ADR-003 and the SKILL's bias-toward-`--extend` rule, considered alternatives:

Option Why rejected
`--extend dashboards` (SlugGenerator) Slug helper is reusable beyond dashboards
`--extend conditional-visibility` (UserAttributeResolver) Resolver is a generic primitive; the visibility logic that uses it stays put
Per-method splits across `tiles` + `widgets` (RequestDataExtractor) Would duplicate the helper's contract across two specs
Split into three different capabilities Would scatter the helpers' shared architectural shape

The new capability includes a `## Scope` section that prevents drift: future helpers that DO fit a domain capability should land there, not here.

What this PR does NOT do

  • No code behaviour changes — pure annotation + spec
  • Does not silently fix observed-but-suspicious behaviour:
    • `RequestDataExtractor::extractPlacementData()` type-casting asymmetry vs `extractTileData()` — documented in spec Notes
    • `UserAttributeResolver::evaluateOperator()` silent-false on unknown operators — documented (future-tightening TODO)
    • `SlugGenerator::slugify('')` empty-string return — documented as intentional (callers substitute UUID)

Review focus

  • REQ language matches observed behaviour (not aspirational)
  • Scenarios are testable
  • Capability scope is well-defined enough to prevent drift
  • New capability genuinely earns its slot (not just a dumping ground)

Source: `openspec/coverage-report.md` generated 2026-05-24
Cluster: infrastructure-helpers (Bucket 2b)
Refs #292

New capability covers three cross-cutting helper classes that
were flagged Bucket 2b (no owning capability) by the 2026-05-24
coverage scan:

- SlugGenerator (2 methods) — URL-safe slug grammar + transform
  pipeline + validation
- UserAttributeResolver (2 methods) — Nextcloud user attribute
  lookup + 5 string-comparison operators
- RequestDataExtractor (2 methods) — tile + placement form data
  extraction from IRequest

Per the SKILL's bias-toward-extend rule, considered extending
dashboards / conditional-visibility / tiles+widgets — but the
helpers' shared shape (stateless, no persistence, reusable across
capabilities) is itself the spec, so a thin new capability with a
clear Scope section keeps each owning capability focused on
domain behaviour.

Ghost change: archive/2026-05-24-retrofit-infrastructure-helpers.

Refs #292
@rubenvdlinde rubenvdlinde added openspec OpenSpec-driven change yolo Auto-merge when all phases pass retrofit labels May 24, 2026
@rubenvdlinde rubenvdlinde requested a review from Rem-Dam as a code owner May 24, 2026 18:21
@github-actions
Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/mydash @ 605274c

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
composer
npm ✅ 436/436
PHPUnit ⏭️
Newman ⏭️
Playwright ⏭️

Quality workflow — 2026-05-24 18:23 UTC

Download the full PDF report from the workflow artifacts.

@rubenvdlinde rubenvdlinde merged commit dc89341 into development May 25, 2026
13 of 25 checks passed
@rubenvdlinde rubenvdlinde deleted the retrofit/reverse-spec-mydash-infrastructure-helpers-2026-05-24 branch May 25, 2026 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

openspec OpenSpec-driven change retrofit reverse-spec yolo Auto-merge when all phases pass

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant