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
16 changes: 12 additions & 4 deletions .github/workflows/nestia.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,18 @@ jobs:
name: ttsc-tarballs
path: experimental/tarballs

- name: Clone nestia
run: |
rm -rf experimental/nestia
git clone --depth=1 --branch master https://github.com/samchon/nestia experimental/nestia
# Keep this integration gate attributable to ttsc. nestia master became
# red in its own sdk lane after this revision (PR #1594, openapi_v2), so a
# moving clone made every ttsc change inherit an unrelated upstream
# failure. Advance the pin only to a revision with a reviewed green full
# suite; 3b27e69b is the merge of nestia #1593 and its complete test run
# 29959327169 passed.
- name: Check out verified nestia integration revision
uses: actions/checkout@v4
with:
repository: samchon/nestia
ref: 3b27e69b69dea3f102315042dce87c18d81be74a
path: experimental/nestia

- name: Use local ttsc tarballs
working-directory: experimental/nestia
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ permissions:
jobs:
publish:
runs-on: ubuntu-latest
# One full build-plus-publish cycle takes ~35 minutes end to end.
timeout-minutes: 60
steps:
# `pnpm run build` cross-compiles every platform package in one job: seven
# GOOS/GOARCH pairs, each producing a tsgo-sized ttsc and ttscserver, each
Expand Down Expand Up @@ -78,13 +80,23 @@ jobs:
! printf '%s\n%s\n' "$ttsc_out" "$server_out" | grep -q '0.0.0-dev'
! printf '%s\n%s\n' "$ttsc_out" "$server_out" | grep -q 'commit dev'
- name: Publish VS Code Marketplace extension
# Fail fast on a stalled Marketplace call: the healthy step takes
# under a minute (11-28 s observed), and the default 360-minute job
# timeout would otherwise hold the npm publish hostage for hours
# while looking like a slow build (#1008).
timeout-minutes: 10
run: SKIP_BUILD=1 bash scripts/publish-vscode-marketplace.sh
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
- name: Publish to npm
# Same fail-fast contract as the Marketplace step: the healthy step
# takes ~5.5 minutes; the default 360-minute job timeout would hold a
# stalled publish silently for hours (#1008).
timeout-minutes: 20
run: pnpm run package:latest:publish
wasm-smoke:
runs-on: ubuntu-latest
timeout-minutes: 15
needs: publish
steps:
- uses: actions/setup-node@v6
Expand All @@ -102,6 +114,7 @@ jobs:
node -e "if(!require('@ttsc/wasm'))process.exit(1)"
vscode-smoke:
runs-on: ubuntu-latest
timeout-minutes: 15
needs: publish
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -146,6 +159,7 @@ jobs:
NODE
release:
runs-on: ubuntu-latest
timeout-minutes: 15
needs: [wasm-smoke, vscode-smoke]
permissions:
contents: write
Expand Down
7 changes: 5 additions & 2 deletions experimental/unplugin-perf/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,15 @@
This experiment drives the **real** `@ttsc/unplugin` Rollup plugin object over a synthetic project of `N` TypeScript files and measures, per simulated build:

- **plugin runs** — how many times the whole project is re-transformed (native plugin spawns). A correct per-build cache transforms the project **once**.
- **`fs.readFileSync` calls / bytes** — the file-system work the adapter performs while serving the `N` modules. A correct cache walks the tree a constant number of times; the current code re-hashes the entire project on every module.
- **`fs.readFileSync` calls / bytes** — the file-system work the adapter performs while serving the `N` modules. A correct cache walks the tree a constant number of times per build.
- **fs identity probes** — the `existsSync`/`realpathSync.native` call volume the macOS `pathIdentityKey` branch would pay, counted under a simulated `process.platform = "darwin"` so it is observable on any host. Correct watch-input derivation pays it once per distinct graph path per generation, not once per module delivery.

The guarded invariant is **`plugin runs == 1`**: a build must transform the whole project exactly once and serve every other module from the per-build cache. The harness exits non-zero if any build exceeds one transform.
The guarded invariants are **`plugin runs == 1`** and, for the graph scenario, **bounded probes per module** — the harness exits non-zero when either breaks.

- **Scenario A — output keys under the project root.** The cache hits, so the project is transformed once. (`reads` still grow with `N`: validating a cache hit re-hashes the project to detect a sibling-file change — bounded work that the existing invalidation contract requires.)
- **Scenario B — one output key outside the validator's directory walk** (a `node_modules/**` path, exactly what the native host emits for program dependencies). Before the fix the store-time and validate-time hash key sets diverged, the cache _never_ hit, and the whole project was re-transformed once per module (`plugin runs == N`); now the cache hits and `plugin runs == 1`.
- **Scenario C — a graph-bearing envelope (the typia >= 13.1.19 shape).** The sidecar stamps `graph` (every module edges to its next sibling plus `K` external `node_modules` declarations, and one missing resolution candidate) and per-file `dependencies`. Before the #1007 fix every cache-hit delivery re-walked the whole graph: probes per module grew linearly with the edge count (6.7k/12k/22.8k probes per module at E=2.6k/5.1k/10.1k, ~76-95 s for 99 deliveries), the O(modules x edges) syscall storm behind the #970 residual stall on macOS. The gate is 64 probes per module; the fixed code derives once per generation and stays flat regardless of `E`.
- **Scenario D — the same envelope without a build boundary** (the Vite development server's persistent-validation mode). Measurement only: it quantifies the deliberate per-delivery complete-input validation against a large external input set. The path is linear and is the #980 freshness contract, so no invariant gate applies.

The adapter source is bundled on the fly with esbuild (with `ttsc` and `unplugin` kept external), so the production code path runs unmodified — no rebuilt `lib` required.

Expand Down
Loading
Loading