Repository navigation
70 lines (62 loc) · 2.51 KB
/
Copy pathpackage-consumer.yml
File metadata and controls
70 lines (62 loc) · 2.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: Package Consumer
# Not a required check, and it must stay that way: it builds the package, packs
# it, and then installs the tarball with its thousands of modules once per case,
# each in a fresh directory, with the npm registry in the loop. That is far too
# slow and too network-dependent for `test` or `provider-safety-net`, which gate
# every pull request. Do not add its name to branch protection or to a ruleset.
#
# What it answers is whether the PACKED package type-checks for a consumer with
# `strict` on and `skipLibCheck` off, across @types/node 22 and latest, React 18
# and 19, and an install that omits the optional dependencies. See the header of
# test/continuous-test-suite-package-consumer.ts for the cases and for
# KNOWN_FAILURES, the ratchet of defects it expects while their fixes land.
#
# Nightly, at an hour that sits away from live-matrix (03:00 UTC) and
# model-liveness (04:00 UTC), plus on demand, plus on pull requests that change
# what a consumer receives: the manifest, the public types, or an entry point
# the exports map names.
on:
schedule:
- cron: "17 6 * * *"
workflow_dispatch:
pull_request:
paths:
- "package.json"
- "src/lib/types/**"
- "src/lib/**/index.ts"
- "src/lib/client/reactHooks.tsx"
- "src/lib/voice/streaming/endpointer.ts"
- "src/lib/processors/*.ts"
- "src/lib/adapters/*.ts"
- "src/cli/index.ts"
- "test/continuous-test-suite-package-consumer.ts"
- ".github/workflows/package-consumer.yml"
permissions:
contents: read
concurrency:
group: package-consumer-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
package-consumer:
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Setup PNPM
uses: pnpm/action-setup@ea17c68df8912ef543352723c149a84f56e3d413 # v6.1.0
- name: Setup Node.js
uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7.1.0
with:
node-version: "22.23.4"
cache: "pnpm"
- name: Install dependencies
run: pnpm install --frozen-lockfile
# The suite packs whatever dist/ holds and refuses a dist/ older than src/,
# so the build has to come first.
- name: Build
run: pnpm run build
- name: Strict consumer type-check of the packed package
run: pnpm run test:package-consumer