Skip to content

Upgrade sc-just to use sc-compose reporting runtime #95

Description

@randlee

Summary

Upgrade the canonical sc-just package at packages/sc-just so it becomes the recommended just integration layer for the Phase B reporting/runtime system in sc-compose.

sc-compose should own the reporting engine and CLI/runtime commands. sc-just should own the recommended Justfile surface, bootstrap flow, and scaffold layout that call into sc-compose.

Canonical Split

sc-compose owns

  • report catalog loading and validation
  • source collection and render-many
  • shared template-family resolution
  • latest/archive output handling
  • report verification and index/summary commands
  • publish-manifest generation
  • typed diagram-spec support

sc-just owns

  • recommended Justfile recipe surface
  • recipe scaffolding and bootstrap flow
  • repo-facing command layout
  • standard TODO markers showing what the consumer repo must fill in

consumer repos own

  • repo-specific just lint, just test, and just smoke bodies
  • repo-specific templates and source inputs
  • repo-specific wrapper/publish commands

Required Design Rule

sc-just should use sc-compose for shared reporting behavior rather than reimplementing reporting logic in shell recipes.

That means:

  • sc-just calls sc-compose commands for report catalog/runtime behavior
  • sc-just scaffolds Justfile entries that point at sc-compose
  • consumer repos fill in producer-specific command bodies where needed

Recommended Recipe Surface

lint:
	@echo "repo-owned lint producer"

test:
	@echo "repo-owned test producer"

smoke:
	@echo "repo-owned smoke producer"

reports:
	sc-compose reports index --catalog reports/catalog/reports.toml

reports-verify:
	sc-compose reports verify --catalog reports/catalog/reports.toml

Optional repo-local helpers may exist, but they are not part of the shared contract:

  • just reports-open
  • just reports-clean
  • just reports-publish

Recommended Upgrades

1. Report Catalog Bootstrap

sc-just should scaffold:

  • reports/catalog/reports.toml
  • reports/latest/
  • reports/archive/
  • reports/templates/

The scaffold should assume sc-compose owns catalog parsing and validation.

2. Smoke Scaffold Fixtures

sc-just should generate a standard smoke scaffold shape:

  • one reference smoke template fixture
  • one sample-vars.json fixture
  • one wrapper entrypoint that the generated just smoke target invokes

This keeps the smoke contract stable across repos while still leaving the actual repo-specific smoke command body consumer-owned.

3. Ownership Markers In Scaffold Output

Generated files should mark ownership explicitly:

  • sc-compose-owned contract calls
  • sc-just-owned scaffold structure
  • consumer-owned command bodies and repo-local templates

This should be visible in generated comments or TODO markers.

4. reports And reports-verify Stubs

sc-just should scaffold the shared reporting commands as direct sc-compose invocations:

  • sc-compose reports index --catalog reports/catalog/reports.toml
  • sc-compose reports verify --catalog reports/catalog/reports.toml

The skill should not shell-duplicate catalog logic or verification semantics.

5. Backward-Compatibility Harness Hooks

sc-just should support a standard place for backward-compat checks that run through sc-compose, especially for:

  • bundled example regressions
  • migrated report-family regressions
  • stable output-path expectations

6. Edge-Case Fixture Generation

sc-just should be able to scaffold fixtures that stress the reporting pipeline:

  • nested includes
  • missing optional fields
  • extra unknown fields
  • large variable payloads
  • unusual whitespace

These belong in the scaffold because they are shared test-shape concerns, not repo-specific business logic.

7. Reference Repo Pattern

sc-compose should act as the reference repo showing how sc-just uses sc-compose commands, but sc-compose should not become a second source of truth for the skill itself.

The canonical package remains:

  • packages/sc-just

Context

This came out of the approved Phase B planning work in sc-compose, where the reporting/runtime system is being implemented in Rust and the recommended just integration pattern should live in the canonical sc-just package.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions