Compare commits
15
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
321e4e8411 | ||
|
|
49384163e3 | ||
|
|
d923ae04fb | ||
|
|
3e55a1c081 | ||
|
|
cf7d30d8c2 | ||
|
|
29b2fa0483 | ||
|
|
5ed24d415b | ||
|
|
9379b58dd8 | ||
|
|
c87dccedd0 | ||
|
|
fc495fa3cb | ||
|
|
1f3a42e747 | ||
|
|
d5e8c8a827 | ||
|
|
32baf0c592 | ||
|
|
4a98046da2 | ||
|
|
57c4707bc5 |
No files matched your search
+19
-14
@@ -1,23 +1,30 @@
|
|||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
# Runs on the development forge only, through the `if:` guards below. The reason they were added is
|
# Runs on BOTH forges. It used to be guarded to the development forge, because the packages built
|
||||||
# gone — the packages used to build against a core that existed on an internal registry, and now
|
# against a core that existed only on an internal registry a public runner cannot reach. They now
|
||||||
# resolve it from npmjs.org like anyone else — so lifting them is unblocked. Until that happens, the
|
# resolve `@green-tea/core` from npmjs.org, so that reason is gone and the guards are too.
|
||||||
# public mirror carries this file with every job skipped.
|
#
|
||||||
|
# `contrib` is in both lists because external pull requests target it (CONTRIBUTING.md). Leaving it
|
||||||
|
# out is not a smaller version of running CI — it is none: a pull request against a branch that is
|
||||||
|
# not listed triggers nothing at all, so a contributor gets no signal and neither does whoever
|
||||||
|
# merges it.
|
||||||
|
#
|
||||||
|
# GitHub does not run workflows on pull requests from forks until a maintainer approves them, so a
|
||||||
|
# contributor's first push may sit with no checks for a while. That is not a rejection.
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [develop, main]
|
branches: [develop, main, contrib]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [develop, main]
|
branches: [develop, main, contrib]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
# Its own job so a missing sign-off reports on its own and costs nothing on push. Checks that the
|
# Its own job so a missing sign-off reports on its own and costs nothing on push. Checks that the
|
||||||
# trailer is present, not that it matches the author.
|
# trailer is present, not that it matches the author.
|
||||||
dco:
|
dco:
|
||||||
if: github.event_name == 'pull_request' && github.server_url != 'https://github.com'
|
if: github.event_name == 'pull_request'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- name: Every commit needs a Signed-off-by
|
- name: Every commit needs a Signed-off-by
|
||||||
@@ -39,11 +46,10 @@ jobs:
|
|||||||
|
|
||||||
# Node 22 is the lowest `engines.node` any package declares (spec 2.5: build on the floor).
|
# Node 22 is the lowest `engines.node` any package declares (spec 2.5: build on the floor).
|
||||||
build:
|
build:
|
||||||
if: github.server_url != 'https://github.com'
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: '22'
|
node-version: '22'
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
@@ -59,15 +65,14 @@ jobs:
|
|||||||
# A fixed matrix, not `fromJSON`: Gitea Actions support for a dynamic matrix was not verified. Each
|
# A fixed matrix, not `fromJSON`: Gitea Actions support for a dynamic matrix was not verified. Each
|
||||||
# entry runs only the packages whose engines name that runtime (scripts/run-runtime.mjs).
|
# entry runs only the packages whose engines name that runtime (scripts/run-runtime.mjs).
|
||||||
runtimes:
|
runtimes:
|
||||||
if: github.server_url != 'https://github.com'
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
runtime: [deno, bun, edge]
|
runtime: [deno, bun, edge]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v5
|
||||||
with:
|
with:
|
||||||
node-version: '22'
|
node-version: '22'
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ jobs:
|
|||||||
if: ${{ github.server_url != 'https://github.com' }}
|
if: ${{ github.server_url != 'https://github.com' }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v5
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0 # full history for a clean push
|
fetch-depth: 0 # full history for a clean push
|
||||||
- name: Push to GitHub
|
- name: Push to GitHub
|
||||||
|
|||||||
@@ -0,0 +1,98 @@
|
|||||||
|
name: Release → JSR
|
||||||
|
|
||||||
|
# Publishes the workspace to JSR. Runs on GITHUB ONLY, on a `release-*` tag.
|
||||||
|
#
|
||||||
|
# **The tag is a date, not a version.** `release-26.9.23` says when, and the release body says what
|
||||||
|
# moved. A version-shaped tag would be a lie here: three packages carry three independent versions,
|
||||||
|
# so `plugins-v26.9.0` would match none of them and invite exactly the confusion of reading it as
|
||||||
|
# `@green-tea/jwt@26.9.0`.
|
||||||
|
#
|
||||||
|
# Tag-driven rather than push-driven, unlike the example JSR's own setup page offers. That example
|
||||||
|
# publishes on every push to `main`, which for this repository means every promotion publishes — and
|
||||||
|
# a JSR version can never be replaced or removed, so a distracted merge would burn a version number
|
||||||
|
# forever. A tag is a decision; a merge is not.
|
||||||
|
#
|
||||||
|
# Publishing all three at once is safe, and this is the fact the whole design rests on: `deno publish`
|
||||||
|
# queries the registry per package and drops the ones already there, logging
|
||||||
|
# `Warning: Skipping, already published` for each. If every version is already published it prints
|
||||||
|
# `Success: All packages are already published` and exits 0. So a tag cut after changing one package
|
||||||
|
# publishes that one and leaves the others alone, with no per-package logic here.
|
||||||
|
# (denoland/deno, cli/tools/publish/mod.rs — `filter_out_published_packages`.)
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags: ['release-*']
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish:
|
||||||
|
if: ${{ github.server_url == 'https://github.com' }}
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
id-token: write # OIDC — this is what publishes, and what earns provenance
|
||||||
|
contents: write # create the GitHub release for this tag
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v5
|
||||||
|
- uses: actions/setup-node@v5
|
||||||
|
with:
|
||||||
|
node-version: '22'
|
||||||
|
- uses: denoland/setup-deno@v2
|
||||||
|
with:
|
||||||
|
deno-version: v2.x
|
||||||
|
# Both runtimes, because the gates below run both suites. `ci.yml` installs these one per
|
||||||
|
# matrix entry; here every suite runs in the same job, so both have to be present. Leaving
|
||||||
|
# bun out does not skip its suite — `scripts/run-runtime.mjs` spawns `bun`, gets ENOENT, and
|
||||||
|
# `process.exit(status ?? 1)` turns that into a failure that aborts the release.
|
||||||
|
- uses: oven-sh/setup-bun@v2
|
||||||
|
- run: npm ci
|
||||||
|
|
||||||
|
# The same gates CI runs. They ran on `main` already, and they run again here because this is
|
||||||
|
# the last moment they can still change the outcome: after the publish there is no amending a
|
||||||
|
# version, only publishing another one.
|
||||||
|
- run: npm run lint
|
||||||
|
- run: npm run format:check
|
||||||
|
- run: npm run typecheck
|
||||||
|
- run: npm run complexity:check
|
||||||
|
- run: npm test
|
||||||
|
- run: npm run test:deno
|
||||||
|
- run: npm run test:bun
|
||||||
|
- run: npm run test:edge
|
||||||
|
|
||||||
|
# Before the publish, on purpose. This reports which versions the tag would ship and refuses
|
||||||
|
# when one has no CHANGELOG entry — a package whose own changelog says it was never released
|
||||||
|
# is not something to discover afterwards, because afterwards is permanent.
|
||||||
|
- name: Every version about to ship has a changelog entry
|
||||||
|
run: node scripts/release.mjs --check
|
||||||
|
|
||||||
|
# JSR checks things no other gate does — slow types, module analysis — and learning about them
|
||||||
|
# mid-publish leaves a tag half-shipped.
|
||||||
|
- run: deno publish --dry-run
|
||||||
|
|
||||||
|
# No token: OIDC exchanges the workflow's id-token, which is also what attaches provenance.
|
||||||
|
# `tee` because the release body is built from what this actually did rather than from a guess
|
||||||
|
# about what it would do.
|
||||||
|
#
|
||||||
|
# Two details in this one line, both of which produce a *silently wrong* release when missed:
|
||||||
|
#
|
||||||
|
# `shell: bash` — the default shell here is `bash -e`, without `pipefail`, so a pipeline
|
||||||
|
# reports the exit status of its LAST command. That is `tee`, which always
|
||||||
|
# succeeds. A failed publish would have been reported as a green step, and
|
||||||
|
# a GitHub release created for it. Naming the shell gets `-eo pipefail`.
|
||||||
|
#
|
||||||
|
# `2>&1` — deno's logger is env_logger, whose default target is stderr, so every
|
||||||
|
# "Successfully published" line goes there. Measured: a publish writes 0
|
||||||
|
# lines to stdout and all of them to stderr. Without this the log is empty
|
||||||
|
# and the release notes say nothing shipped while three packages did.
|
||||||
|
- name: Publish
|
||||||
|
shell: bash
|
||||||
|
run: deno publish 2>&1 | tee /tmp/publish.log
|
||||||
|
|
||||||
|
- name: Release notes
|
||||||
|
run: node scripts/release.mjs --notes /tmp/publish.log "$GITHUB_REF_NAME" > /tmp/notes.md
|
||||||
|
|
||||||
|
- name: GitHub release
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ github.token }}
|
||||||
|
run: |
|
||||||
|
gh release create "$GITHUB_REF_NAME" \
|
||||||
|
--title "$GITHUB_REF_NAME" \
|
||||||
|
--notes-file /tmp/notes.md \
|
||||||
|
--prerelease
|
||||||
@@ -54,11 +54,19 @@ mirror push refuse.
|
|||||||
removed, so promoting a tag has to stay a deliberate act rather than a side effect of promoting a
|
removed, so promoting a tag has to stay a deliberate act rather than a side effect of promoting a
|
||||||
branch.
|
branch.
|
||||||
|
|
||||||
CI itself still runs on the development forge only, through the `if:` guards in `ci.yml` — but the
|
**CI runs on both forges, and `contrib` is one of the branches it watches.** It used to be guarded
|
||||||
reason is gone: the packages used to build against a core that existed on an internal registry
|
to the development forge, because the packages built against a core that existed only on an
|
||||||
alone, and since 2026-09-22 they resolve `@green-tea/core` from npmjs.org like anyone else.
|
internal registry a public runner cannot reach; they resolve `@green-tea/core` from npmjs.org now,
|
||||||
Removing those guards is unblocked rather than done, and until it happens the mirrored repository
|
so the guards are gone.
|
||||||
carries workflows that skip every job.
|
|
||||||
|
Adding `contrib` to the mirror without adding it to `ci.yml` would have been worse than not having
|
||||||
|
the branch. A pull request against a branch a workflow does not list triggers **nothing** — not a
|
||||||
|
reduced set of checks, none — so a contributor would see no signal and neither would whoever merged
|
||||||
|
it. The two changes belong together.
|
||||||
|
|
||||||
|
GitHub does not run workflows on pull requests from forks until a maintainer approves them, so a
|
||||||
|
contributor's first push may sit with no checks for a while. That is not a rejection, and it is
|
||||||
|
worth saying so rather than letting silence read as one.
|
||||||
|
|
||||||
## The plugin convention
|
## The plugin convention
|
||||||
|
|
||||||
|
|||||||
@@ -35,11 +35,12 @@ That works under every package manager: `jsr add` writes one line to `.npmrc` an
|
|||||||
|
|
||||||
Plugins import core as types only, and a type import leaves nothing behind when it compiles — the
|
Plugins import core as types only, and a type import leaves nothing behind when it compiles — the
|
||||||
JavaScript JSR publishes never mentions core. So the core that runs is always your application's,
|
JavaScript JSR publishes never mentions core. So the core that runs is always your application's,
|
||||||
whatever version a plugin was written against, and nothing warns about a version range, which under
|
whatever version a plugin was written against.
|
||||||
CalVer no range can express.
|
|
||||||
|
|
||||||
That is about *loading*, not about disk. A plugin names an exact core in its `deno.json`, and when
|
The types still come from somewhere, so each plugin's `deno.json` names a core **range**,
|
||||||
your version differs by more than the patch, npm places a second copy under the plugin rather than
|
`^26.11.0-rc.2`: the version its tests run against, up to the next year. After core's first stable
|
||||||
deduplicating. Measured, on purpose: it is inert, because nothing ever imports it. What it can do
|
release only the first release of a year may break, so that range is exactly the set of cores a
|
||||||
is make `tsc` resolve a plugin's `Plugin` type against that copy instead of yours, which fails
|
plugin stays compatible with, and your application's core satisfies it without a second copy. A
|
||||||
loudly at compile time rather than quietly at runtime.
|
plugin published before this named an exact core, and an application on a newer one could get a
|
||||||
|
second, older copy under the plugin. It was inert at runtime, but `tsc` could resolve the plugin's
|
||||||
|
`Plugin` type against it and fail at compile time.
|
||||||
Generated
+97
-83
@@ -611,16 +611,16 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@green-tea/core": {
|
"node_modules/@green-tea/core": {
|
||||||
"version": "26.9.0-beta.2",
|
"version": "26.11.0-rc.2",
|
||||||
"resolved": "https://registry.npmjs.org/@green-tea/core/-/core-26.9.0-beta.2.tgz",
|
"resolved": "https://registry.npmjs.org/@green-tea/core/-/core-26.11.0-rc.2.tgz",
|
||||||
"integrity": "sha512-HM8FdRgJz5CUiXqQUEa7vA3C+MLm/xe1Gq+5Unzg/3U6pPxqLedac+kUNcokeuwCNU5UE6bqtraTuHMua+xZ7Q==",
|
"integrity": "sha512-fvpJsK67vRQZ/TidhNclMO8KUXeSxZIbGq6lHHP2fRQVGh5ys8iOzcKE8sXTucUjV00dTe+VjNnWq2BTpndXig==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"reflect-metadata": "0.2.2"
|
"reflect-metadata": "0.2.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=18"
|
"node": ">=22"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"busboy": "^1.6.0",
|
"busboy": "^1.6.0",
|
||||||
@@ -731,6 +731,13 @@
|
|||||||
"node": ">=12"
|
"node": ">=12"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@isaacs/nonrecursive-glob-match": {
|
||||||
|
"version": "1.1.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/@isaacs/nonrecursive-glob-match/-/nonrecursive-glob-match-1.1.0.tgz",
|
||||||
|
"integrity": "sha512-GPm/Dbvk5RLmhRnxXIa7nTpK0xtl4E0wj0MslsuNiJ1FIROU+2+9lgUC/dgF7Ey4QCWhfEsgxilMRMCdHPfDfw==",
|
||||||
|
"dev": true,
|
||||||
|
"license": "BlueOak-1.0.0"
|
||||||
|
},
|
||||||
"node_modules/@one-ini/wasm": {
|
"node_modules/@one-ini/wasm": {
|
||||||
"version": "0.1.1",
|
"version": "0.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/@one-ini/wasm/-/wasm-0.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/@one-ini/wasm/-/wasm-0.1.1.tgz",
|
||||||
@@ -795,17 +802,17 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/eslint-plugin": {
|
"node_modules/@typescript-eslint/eslint-plugin": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.74.0.tgz",
|
||||||
"integrity": "sha512-nDNrUQ/4ruSNYbu749TRY7cfrzPtoLHEXSNBI8aaNY32LlZCajixqRf3FqcKC4p5Cam4VOHYx/t+i5+nKXvrqA==",
|
"integrity": "sha512-z3KXk1+Vm+d82ZRplOoC89ho4Rf1da5ju6sx8//92GnN532U62DGPjECXkkVqtYzIv0zoJlpO39SX2Z9tk6LVw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@eslint-community/regexpp": "^4.12.2",
|
"@eslint-community/regexpp": "^4.12.2",
|
||||||
"@typescript-eslint/scope-manager": "8.70.1",
|
"@typescript-eslint/scope-manager": "8.74.0",
|
||||||
"@typescript-eslint/type-utils": "8.70.1",
|
"@typescript-eslint/type-utils": "8.74.0",
|
||||||
"@typescript-eslint/utils": "8.70.1",
|
"@typescript-eslint/utils": "8.74.0",
|
||||||
"@typescript-eslint/visitor-keys": "8.70.1",
|
"@typescript-eslint/visitor-keys": "8.74.0",
|
||||||
"ignore": "^7.0.5",
|
"ignore": "^7.0.5",
|
||||||
"natural-compare": "^1.4.0",
|
"natural-compare": "^1.4.0",
|
||||||
"ts-api-utils": "^2.5.0"
|
"ts-api-utils": "^2.5.0"
|
||||||
@@ -818,15 +825,15 @@
|
|||||||
"url": "https://opencollective.com/typescript-eslint"
|
"url": "https://opencollective.com/typescript-eslint"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@typescript-eslint/parser": "^8.70.1",
|
"@typescript-eslint/parser": "^8.74.0",
|
||||||
"eslint": "^8.57.0 || ^9.0.0 || ^10.0.0",
|
"eslint": "^8.57.0 || ^9.0.0 || ^10.0.0",
|
||||||
"typescript": ">=4.8.4 <6.1.0"
|
"typescript": ">=4.8.4 <6.1.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore": {
|
"node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore": {
|
||||||
"version": "7.0.10",
|
"version": "7.0.16",
|
||||||
"resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.10.tgz",
|
"resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.16.tgz",
|
||||||
"integrity": "sha512-HpbUakT7xp5miBUywCHf36ZEuAJNklBJDDsGpUIjMzOSmM8ELSfA9Sa/QDPeNeqeoN31u+UTCkL4klCOVvRm4Q==",
|
"integrity": "sha512-52N+Y4HRMOJmbLmr+DqO4iSRyyB7N52gm7PWCT6h0p978+oKbqHCB7gIJIwZvBUsjlSdWbrBFqUSmIFNZMpn0A==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -834,16 +841,16 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/parser": {
|
"node_modules/@typescript-eslint/parser": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.74.0.tgz",
|
||||||
"integrity": "sha512-nO974WLllwhSFWQXnMLj6nDGa8f0khKEz1JzpPJ1u7Vm/4X1X6ZHajpoknU4bb41vJyMB0HHVyS2GqdhWfIXZw==",
|
"integrity": "sha512-ecr8AYdig7avVkxaHdQvxHnIJ/mOyliO4Gv/uWF8q69vBew/z3sexqBwHUZX5Vql+Ns0w4sH6gBLkICGbOvJkA==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/scope-manager": "8.70.1",
|
"@typescript-eslint/scope-manager": "8.74.0",
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"@typescript-eslint/typescript-estree": "8.70.1",
|
"@typescript-eslint/typescript-estree": "8.74.0",
|
||||||
"@typescript-eslint/visitor-keys": "8.70.1",
|
"@typescript-eslint/visitor-keys": "8.74.0",
|
||||||
"debug": "^4.4.3"
|
"debug": "^4.4.3"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -859,14 +866,14 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/project-service": {
|
"node_modules/@typescript-eslint/project-service": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.74.0.tgz",
|
||||||
"integrity": "sha512-62xOgboPfwc3/IgPSX/W6oQR3ZbF04194FPGUGH8HL8iLFHbt/456/8Ph1wLNUgVF+s94FlHoipBsz+v7+LMnA==",
|
"integrity": "sha512-z/mymuE+JlEeSFIv3Mo70EvgG1Zz74Hl0IDfExfXutARAP834bt+MppTD7mVAwmZO0GdxdOAi0jbTam749eH6g==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/tsconfig-utils": "^8.70.1",
|
"@typescript-eslint/tsconfig-utils": "^8.74.0",
|
||||||
"@typescript-eslint/types": "^8.70.1",
|
"@typescript-eslint/types": "^8.74.0",
|
||||||
"debug": "^4.4.3"
|
"debug": "^4.4.3"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -881,14 +888,14 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/scope-manager": {
|
"node_modules/@typescript-eslint/scope-manager": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.74.0.tgz",
|
||||||
"integrity": "sha512-Pa0EeSeAusQc1WbjQMac+YfenewYTBu0KjgYvkUKwhXaHUKbFog23Dm/rp0DX/6tyYOQ3Xl1a+3EcFNZynGHCw==",
|
"integrity": "sha512-kpOdpu4CpWN5U38ox3f727DwWRBtUAVhyUJtqTBYe5gf2wYoxac7PgKP14txrxN7ICVtcjlLdzjqfRgpSnDKvQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"@typescript-eslint/visitor-keys": "8.70.1"
|
"@typescript-eslint/visitor-keys": "8.74.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
||||||
@@ -899,9 +906,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/tsconfig-utils": {
|
"node_modules/@typescript-eslint/tsconfig-utils": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.74.0.tgz",
|
||||||
"integrity": "sha512-jumze1fPI+sDOaM2TWGQdn39PDxTr7TZGeuyLkAbNyx2vtMT3uRnVKChN0hfht5V2TugphJzF6bYXvBcE09qqg==",
|
"integrity": "sha512-p07wAuaS6BjCYgOSXKJi4YhvTnAf7fiG37e9THcpnYaQEt2QiTTYZWKwUFNgeRiywiMudazhzgddAirZ0GgHtQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -916,15 +923,15 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/type-utils": {
|
"node_modules/@typescript-eslint/type-utils": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.74.0.tgz",
|
||||||
"integrity": "sha512-7zKTnyvaVWqzLZHPFQtX1hVHqgkMC+WebPWakNCSyrQVbIP1AM0L0TlBZtACldIRb6PptI8Odk+jyZ5kP3B1VA==",
|
"integrity": "sha512-CV3Y3la8l3F9ANfxcfpgSSiQgJTe4IeLEoZV4O/gcW86Ugp8X6SKiQ0vm+QegXaRIbbDMokZZSF3A1CgiU/kPw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"@typescript-eslint/typescript-estree": "8.70.1",
|
"@typescript-eslint/typescript-estree": "8.74.0",
|
||||||
"@typescript-eslint/utils": "8.70.1",
|
"@typescript-eslint/utils": "8.74.0",
|
||||||
"debug": "^4.4.3",
|
"debug": "^4.4.3",
|
||||||
"ts-api-utils": "^2.5.0"
|
"ts-api-utils": "^2.5.0"
|
||||||
},
|
},
|
||||||
@@ -941,9 +948,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/types": {
|
"node_modules/@typescript-eslint/types": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.74.0.tgz",
|
||||||
"integrity": "sha512-Dm1ypdhhrGCTyyehxElhgJ6kgk8MVCv5qXdoOVqPr1uqk42jX8KjrZqhROvdShczA8qrDoYiOWn1ykWlx2k81Q==",
|
"integrity": "sha512-MpnMrJCVNpP1iVL8NiHkQZgQqIMBH5ewDGUPBh1pqQXwFtMFjsl1M03QcYPXmv6stCKEiF0PN7CGbU1ZbXFzEA==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -955,18 +962,18 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/typescript-estree": {
|
"node_modules/@typescript-eslint/typescript-estree": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.74.0.tgz",
|
||||||
"integrity": "sha512-TU8PwyGN0PQJUcE96mw8eCQ44SmxGdQlJmlWakHaHQ15eIuuvye5yNtmh/i6oS88jzXVQB71xdNkbkB/fMwL0g==",
|
"integrity": "sha512-wL348k6l92DNG+kPP5rVpKwNBoz7a3xRZy3TPKc1uymQttd7u7gcMv3eENmcuh4CjC4mO3FTM0DYstFXMyDLuw==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/project-service": "8.70.1",
|
"@typescript-eslint/project-service": "8.74.0",
|
||||||
"@typescript-eslint/tsconfig-utils": "8.70.1",
|
"@typescript-eslint/tsconfig-utils": "8.74.0",
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"@typescript-eslint/visitor-keys": "8.70.1",
|
"@typescript-eslint/visitor-keys": "8.74.0",
|
||||||
"debug": "^4.4.3",
|
"debug": "^4.4.3",
|
||||||
"minimatch": "^10.2.2",
|
"minimatch": "^11.0.1",
|
||||||
"semver": "^7.7.3",
|
"semver": "^7.7.3",
|
||||||
"tinyglobby": "^0.2.15",
|
"tinyglobby": "^0.2.15",
|
||||||
"ts-api-utils": "^2.5.0"
|
"ts-api-utils": "^2.5.0"
|
||||||
@@ -979,7 +986,13 @@
|
|||||||
"url": "https://opencollective.com/typescript-eslint"
|
"url": "https://opencollective.com/typescript-eslint"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
|
"@typescript/native": "npm:typescript@>=7.1.0-dev.20261009.1 || >=7.1.0-beta <7.1.0-dev",
|
||||||
"typescript": ">=4.8.4 <6.1.0"
|
"typescript": ">=4.8.4 <6.1.0"
|
||||||
|
},
|
||||||
|
"peerDependenciesMeta": {
|
||||||
|
"@typescript/native": {
|
||||||
|
"optional": true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/typescript-estree/node_modules/balanced-match": {
|
"node_modules/@typescript-eslint/typescript-estree/node_modules/balanced-match": {
|
||||||
@@ -993,9 +1006,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/typescript-estree/node_modules/brace-expansion": {
|
"node_modules/@typescript-eslint/typescript-estree/node_modules/brace-expansion": {
|
||||||
"version": "5.0.12",
|
"version": "5.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.12.tgz",
|
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.1.0.tgz",
|
||||||
"integrity": "sha512-YovQ3rzhaLMIrDjNDMkNS01tea93qhEhG5xy8f6+R0l+dw3Ki+5sCoIoI942iuLZTHWogWktgwVDhU09iNEimQ==",
|
"integrity": "sha512-aa11Dv491GKnYqxaul3aRJ0szew7yMJMfZPnqD44NjGrZXoj62l41OEDDpdpC4eE2P88vBFfLuSyRhpG91NUvg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
@@ -1006,32 +1019,33 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch": {
|
"node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch": {
|
||||||
"version": "10.2.6",
|
"version": "11.0.9",
|
||||||
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.6.tgz",
|
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-11.0.9.tgz",
|
||||||
"integrity": "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A==",
|
"integrity": "sha512-KCFkfyjqerNlSstjlhIGNXIKZGA/6O4V4RlhZ+Dsr621SPPw0mzlypE9D9ZOoPiVefHID+j7/XuMMlqfD/F60Q==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "BlueOak-1.0.0",
|
"license": "BlueOak-1.0.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"brace-expansion": "^5.0.8"
|
"@isaacs/nonrecursive-glob-match": "^1.1.0",
|
||||||
|
"brace-expansion": "^5.0.12"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "18 || 20 || >=22"
|
"node": "20 || >=22"
|
||||||
},
|
},
|
||||||
"funding": {
|
"funding": {
|
||||||
"url": "https://github.com/sponsors/isaacs"
|
"url": "https://github.com/sponsors/isaacs"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/utils": {
|
"node_modules/@typescript-eslint/utils": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.74.0.tgz",
|
||||||
"integrity": "sha512-Esgul8MsnKnRLdYU2Eb2cRV9bS5HJYtKj1ByJnOzzG2M58DGdSUQ1jUuILxipqcpB2h9WLrbD5GijIWUjX/Tqw==",
|
"integrity": "sha512-IpWXPxXXomzxyTcvjhZJexgdvtTR1TooLAPpuxzaGqQ8BHll1lf4Ysp/BTE/l0U5TJ+x1j7B4bEM8pLRrvY+XA==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@eslint-community/eslint-utils": "^4.9.1",
|
"@eslint-community/eslint-utils": "^4.9.1",
|
||||||
"@typescript-eslint/scope-manager": "8.70.1",
|
"@typescript-eslint/scope-manager": "8.74.0",
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"@typescript-eslint/typescript-estree": "8.70.1"
|
"@typescript-eslint/typescript-estree": "8.74.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
||||||
@@ -1046,13 +1060,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typescript-eslint/visitor-keys": {
|
"node_modules/@typescript-eslint/visitor-keys": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.74.0.tgz",
|
||||||
"integrity": "sha512-Vwj9lUIW5Xq3wQ9w6gv3R86g1hMK8f2zNOdGTAgeXUMMXFK78G9ruCjjqutHMNJc0+CH7LYRnHeUB9IT8wFmcw==",
|
"integrity": "sha512-XSZmOtMUbWCBIM+2BK134FyMFxmll1mW2mPLk/PSwYQYzGIPMgJAqL929U4qXVizLv7Xq5b7r41/o7Ombuwk0g==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/types": "8.70.1",
|
"@typescript-eslint/types": "8.74.0",
|
||||||
"eslint-visitor-keys": "^5.0.0"
|
"eslint-visitor-keys": "^5.0.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
@@ -2725,16 +2739,16 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/typescript-eslint": {
|
"node_modules/typescript-eslint": {
|
||||||
"version": "8.70.1",
|
"version": "8.74.0",
|
||||||
"resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.70.1.tgz",
|
"resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.74.0.tgz",
|
||||||
"integrity": "sha512-AcWG7KDjZ2THNXsgwttMaGmzVi0VFRlFYfqFHYQRbDpF3owuYbuiL8c7UUrd2k8s3PoSfIQrWfrGXfcElrWLYA==",
|
"integrity": "sha512-OsWQlsedt1ZpZXfZZMNK3m4SoQONFFcy4h/uRznsCeRfVuEic3gh4KGUs2pJJ5o0Jj0Jr7keUHQGN1Ns9aDw7Q==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typescript-eslint/eslint-plugin": "8.70.1",
|
"@typescript-eslint/eslint-plugin": "8.74.0",
|
||||||
"@typescript-eslint/parser": "8.70.1",
|
"@typescript-eslint/parser": "8.74.0",
|
||||||
"@typescript-eslint/typescript-estree": "8.70.1",
|
"@typescript-eslint/typescript-estree": "8.74.0",
|
||||||
"@typescript-eslint/utils": "8.70.1"
|
"@typescript-eslint/utils": "8.74.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
|
||||||
@@ -2931,13 +2945,13 @@
|
|||||||
},
|
},
|
||||||
"packages/jwt": {
|
"packages/jwt": {
|
||||||
"name": "@green-tea/jwt",
|
"name": "@green-tea/jwt",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"jose": "^6.2.12"
|
"jose": "^6.2.12"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"bun": ">=1.3",
|
"bun": ">=1.3",
|
||||||
@@ -2947,10 +2961,10 @@
|
|||||||
},
|
},
|
||||||
"packages/metrics": {
|
"packages/metrics": {
|
||||||
"name": "@green-tea/metrics",
|
"name": "@green-tea/metrics",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"bun": ">=1.3",
|
"bun": ">=1.3",
|
||||||
@@ -2960,10 +2974,10 @@
|
|||||||
},
|
},
|
||||||
"packages/rate-limit": {
|
"packages/rate-limit": {
|
||||||
"name": "@green-tea/rate-limit",
|
"name": "@green-tea/rate-limit",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"bun": ">=1.3",
|
"bun": ">=1.3",
|
||||||
|
|||||||
@@ -2,8 +2,24 @@
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [26.11.0-rc.2] - 2026-11-23
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- **Versions track core.** This release is 26.11.0-rc.2, the core it is tested against.
|
||||||
|
- **Core is a range, `^26.11.0-rc.2`, not an exact `26.9.0-beta.2`.** JSR consumers resolve the
|
||||||
|
`@green-tea/core` import in `deno.json`, and the exact pin gave an application on a newer core a
|
||||||
|
second, older copy whose types `tsc` could pick up. The range starts at the core the tests run
|
||||||
|
against (26.11.0-rc.2, which fixes nine security advisories reported against rc.1) and stops at
|
||||||
|
the next year, the only core release that may break.
|
||||||
|
|
||||||
|
## [26.9.0-beta.0] - 2026-09-23
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
- `jwt({ keys, provides? })`: loads each JWK file while providers boot and publishes a `JwtRegistry`
|
- `jwt({ keys, provides? })`: loads each JWK file while providers boot and publishes a `JwtRegistry`
|
||||||
under `provides` (default `jwt`). `Signer` signs with `iat` and a random `jti`, and verifies issuer
|
under `provides` (default `jwt`). `Signer` signs with `iat` and a random `jti`, and verifies issuer
|
||||||
and audience. `JwtRegistry.publicJwk(name)` returns a key's public half for a JWKS endpoint.
|
and audience. `JwtRegistry.publicJwk(name)` returns a key's public half for a JWKS endpoint.
|
||||||
|
|
||||||
|
[26.11.0-rc.2]: https://jsr.io/@green-tea/jwt@26.11.0-rc.2
|
||||||
|
[26.9.0-beta.0]: https://jsr.io/@green-tea/jwt@26.9.0-beta.0
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/jwt",
|
"name": "@green-tea/jwt",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"exports": "./src/index.ts",
|
"exports": "./src/index.ts",
|
||||||
"imports": {
|
"imports": {
|
||||||
"@green-tea/core": "npm:@green-tea/core@26.9.0-beta.2",
|
"@green-tea/core": "npm:@green-tea/core@^26.11.0-rc.2",
|
||||||
"jose": "npm:jose@^6.2.12"
|
"jose": "npm:jose@^6.2.12"
|
||||||
},
|
},
|
||||||
"publish": {
|
"publish": {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/jwt",
|
"name": "@green-tea/jwt",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"private": true,
|
"private": true,
|
||||||
"description": "Loads JWT signing keys at boot and publishes a sign/verify registry into the green-tea graph.",
|
"description": "Loads JWT signing keys at boot and publishes a sign/verify registry into the green-tea graph.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
@@ -20,6 +20,6 @@
|
|||||||
"jose": "^6.2.12"
|
"jose": "^6.2.12"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2,9 +2,25 @@
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [26.11.0-rc.2] - 2026-11-23
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- **Versions track core.** This release is 26.11.0-rc.2, the core it is tested against.
|
||||||
|
- **Core is a range, `^26.11.0-rc.2`, not an exact `26.9.0-beta.2`.** JSR consumers resolve the
|
||||||
|
`@green-tea/core` import in `deno.json`, and the exact pin gave an application on a newer core a
|
||||||
|
second, older copy whose types `tsc` could pick up. The range starts at the core the tests run
|
||||||
|
against (26.11.0-rc.2, which fixes nine security advisories reported against rc.1) and stops at
|
||||||
|
the next year, the only core release that may break.
|
||||||
|
|
||||||
|
## [26.9.0-beta.0] - 2026-09-23
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
- `metrics({ provides? })`: subscribes to the lifecycle stream and publishes a `Metrics` with
|
- `metrics({ provides? })`: subscribes to the lifecycle stream and publishes a `Metrics` with
|
||||||
`render()`. Counts `request:end` as requests and `request:failed` separately, labelled on the
|
`render()`. Counts `request:end` as requests and `request:failed` separately, labelled on the
|
||||||
bounded `route` rather than on the caller-controlled `name`. `prometheus` is a `TransformerFn` for
|
bounded `route` rather than on the caller-controlled `name`. `prometheus` is a `TransformerFn` for
|
||||||
serving `render()` from a route the application owns. Closes green-tea#68.
|
serving `render()` from a route the application owns. Closes green-tea#68.
|
||||||
|
|
||||||
|
[26.11.0-rc.2]: https://jsr.io/@green-tea/metrics@26.11.0-rc.2
|
||||||
|
[26.9.0-beta.0]: https://jsr.io/@green-tea/metrics@26.9.0-beta.0
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/metrics",
|
"name": "@green-tea/metrics",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"exports": "./src/index.ts",
|
"exports": "./src/index.ts",
|
||||||
"imports": {
|
"imports": {
|
||||||
"@green-tea/core": "npm:@green-tea/core@26.9.0-beta.2"
|
"@green-tea/core": "npm:@green-tea/core@^26.11.0-rc.2"
|
||||||
},
|
},
|
||||||
"publish": {
|
"publish": {
|
||||||
"include": ["src", "README.md", "CHANGELOG.md", "deno.json"]
|
"include": ["src", "README.md", "CHANGELOG.md", "deno.json"]
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/metrics",
|
"name": "@green-tea/metrics",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"private": true,
|
"private": true,
|
||||||
"description": "Counts green-tea's lifecycle events and renders them in the Prometheus text format.",
|
"description": "Counts green-tea's lifecycle events and renders them in the Prometheus text format.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
@@ -17,6 +17,6 @@
|
|||||||
"bun": ">=1.3"
|
"bun": ">=1.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -88,7 +88,8 @@ test('the transformer serves the text format with the content type Prometheus ex
|
|||||||
const rendered = prometheus('green_tea_requests_total{route="/x",method="GET",status="200"} 1\n');
|
const rendered = prometheus('green_tea_requests_total{route="/x",method="GET",status="200"} 1\n');
|
||||||
|
|
||||||
assert.equal(rendered.status, 200);
|
assert.equal(rendered.status, 200);
|
||||||
assert.match(rendered.headers!['content-type'], /text\/plain/);
|
// Core RC.1 widens response header values to `string | string[]` (core #113), so a reader narrows.
|
||||||
|
assert.match(String(rendered.headers!['content-type']), /text\/plain/);
|
||||||
assert.match(rendered.body, /green_tea_requests_total/);
|
assert.match(rendered.body, /green_tea_requests_total/);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -2,9 +2,25 @@
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [26.11.0-rc.2] - 2026-11-23
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- **Versions track core.** This release is 26.11.0-rc.2, the core it is tested against.
|
||||||
|
- **Core is a range, `^26.11.0-rc.2`, not an exact `26.9.0-beta.2`.** JSR consumers resolve the
|
||||||
|
`@green-tea/core` import in `deno.json`, and the exact pin gave an application on a newer core a
|
||||||
|
second, older copy whose types `tsc` could pick up. The range starts at the core the tests run
|
||||||
|
against (26.11.0-rc.2, which fixes nine security advisories reported against rc.1) and stops at
|
||||||
|
the next year, the only core release that may break.
|
||||||
|
|
||||||
|
## [26.9.0-beta.0] - 2026-09-23
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
- `rateLimit({ rules, store?, keyOf?, provides? })`: publishes a `RateLimiter` under `provides`
|
- `rateLimit({ rules, store?, keyOf?, provides? })`: publishes a `RateLimiter` under `provides`
|
||||||
(default `rateLimit`). Exceeding a rule throws `TooManyRequests`, a branded 429 carrying
|
(default `rateLimit`). Exceeding a rule throws `TooManyRequests`, a branded 429 carrying
|
||||||
`Retry-After`. The default `MemoryStore` sweeps expired windows on an interval and is released by
|
`Retry-After`. The default `MemoryStore` sweeps expired windows on an interval and is released by
|
||||||
the plugin's `onShutdown`.
|
the plugin's `onShutdown`.
|
||||||
|
|
||||||
|
[26.11.0-rc.2]: https://jsr.io/@green-tea/rate-limit@26.11.0-rc.2
|
||||||
|
[26.9.0-beta.0]: https://jsr.io/@green-tea/rate-limit@26.9.0-beta.0
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/rate-limit",
|
"name": "@green-tea/rate-limit",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"exports": "./src/index.ts",
|
"exports": "./src/index.ts",
|
||||||
"imports": {
|
"imports": {
|
||||||
"@green-tea/core": "npm:@green-tea/core@26.9.0-beta.2"
|
"@green-tea/core": "npm:@green-tea/core@^26.11.0-rc.2"
|
||||||
},
|
},
|
||||||
"publish": {
|
"publish": {
|
||||||
"include": ["src", "README.md", "CHANGELOG.md", "deno.json"]
|
"include": ["src", "README.md", "CHANGELOG.md", "deno.json"]
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@green-tea/rate-limit",
|
"name": "@green-tea/rate-limit",
|
||||||
"version": "26.9.0-beta.0",
|
"version": "26.11.0-rc.2",
|
||||||
"private": true,
|
"private": true,
|
||||||
"description": "A per-request rate limiter published into the green-tea graph, with a branded 429 and a swept in-memory store.",
|
"description": "A per-request rate limiter published into the green-tea graph, with a branded 429 and a swept in-memory store.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
@@ -17,6 +17,6 @@
|
|||||||
"bun": ">=1.3"
|
"bun": ">=1.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@green-tea/core": "26.9.0-beta.2"
|
"@green-tea/core": "26.11.0-rc.2"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,148 @@
|
|||||||
|
#!/usr/bin/env node
|
||||||
|
// Two jobs around a `deno publish`, both about the same thing: a JSR version can never be replaced
|
||||||
|
// or removed, so anything wrong has to be caught *before* the publish rather than reported after it.
|
||||||
|
//
|
||||||
|
// --check Which packages this tag would publish, and whether each has a CHANGELOG entry
|
||||||
|
// to match. Exits non-zero when one does not. Run this BEFORE publishing.
|
||||||
|
// --notes <log> The GitHub release body, built from what `deno publish` actually did.
|
||||||
|
//
|
||||||
|
// The order matters and is the whole point of splitting it in two. core's equivalent script runs
|
||||||
|
// after npm and JSR have already published, so a missing heading fails a release that has already
|
||||||
|
// shipped — a wart worth not inheriting.
|
||||||
|
import { readFileSync, readdirSync } from 'node:fs';
|
||||||
|
import { join } from 'node:path';
|
||||||
|
|
||||||
|
const ROOT = new URL('..', import.meta.url).pathname;
|
||||||
|
const PACKAGES = join(ROOT, 'packages');
|
||||||
|
const REPO = 'Expressive-Tea/green-tea-plugins';
|
||||||
|
|
||||||
|
/** Every workspace package, with the version its deno.json declares. */
|
||||||
|
function readPackages() {
|
||||||
|
return readdirSync(PACKAGES, { withFileTypes: true })
|
||||||
|
.filter((entry) => entry.isDirectory())
|
||||||
|
.map((entry) => {
|
||||||
|
const deno = JSON.parse(readFileSync(join(PACKAGES, entry.dir ?? entry.name, 'deno.json'), 'utf8'));
|
||||||
|
return { dir: entry.name, name: deno.name, version: deno.version };
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Whether JSR already serves this exact version. A 404 for a package with no versions at all is
|
||||||
|
* not an error — it is what every one of these looks like until its first publish. */
|
||||||
|
async function isPublished({ name, version }) {
|
||||||
|
const [scope, pkg] = name.replace(/^@/, '').split('/');
|
||||||
|
const url = `https://api.jsr.io/scopes/${scope}/packages/${pkg}/versions/${version}`;
|
||||||
|
const response = await fetch(url, { headers: { accept: 'application/json' } });
|
||||||
|
|
||||||
|
if (response.status === 404) return false;
|
||||||
|
if (!response.ok) throw new Error(`${name}@${version}: ${url} answered ${response.status}`);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** One version's section of a package CHANGELOG, heading excluded. */
|
||||||
|
function changelogSection(dir, version) {
|
||||||
|
const lines = readFileSync(join(PACKAGES, dir, 'CHANGELOG.md'), 'utf8').split('\n');
|
||||||
|
const start = lines.findIndex((line) => line.startsWith(`## [${version}]`));
|
||||||
|
if (start === -1) return null;
|
||||||
|
|
||||||
|
const rest = lines.slice(start + 1);
|
||||||
|
const end = rest.findIndex((line) => line.startsWith('## '));
|
||||||
|
|
||||||
|
return (end === -1 ? rest : rest.slice(0, end))
|
||||||
|
// Link reference definitions belong to the file, not to the entry. Nothing separates them from
|
||||||
|
// the last section, so without this they ride along into the release body as a stray line.
|
||||||
|
.filter((line) => !/^\[[^\]]+\]:\s/.test(line))
|
||||||
|
.join('\n')
|
||||||
|
.trim();
|
||||||
|
}
|
||||||
|
|
||||||
|
async function check() {
|
||||||
|
const packages = readPackages();
|
||||||
|
const published = await Promise.all(packages.map(isPublished));
|
||||||
|
const pending = packages.filter((_, i) => !published[i]);
|
||||||
|
|
||||||
|
if (pending.length === 0) {
|
||||||
|
console.log('Nothing to publish: every package version is already on JSR.');
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
let missing = 0;
|
||||||
|
for (const pkg of pending) {
|
||||||
|
const section = changelogSection(pkg.dir, pkg.version);
|
||||||
|
if (section) {
|
||||||
|
console.log(` ok ${pkg.name}@${pkg.version}`);
|
||||||
|
} else {
|
||||||
|
// Deliberately an error rather than a warning. A version heading is a claim that the release
|
||||||
|
// exists, and publishing without one leaves a package on JSR that its own changelog says was
|
||||||
|
// never released — permanently, because the version cannot be replaced.
|
||||||
|
console.error(` MISSING ${pkg.name}@${pkg.version} has no "## [${pkg.version}]" in packages/${pkg.dir}/CHANGELOG.md`);
|
||||||
|
missing += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
packages
|
||||||
|
.filter((_, i) => published[i])
|
||||||
|
.forEach((pkg) => console.log(` skip ${pkg.name}@${pkg.version} (already on JSR)`));
|
||||||
|
|
||||||
|
return missing === 0 ? 0 : 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Parse what `deno publish` reported. Its own output is the only honest source for this: predicting
|
||||||
|
* it means duplicating the filtering Deno already did, and being wrong about it silently. */
|
||||||
|
function notes(logPath, tag) {
|
||||||
|
const log = readFileSync(logPath, 'utf8');
|
||||||
|
// Colour codes survive when a terminal is attached and vanish in CI. Strip either way.
|
||||||
|
const plain = log.replace(/\u001b\[[0-9;]*m/g, '');
|
||||||
|
const shipped = [...plain.matchAll(/Successfully published (@[^@\s]+\/[^@\s]+)@(\S+)/g)]
|
||||||
|
.map(([, name, version]) => ({ name, version }));
|
||||||
|
|
||||||
|
// A log carrying neither marker is not "nothing was published" — it is a log this script cannot
|
||||||
|
// read, and the two are indistinguishable from the text alone. Saying nothing shipped when three
|
||||||
|
// packages did is the worse failure, and it is silent, so refuse instead of guessing.
|
||||||
|
//
|
||||||
|
// This is not hypothetical: the first version of this workflow piped only stdout, while deno logs
|
||||||
|
// to stderr, so every successful release would have produced an empty log and a release body
|
||||||
|
// announcing that nothing happened.
|
||||||
|
if (shipped.length === 0 && !/already published/.test(plain)) {
|
||||||
|
throw new Error(
|
||||||
|
`${logPath} contains neither "Successfully published" nor "already published". ` +
|
||||||
|
'Either the publish did not run, or its output is not being captured — check that the step ' +
|
||||||
|
'redirects stderr (deno logs there) and that the pipeline uses pipefail.',
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (shipped.length === 0) {
|
||||||
|
return `No package versions were published by \`${tag}\` — every version in the workspace was already on JSR.`;
|
||||||
|
}
|
||||||
|
|
||||||
|
const byName = Object.fromEntries(readPackages().map((pkg) => [pkg.name, pkg.dir]));
|
||||||
|
const body = shipped.map(({ name, version }) => {
|
||||||
|
const dir = byName[name];
|
||||||
|
const section = (dir && changelogSection(dir, version)) || '_No changelog entry._';
|
||||||
|
const link = `https://github.com/${REPO}/blob/${tag}/packages/${dir}/CHANGELOG.md`;
|
||||||
|
|
||||||
|
return `## [${name}@${version}](https://jsr.io/${name}@${version})\n\n${section}\n\n[Full changelog](${link})`;
|
||||||
|
});
|
||||||
|
|
||||||
|
const untouched = readPackages().filter((pkg) => !shipped.some((s) => s.name === pkg.name));
|
||||||
|
const footer = untouched.length
|
||||||
|
? `\n\n---\n\nUnchanged in this release: ${untouched.map((p) => `\`${p.name}@${p.version}\``).join(', ')}.`
|
||||||
|
: '';
|
||||||
|
|
||||||
|
return `${body.join('\n\n')}${footer}`;
|
||||||
|
}
|
||||||
|
|
||||||
|
const [mode, arg] = process.argv.slice(2);
|
||||||
|
|
||||||
|
if (mode === '--check') {
|
||||||
|
process.exit(await check());
|
||||||
|
} else if (mode === '--notes') {
|
||||||
|
if (!arg) {
|
||||||
|
console.error('usage: release.mjs --notes <publish-log> [tag]');
|
||||||
|
process.exit(2);
|
||||||
|
}
|
||||||
|
console.log(notes(arg, process.argv[4] ?? 'main'));
|
||||||
|
} else {
|
||||||
|
console.error('usage: release.mjs --check | --notes <publish-log> [tag]');
|
||||||
|
process.exit(2);
|
||||||
|
}
|
||||||
@@ -76,8 +76,11 @@ for (const dir of packages) {
|
|||||||
assert.equal(pkg.peerDependencies?.['@green-tea/core'], undefined, 'core in peerDependencies');
|
assert.equal(pkg.peerDependencies?.['@green-tea/core'], undefined, 'core in peerDependencies');
|
||||||
});
|
});
|
||||||
|
|
||||||
test(`${dir}: JSR maps the core version npm installs`, () => {
|
// A range, not a pin (core #73): JSR consumers resolve this import, and an exact version gave an app
|
||||||
assert.equal(deno.imports?.['@green-tea/core'], `npm:@green-tea/core@${pkg.devDependencies?.['@green-tea/core']}`);
|
// on a newer core the plugin's older core types. The floor is the version the tests run against;
|
||||||
|
// `^` stops at the next year, the only release that may break (core's versioning policy).
|
||||||
|
test(`${dir}: JSR maps a core range whose floor is the version npm installs`, () => {
|
||||||
|
assert.equal(deno.imports?.['@green-tea/core'], `npm:@green-tea/core@^${pkg.devDependencies?.['@green-tea/core']}`);
|
||||||
});
|
});
|
||||||
|
|
||||||
test(`${dir}: engines declares runtimes, and only known ones`, () => {
|
test(`${dir}: engines declares runtimes, and only known ones`, () => {
|
||||||
|
|||||||
Reference in new issue
Block a user