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
56 changes: 54 additions & 2 deletions .github/workflows/attach-release-vsix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,53 @@ jobs:
with:
release-tag: ${{ inputs.tag }}

attach:
qualify:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- run: npm ci
- run: node --test scripts/verify-release-packages.test.mjs
- uses: actions/download-artifact@v4
with:
name: ${{ needs.build.outputs.artifact-name }}
path: output
- name: Verify and unpack the exact candidate VSIX
env:
EXPECTED_SHA: ${{ needs.build.outputs.sha256 }}
run: |
set -euo pipefail
vsix=$(ls output/*.vsix)
test "$(sha256sum "$vsix" | cut -d' ' -f1)" = "$EXPECTED_SHA"
mkdir -p "$RUNNER_TEMP/draft-vsix"
unzip -q "$vsix" -d "$RUNNER_TEMP/draft-vsix"
echo "TX_E2E_EXTENSION_PATH=$RUNNER_TEMP/draft-vsix/extension" >> "$GITHUB_ENV"
echo "VSIX_SHA256=$EXPECTED_SHA" >> "$GITHUB_ENV"
echo "TX_E2E_PACKAGE_OUTPUT=$GITHUB_WORKSPACE/qualified" >> "$GITHUB_ENV"
- name: Qualify the packaged UI and retain its exact installed CLI archive
run: xvfb-run -a npm run test:e2e-extension:packaged
- name: Package the matching diagrams workspace
run: npm pack --ignore-scripts --workspace packages/diagrams --pack-destination qualified --json > qualified/diagrams-pack.json
- name: Hash qualified assets
run: |
cd qualified
sha256sum *.tgz *.json > SHA256SUMS
- name: Verify qualified identities and refusal controls
run: node scripts/verify-release-packages.mjs qualified output/*.vsix
- uses: actions/upload-artifact@v4
with:
name: qualified-release-packages
path: qualified/*
if-no-files-found: error
retention-days: 7

attach:
needs: [build, qualify]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
Expand All @@ -43,6 +87,14 @@ jobs:
name: ${{ needs.build.outputs.artifact-name }}
path: output

- uses: actions/download-artifact@v4
with:
name: qualified-release-packages
path: qualified

- name: Verify qualified package hashes
run: cd qualified && sha256sum --check SHA256SUMS

- name: Verify downloaded artifact matches the attested hash
shell: bash
run: |
Expand Down Expand Up @@ -115,7 +167,7 @@ jobs:
# host `gh api` defaults to for a bare path — `gh release upload` targets
# the correct host itself.
gh release upload "${{ inputs.tag }}" \
output/*.vsix output/*.sha256 output/sbom.xml \
output/*.vsix output/*.sha256 output/sbom.xml qualified/* \
-R ${{ github.repository }}

- name: Update release notes with attestation verification command
Expand Down
70 changes: 40 additions & 30 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,12 @@ name: npm — publish packages
on:
release:
types: [published]
workflow_dispatch: {}
workflow_dispatch:
inputs:
tag:
description: Published release tag whose verified assets will be published
required: true
type: string

permissions:
contents: read
Expand All @@ -48,9 +53,12 @@ jobs:
- name: Check npm channel selection
run: node --test scripts/npm-publish-tag.test.mjs

- name: Test exact package refusal controls
run: node --test scripts/verify-release-packages.test.mjs

- name: Check release package versions
env:
RELEASE_TAG: ${{ github.event.release.tag_name }}
RELEASE_TAG: ${{ github.event.release.tag_name || inputs.tag }}
run: node scripts/check-release-versions.mjs

publish:
Expand All @@ -76,33 +84,35 @@ jobs:
- name: Install OIDC-capable npm
run: npm install --global npm@11

- name: Install root dependencies
run: npm ci

- name: Build @transitrix/diagrams
run: npm run build --workspace packages/diagrams

# Each package selects next for a prerelease and latest for a stable version.
# Publish order matters: diagrams first, then cli (runbook convention).
- name: Publish @transitrix/diagrams (skips if version already published)
- name: Download the release-qualified package archives
env:
GH_TOKEN: ${{ github.token }}
RELEASE_TAG: ${{ github.event.release.tag_name || inputs.tag }}
run: |
LOCAL=$(node -p "require('./packages/diagrams/package.json').version")
DIST_TAG=$(node scripts/npm-publish-tag.mjs "$LOCAL")
PUBLISHED=$(npm view "@transitrix/diagrams@$LOCAL" version 2>/dev/null || echo "")
if [ "$PUBLISHED" = "$LOCAL" ]; then
echo "@transitrix/diagrams@$LOCAL is already on the registry — skipping."
else
npm publish --workspace packages/diagrams --access public --tag "$DIST_TAG"
fi

- name: Publish @transitrix/cli (skips if version already published)
set -euo pipefail
test -n "$RELEASE_TAG"
gh api "/repos/$GITHUB_REPOSITORY/releases/tags/$RELEASE_TAG" > release.json
node -e "const r=require('./release.json'); if(r.draft || r.target_commitish !== process.env.GITHUB_SHA) process.exit(1)"
mkdir qualified
gh release download "$RELEASE_TAG" -R "$GITHUB_REPOSITORY" --dir qualified \
--pattern '*.tgz' --pattern '*.vsix' --pattern 'cli-qualification.json' --pattern 'runtime-audit.json' --pattern 'SHA256SUMS'
- name: Verify exact qualified package identities
run: node scripts/verify-release-packages.mjs qualified qualified/*.vsix

# These are the exact qualified archives. Never rebuild at publication.
- name: Publish verified archives (skip only identical registry bytes)
run: |
LOCAL=$(node -p "require('./packages/cli/package.json').version")
DIST_TAG=$(node scripts/npm-publish-tag.mjs "$LOCAL")
PUBLISHED=$(npm view "@transitrix/cli@$LOCAL" version 2>/dev/null || echo "")
if [ "$PUBLISHED" = "$LOCAL" ]; then
echo "@transitrix/cli@$LOCAL is already on the registry — skipping."
else
# prepack (scripts/build-cli-package.mjs) assembles dist/ + schemas/.
npm publish --workspace packages/cli --access public --tag "$DIST_TAG"
fi
set -euo pipefail
for package in diagrams cli; do
version=$(node -p "require('./packages/$package/package.json').version")
archive="qualified/transitrix-$package-$version.tgz"
integrity=$(node -e "const fs=require('fs'),c=require('crypto');console.log('sha512-'+c.createHash('sha512').update(fs.readFileSync(process.argv[1])).digest('base64'))" "$archive")
published=$(npm view "@transitrix/$package@$version" dist.integrity 2>/dev/null || true)
if [ -n "$published" ]; then
test "$published" = "$integrity" || { echo 'Existing package integrity differs'; exit 1; }
echo "Identical @transitrix/$package@$version already published; skipping"
else
channel=$(node scripts/npm-publish-tag.mjs "$version")
npm publish "$archive" --ignore-scripts --access public --tag "$channel"
fi
done
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
# Changelog

## [3.10.0] — 2026-11-08

### Added

- Per-file relation validation with admission and quoted inclusive lifecycle dates; actor identity validation rejects inline reporting fields. (#742)

### Changed

- CLI 2.13.0 and diagrams 1.17.0 move together; requirements reports retain transport 1, projection 0.3 and the explicit 0.2 adapter.
- Updated dependencies since 3.9.0 remain subject to exact-candidate checks.

Known vocabulary limitation: the same 22 baseline drift entries (declared
methodology 3.1.0 versus vendored 3.3.0, block-grid TYPE registry and unbound
vocabulary registries) are explicitly renewed only until 2026-11-16. This
release does not claim complete Methodology 8.0.0 vocabulary conformance. New,
stale or subsequently expired exceptions still fail closed.

See [compatibility and candidate qualification](docs/releases/3.10.0-compatibility.md). No publication or installed support is claimed.

## [3.9.0] — 2026-10-25

### Added
Expand Down
6 changes: 0 additions & 6 deletions changelog/fragments/person-reporting-validation.md

This file was deleted.

6 changes: 5 additions & 1 deletion docs/internal/release-runbook.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ from CI.
| Artifact | Pipeline | Trigger |
|---|---|---|
| Universal VSIX, attached to the release + SHA-256 recorded | `.github/workflows/attach-release-vsix.yml` | Explicit `workflow_dispatch` for an existing draft tag, run against its exact target commit |
| `@transitrix/diagrams` + `@transitrix/cli` → npm | `.github/workflows/npm-publish.yml` | GitHub Release **published** (or `workflow_dispatch`) |
| `@transitrix/diagrams` + `@transitrix/cli` → npm (verified attached archives) | `.github/workflows/npm-publish.yml` | GitHub Release **published** (or `workflow_dispatch`) |
| VS Code extension → VS Code Marketplace | `.github/workflows/vscode-marketplace-publish.yml` | `workflow_dispatch` only — see that workflow's header before changing this |
| VS Code extension → Open VSX (Cursor / VSCodium / Windsurf) | `.github/workflows/openvsx-publish.yml` | GitHub Release **published** (or `workflow_dispatch`); downloads the asset `attach-release-vsix.yml` attached rather than rebuilding |
| IntelliJ plugin → JetBrains Marketplace | `.github/workflows/jetbrains-publish.yml` | GitHub Release **published** (plugin version derived from the release tag, `v` prefix stripped) |
Expand Down Expand Up @@ -165,3 +165,7 @@ npm deprecate @transitrix/diagrams@1.0.0 "Broken — use 1.0.1+"
[`openvsx-publish-runbook.md`](openvsx-publish-runbook.md) — the
marketplace-specific notes the workflows codify.
- [`docs/cli.md`](cli.md) — CLI install docs.

## Qualified package identity

The draft-attachment workflow gates attachment on packaged UI/CLI tests and a zero-vulnerability runtime audit. It retains the exact tested CLI archive; publication verifies the attached archives against source/version/hash receipts and publishes those bytes with lifecycle scripts disabled. An existing registry version is skipped only when its integrity matches. No rebuild may silently replace the qualified package. Draft creation and attachment do not publish a release.
64 changes: 64 additions & 0 deletions docs/releases/3.10.0-compatibility.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Studio 3.10.0 preparation candidate

Status: proposed source changes; no release, installation or final artifact qualification.

| Surface | Proposed version | Classification |
|---|---|---|
| Studio / extension | 3.10.0 | MINOR: newly supported relation-file validation; no command or supported report contract removed |
| CLI | 2.13.0 | MINOR: new file-validation support; bundled diagrams must move with the source |
| diagrams | 1.17.0 | MINOR: correct enforcement of the existing actor identity boundary |
| Methodology | 8.0.0 | Separate MAJOR: closed relation enum expansion and stricter adopter tooling |

## Compatibility disposition

Compare Studio v3.9.0 (`4ad085e14e7cc9c1662e55065c183e09a42f95c6`)
with the source baseline `b5651f326f59f82155eed327ecbebd80d954fecd`.
Before #742, `relation` had no file validator and was in the registered-but-
unsupported population. An unvalidated/strict-failing input is not a previously
supported clean result. Admission and quoted lifecycle date checks therefore
add support, rather than remove supported relation-file behavior. They do not
prove catalogue identity, actor subtype, cycles or reporting health.

Methodology v7.0.0 already describes ACTOR as identity-only, with engagement and
hierarchy in first-class REL records (19-actors §1/§5 and ACTOR-003).
Rejecting inline `manager` / `reports_to` corrects previously permissive tooling;
it does not remove a field admitted by that contract. Preserve authored values
for review; never infer reporting from employment or silently move data.
Free-form `extensions` stay opaque. Existing supported employment/unit_parent
forms and admission/lifecycle positives and negatives are retained by
`tests/relation-validation.test.ts`; actor tests retain the extensions control.

These MINOR classifications concern these package contracts, independently of
Methodology's closed-enum MAJOR policy. If review produces an old-contract-valid,
previously supported counterexample, revise the affected package to MAJOR with
migration guidance before merging this preparation.

## Exact caller boundary

The requirements-analysis skill must pin the final full Studio commit containing
this version change and the 2.13.0 package identity, not just a branch or version
range. `requirements-build.json` embeds the build's source revision. A candidate
receipt must also record the tarball SHA-256/npm integrity, bundled diagrams
1.17.0 and emitted tool version/source revision. No artifact hash exists in this
source-only proposal. A later merge/rebuild requires its own receipt and skill
map update; do not substitute public 2.12.1 or the old 2.12.0 candidate.

Transport stays `requirements-report/1`; projection stays `requirement-chain/0.3`
with the explicit `requirement-chain/0.2` adapter retained. Keep PRODUCT and
APPLICATION identities, project/release/as-at/source provenance, unknown totals,
exact contributing IDs and the accepted UI oracle. No Phase 2 metrics are added.

## Qualification remaining for these changed candidates

Run source version/lock guards, affected relation/actor controls and retained
requirements projection tests in the exact locked environment. Then qualify the
exact packed CLI's identity, four subject fixtures, negative controls, replay
and unchanged model bytes, and correlate the versioned VSIX's UI populations/IDs.
Reuse historical #711/#712/#742 evidence only at its recorded scope and identity;
unchanged leaf blobs alone do not qualify a rebuilt dependency environment.
This preparation does not repeat earlier machine operations or claim those checks.

JetBrains derives its version from the extension release. Obsidian 0.1.1 keeps
its independent identity. Language advisories remain opt-in/experimental.
Publishing a GitHub Release triggers npm, Open VSX and JetBrains; none is
triggered by this proposal. Microsoft Marketplace remains excluded.
5 changes: 5 additions & 0 deletions extension/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Transitrix Studio — changelog

## 3.10.0 — 2026-11-08

- Adds relation-file conformance validation and enforces the existing actor identity boundary. Reporting graph checks remain separate.
- Requirements report semantics and opt-in language advisories are retained. Exact versioned package/UI qualification is pending; no release is claimed.

## 3.9.0 — 2026-10-25

### Added
Expand Down
4 changes: 2 additions & 2 deletions extension/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion extension/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "transitrix-studio",
"displayName": "Transitrix Studio",
"publisher": "transitrix",
"version": "3.9.0",
"version": "3.10.0",
"description": "Diagrams as text: 17 YAML notations plus release-scoped requirement traceability, live in your editor. Diffable in git. AI-friendly. Open source.",
"license": "MIT",
"icon": "icon.png",
Expand Down
27 changes: 25 additions & 2 deletions extension/test-e2e/runTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,14 @@ async function main(): Promise<void> {
});
npm(['run', 'build:diagrams']);
npm(['pack', '--workspace', 'packages/cli', '--pack-destination', consumerDir, '--cache', path.join(consumerDir, 'cache'), '--json']);
const tarball = fs.readdirSync(consumerDir).find(name => name.endsWith('.tgz'));
// Lifecycle stdout may precede npm's JSON. Use the manifest-bound filename
// and hash actual archive bytes rather than parsing mixed stdout.
const tarball = `transitrix-cli-${cliVersion}.tgz`;
if (!tarball) throw new Error('CLI packaging produced no tarball');
const packagePath = path.join(consumerDir, tarball);
const packageHash = createHash('sha256').update(fs.readFileSync(packagePath)).digest('hex');
const packageBytes = fs.readFileSync(packagePath);
const packageHash = createHash('sha256').update(packageBytes).digest('hex');
const packageIntegrity = 'sha512-' + createHash('sha512').update(packageBytes).digest('base64');
npm(['install', '--prefix', consumerDir, '--ignore-scripts', '--no-audit', '--no-fund', '--cache', path.join(consumerDir, 'cache'), packagePath]);
const callerPath = path.join(consumerDir, 'node_modules', '@transitrix', 'cli', 'dist', 'cli.js');
const sourceRevision = execFileSync('git', ['rev-parse', 'HEAD'], { cwd: repoRoot, encoding: 'utf8' }).trim();
Expand Down Expand Up @@ -90,6 +94,25 @@ async function main(): Promise<void> {
if (exitCode !== 0) {
throw new Error(`extension-e2e: VS Code test host exited with code ${exitCode}`);
}
// Retain the exact installed/tested archive, never a post-test rebuild.
const packageOutput = process.env.TX_E2E_PACKAGE_OUTPUT;
if (packageOutput) {
const audit = JSON.parse(npm(['audit', '--prefix', consumerDir, '--omit=dev', '--json']));
if (audit.metadata?.vulnerabilities?.total !== 0) throw new Error('Candidate runtime audit must report zero vulnerabilities');
fs.mkdirSync(packageOutput, { recursive: true });
const target = path.join(packageOutput, tarball!);
if (fs.existsSync(target) || fs.existsSync(path.join(packageOutput, 'cli-qualification.json'))) throw new Error('Refusing to overwrite retained candidate evidence');
fs.copyFileSync(packagePath, target);
fs.writeFileSync(path.join(packageOutput, 'runtime-audit.json'), JSON.stringify(audit, null, 2) + '\n');
fs.writeFileSync(path.join(packageOutput, 'cli-qualification.json'), JSON.stringify({
schema: 'transitrix-packaged-ui-cli-qualification/1', sourceRevision,
cliVersion, diagramsVersion: JSON.parse(fs.readFileSync(path.join(repoRoot, 'packages/diagrams/package.json'), 'utf8')).version,
artifact: tarball, sha256: packageHash, integrity: packageIntegrity,
vsixSha256: process.env.VSIX_SHA256 ?? null,
reportContract: 'requirement-chain/0.3', transport: 'requirements-report/1',
exactArchiveUsedByPackagedUiTests: true, runtimeAuditVulnerabilities: 0,
}, null, 2) + '\n');
}
console.log(`extension-e2e: all tests passed. PNG captures in ${captureDir}`);
} finally {
fs.rmSync(consumerDir, { recursive: true, force: true });
Expand Down
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading