switchroom 0.13.2 → 0.13.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/agent-scheduler/index.js +2 -2
  2. package/dist/auth-broker/index.js +2 -2
  3. package/dist/cli/switchroom.js +21 -18
  4. package/dist/host-control/main.js +2 -2
  5. package/dist/vault/approvals/kernel-server.js +2 -2
  6. package/dist/vault/broker/server.js +2 -2
  7. package/package.json +1 -1
  8. package/telegram-plugin/dist/gateway/gateway.js +42 -10
  9. package/telegram-plugin/gateway/boot-probes.ts +13 -6
  10. package/telegram-plugin/gateway/gateway.ts +44 -6
  11. package/telegram-plugin/hooks/silent-end-interrupt-stop.mjs +5 -1
  12. package/telegram-plugin/silent-end.ts +56 -0
  13. package/telegram-plugin/tests/boot-probes.test.ts +26 -2
  14. package/telegram-plugin/tests/silent-end.test.ts +69 -0
  15. package/skills/buildkite-agent-infrastructure/SKILL.md +0 -321
  16. package/skills/buildkite-agent-infrastructure/agents/openai.yaml +0 -6
  17. package/skills/buildkite-agent-infrastructure/assets/buildkite-icon-large.png +0 -0
  18. package/skills/buildkite-agent-infrastructure/assets/buildkite-icon-small.png +0 -0
  19. package/skills/buildkite-agent-infrastructure/references/audit-logging.md +0 -87
  20. package/skills/buildkite-agent-infrastructure/references/graphql-mutations.md +0 -690
  21. package/skills/buildkite-agent-infrastructure/references/instance-shapes.md +0 -38
  22. package/skills/buildkite-agent-infrastructure/references/pipeline-templates.md +0 -73
  23. package/skills/buildkite-agent-infrastructure/references/self-hosted-agents.md +0 -137
  24. package/skills/buildkite-agent-infrastructure/references/sso-saml.md +0 -92
  25. package/skills/buildkite-agent-runtime/SKILL.md +0 -509
  26. package/skills/buildkite-agent-runtime/agents/openai.yaml +0 -6
  27. package/skills/buildkite-agent-runtime/assets/buildkite-icon-large.png +0 -0
  28. package/skills/buildkite-agent-runtime/assets/buildkite-icon-small.png +0 -0
  29. package/skills/buildkite-agent-runtime/references/flag-reference.md +0 -417
  30. package/skills/buildkite-agent-runtime/references/patterns-and-recipes.md +0 -555
  31. package/skills/buildkite-api/SKILL.md +0 -308
  32. package/skills/buildkite-api/agents/openai.yaml +0 -6
  33. package/skills/buildkite-api/assets/buildkite-icon-large.png +0 -0
  34. package/skills/buildkite-api/assets/buildkite-icon-small.png +0 -0
  35. package/skills/buildkite-api/references/graphql-reference.md +0 -195
  36. package/skills/buildkite-api/references/patterns.md +0 -44
  37. package/skills/buildkite-api/references/webhooks.md +0 -161
  38. package/skills/buildkite-cli/SKILL.md +0 -397
  39. package/skills/buildkite-cli/agents/openai.yaml +0 -6
  40. package/skills/buildkite-cli/assets/buildkite-icon-large.png +0 -0
  41. package/skills/buildkite-cli/assets/buildkite-icon-small.png +0 -0
  42. package/skills/buildkite-cli/references/command-reference.md +0 -181
  43. package/skills/buildkite-migration/SKILL.md +0 -195
  44. package/skills/buildkite-pipelines/SKILL.md +0 -481
  45. package/skills/buildkite-pipelines/agents/openai.yaml +0 -6
  46. package/skills/buildkite-pipelines/assets/buildkite-icon-large.png +0 -0
  47. package/skills/buildkite-pipelines/assets/buildkite-icon-small.png +0 -0
  48. package/skills/buildkite-pipelines/examples/basic-pipeline.yml +0 -24
  49. package/skills/buildkite-pipelines/examples/optimized-pipeline.yml +0 -100
  50. package/skills/buildkite-pipelines/references/advanced-patterns.md +0 -286
  51. package/skills/buildkite-pipelines/references/retry-and-error-codes.md +0 -131
  52. package/skills/buildkite-pipelines/references/step-types-reference.md +0 -225
  53. package/skills/buildkite-secure-delivery/SKILL.md +0 -182
  54. package/skills/buildkite-secure-delivery/agents/openai.yaml +0 -6
  55. package/skills/buildkite-secure-delivery/assets/buildkite-icon-large.png +0 -0
  56. package/skills/buildkite-secure-delivery/assets/buildkite-icon-small.png +0 -0
  57. package/skills/buildkite-secure-delivery/references/oidc-cloud-providers.md +0 -83
  58. package/skills/buildkite-secure-delivery/references/package-publishing.md +0 -100
  59. package/skills/buildkite-test-engine/SKILL.md +0 -256
  60. package/skills/buildkite-test-engine/agents/openai.yaml +0 -6
  61. package/skills/buildkite-test-engine/assets/buildkite-icon-large.png +0 -0
  62. package/skills/buildkite-test-engine/assets/buildkite-icon-small.png +0 -0
  63. package/skills/buildkite-test-engine/examples/bktec-splitting.yml +0 -16
  64. package/skills/buildkite-test-engine/examples/collector-pipeline.yml +0 -11
  65. package/skills/buildkite-test-engine/references/collectors.md +0 -198
  66. package/skills/buildkite-test-engine/references/splitting-examples.md +0 -93
@@ -1,11 +0,0 @@
1
- # Minimal pipeline using the test-collector plugin with RSpec
2
- # Collects test timing data and sends it to Buildkite Test Engine
3
- steps:
4
- - label: ":rspec: Tests"
5
- command: "bundle exec rspec --format progress --format RspecJunitFormatter --out tmp/rspec.xml"
6
- plugins:
7
- - test-collector#v2.0.0:
8
- files: "tmp/rspec.xml"
9
- format: "junit"
10
- env:
11
- BUILDKITE_ANALYTICS_TOKEN: "your-suite-api-token"
@@ -1,198 +0,0 @@
1
- # Test Collectors Reference
2
-
3
- This file covers all framework-specific collector configurations for sending test execution data to Buildkite Test Engine. Install the collector for the test framework, set `BUILDKITE_ANALYTICS_TOKEN`, and run tests normally.
4
-
5
- ## Ruby — RSpec
6
-
7
- Add the gem to the Gemfile:
8
-
9
- ```ruby
10
- group :test do
11
- gem "buildkite-test_collector"
12
- end
13
- ```
14
-
15
- Configure in `spec_helper.rb` (require gems that patch `Net::HTTP` before this):
16
-
17
- ```ruby
18
- require "buildkite/test_collector"
19
-
20
- Buildkite::TestCollector.configure(hook: :rspec)
21
- ```
22
-
23
- Pipeline step:
24
-
25
- ```yaml
26
- steps:
27
- - label: ":rspec: Tests"
28
- command: "bundle exec rspec"
29
- env:
30
- BUILDKITE_ANALYTICS_TOKEN: "your-suite-api-token"
31
- ```
32
-
33
- ## Ruby — Minitest
34
-
35
- Same gem, different hook. Configure in `test_helper.rb`:
36
-
37
- ```ruby
38
- require "buildkite/test_collector"
39
-
40
- Buildkite::TestCollector.configure(hook: :minitest)
41
- ```
42
-
43
- ## JavaScript — Jest
44
-
45
- Install the npm package:
46
-
47
- ```bash
48
- npm install --save-dev buildkite-test-collector
49
- ```
50
-
51
- Add the reporter to `jest.config.js`:
52
-
53
- ```javascript
54
- module.exports = {
55
- reporters: [
56
- "default",
57
- "buildkite-test-collector/jest/reporter"
58
- ],
59
- testLocationInResults: true
60
- };
61
- ```
62
-
63
- Pipeline step:
64
-
65
- ```yaml
66
- steps:
67
- - label: ":jest: Tests"
68
- command: "npm test"
69
- env:
70
- BUILDKITE_ANALYTICS_TOKEN: "your-suite-api-token"
71
- ```
72
-
73
- ## JavaScript — Playwright
74
-
75
- Add the reporter to `playwright.config.js`:
76
-
77
- ```javascript
78
- module.exports = {
79
- reporter: [
80
- ["list"],
81
- ["buildkite-test-collector/playwright/reporter"]
82
- ]
83
- };
84
- ```
85
-
86
- ## JavaScript — Cypress
87
-
88
- Configure in `cypress.config.js`:
89
-
90
- ```javascript
91
- module.exports = {
92
- reporter: "buildkite-test-collector/cypress/reporter",
93
- reporterOptions: {}
94
- };
95
- ```
96
-
97
- ## Python — pytest
98
-
99
- bktec supports pytest directly as a test runner. No separate collector package is needed — bktec handles both splitting and result collection when `BUILDKITE_TEST_ENGINE_TEST_RUNNER` is set to `pytest`.
100
-
101
- For collecting analytics data without bktec, use the JUnit XML upload method described below.
102
-
103
- ## Go (using the universal JUnit method)
104
-
105
- Generate JUnit XML with `gotestsum`, then upload to the analytics API:
106
-
107
- ```yaml
108
- steps:
109
- - label: ":golang: Tests"
110
- command: |
111
- gotestsum --junitfile junit.xml -- ./...
112
- curl \
113
- -X POST \
114
- --fail-with-body \
115
- -H "Authorization: Token token=\"$$BUILDKITE_ANALYTICS_TOKEN\"" \
116
- -F "data=@junit.xml" \
117
- -F "format=junit" \
118
- -F "run_env[CI]=buildkite" \
119
- -F "run_env[key]=$BUILDKITE_BUILD_ID" \
120
- -F "run_env[number]=$BUILDKITE_BUILD_NUMBER" \
121
- -F "run_env[job_id]=$BUILDKITE_JOB_ID" \
122
- -F "run_env[branch]=$BUILDKITE_BRANCH" \
123
- -F "run_env[commit_sha]=$BUILDKITE_COMMIT" \
124
- -F "run_env[message]=$BUILDKITE_MESSAGE" \
125
- -F "run_env[url]=$BUILDKITE_BUILD_URL" \
126
- https://analytics-api.buildkite.com/v1/uploads
127
- env:
128
- BUILDKITE_ANALYTICS_TOKEN: "your-suite-api-token"
129
- ```
130
-
131
- ## JUnit XML Upload — Universal Fallback
132
-
133
- Any language that produces JUnit XML can upload results to Test Engine via the analytics API. This is the fallback for languages without a dedicated collector.
134
-
135
- ```bash
136
- curl \
137
- -X POST \
138
- --fail-with-body \
139
- -H "Authorization: Token token=\"$BUILDKITE_ANALYTICS_TOKEN\"" \
140
- -F "data=@test-results.xml" \
141
- -F "format=junit" \
142
- -F "run_env[CI]=buildkite" \
143
- -F "run_env[key]=$BUILDKITE_BUILD_ID" \
144
- -F "run_env[number]=$BUILDKITE_BUILD_NUMBER" \
145
- -F "run_env[branch]=$BUILDKITE_BRANCH" \
146
- -F "run_env[commit_sha]=$BUILDKITE_COMMIT" \
147
- https://analytics-api.buildkite.com/v1/uploads
148
- ```
149
-
150
- | Parameter | Required | Description |
151
- |-----------|----------|-------------|
152
- | `data` | Yes | The JUnit XML file (`@path/to/file.xml`) |
153
- | `format` | Yes | Always `junit` for XML uploads |
154
- | `run_env[CI]` | No | CI platform identifier (e.g., `buildkite`, `github_actions`) |
155
- | `run_env[key]` | Yes | Unique identifier for this build run |
156
- | `run_env[number]` | No | Build number |
157
- | `run_env[branch]` | No | Git branch |
158
- | `run_env[commit_sha]` | No | Git commit SHA |
159
- | `run_env[job_id]` | No | Job ID (for parallel builds) |
160
- | `run_env[message]` | No | Commit message |
161
- | `run_env[url]` | No | URL to the build |
162
-
163
- Maximum 5000 test results per upload. For larger suites, split into multiple uploads using the same `run_env[key]` value.
164
-
165
- ## test-collector Plugin
166
-
167
- As an alternative to framework-specific collectors, the `test-collector` plugin uploads test result files directly:
168
-
169
- ```yaml
170
- steps:
171
- - label: ":test_tube: Tests"
172
- command: "make test"
173
- plugins:
174
- - test-collector#v2.0.0:
175
- files: "tmp/junit-*.xml"
176
- format: "junit"
177
- env:
178
- BUILDKITE_ANALYTICS_TOKEN: "your-suite-api-token"
179
- ```
180
-
181
- | Attribute | Required | Description |
182
- |-----------|----------|-------------|
183
- | `files` | Yes | Glob pattern for test result files |
184
- | `format` | Yes | Result format: `junit`, `json` |
185
-
186
- The plugin runs after the test command, collects matching files, and uploads them to Test Engine. Pin the plugin version (`test-collector#v2.0.0`, not `test-collector#v2`).
187
-
188
- ## Running collectors locally
189
-
190
- Test locally to verify collector configuration before committing:
191
-
192
- ```bash
193
- BUILDKITE_ANALYTICS_TOKEN=your-suite-api-token \
194
- BUILDKITE_ANALYTICS_MESSAGE="Local test run" \
195
- bundle exec rspec
196
- ```
197
-
198
- Results appear in the Test Engine dashboard within seconds.
@@ -1,93 +0,0 @@
1
- # Test Splitting Examples and Configuration
2
-
3
- Detailed per-framework splitting examples, split-by-example vs split-by-file guidance, parallelism tuning, and custom test command configuration for bktec.
4
-
5
- ## Complete examples by framework
6
-
7
- ### RSpec with retry and split-by-example
8
-
9
- ```yaml
10
- steps:
11
- - label: ":rspec: Tests %n"
12
- command: bktec
13
- parallelism: 10
14
- env:
15
- BUILDKITE_TEST_ENGINE_API_ACCESS_TOKEN: "your-api-access-token"
16
- BUILDKITE_TEST_ENGINE_SUITE_SLUG: "backend-rspec"
17
- BUILDKITE_TEST_ENGINE_TEST_RUNNER: "rspec"
18
- BUILDKITE_TEST_ENGINE_RESULT_PATH: "tmp/rspec-result.json"
19
- BUILDKITE_TEST_ENGINE_RETRY_COUNT: "2"
20
- BUILDKITE_TEST_ENGINE_SPLIT_BY_EXAMPLE: "true"
21
- ```
22
-
23
- ### Jest
24
-
25
- ```yaml
26
- steps:
27
- - label: ":jest: Tests %n"
28
- command: bktec
29
- parallelism: 8
30
- env:
31
- BUILDKITE_TEST_ENGINE_API_ACCESS_TOKEN: "your-api-access-token"
32
- BUILDKITE_TEST_ENGINE_SUITE_SLUG: "frontend-jest"
33
- BUILDKITE_TEST_ENGINE_TEST_RUNNER: "jest"
34
- BUILDKITE_TEST_ENGINE_RESULT_PATH: "tmp/jest-result.json"
35
- ```
36
-
37
- ### pytest
38
-
39
- ```yaml
40
- steps:
41
- - label: ":python: Tests %n"
42
- command: bktec
43
- parallelism: 6
44
- env:
45
- BUILDKITE_TEST_ENGINE_API_ACCESS_TOKEN: "your-api-access-token"
46
- BUILDKITE_TEST_ENGINE_SUITE_SLUG: "backend-pytest"
47
- BUILDKITE_TEST_ENGINE_TEST_RUNNER: "pytest"
48
- BUILDKITE_TEST_ENGINE_RESULT_PATH: "tmp/pytest-result.json"
49
- BUILDKITE_TEST_ENGINE_RETRY_COUNT: "2"
50
- ```
51
-
52
- ### Go
53
-
54
- ```yaml
55
- steps:
56
- - label: ":golang: Tests %n"
57
- command: bktec
58
- parallelism: 4
59
- env:
60
- BUILDKITE_TEST_ENGINE_API_ACCESS_TOKEN: "your-api-access-token"
61
- BUILDKITE_TEST_ENGINE_SUITE_SLUG: "backend-go"
62
- BUILDKITE_TEST_ENGINE_TEST_RUNNER: "go"
63
- BUILDKITE_TEST_ENGINE_RESULT_PATH: "tmp/go-result.json"
64
- ```
65
-
66
- ## Split by example vs split by file
67
-
68
- By default, bktec splits by **file** — each parallel agent gets a set of test files. Set `BUILDKITE_TEST_ENGINE_SPLIT_BY_EXAMPLE` to `true` to split by **individual test example** instead.
69
-
70
- Split-by-example produces more even partitions when test files have widely varying numbers of tests (e.g., one file with 200 tests and another with 5). Currently only supported for RSpec.
71
-
72
- ## Choosing parallelism level
73
-
74
- | Suite size | Suggested `parallelism` | Reasoning |
75
- |------------|------------------------|-----------|
76
- | < 100 tests | 2-4 | Overhead of splitting outweighs benefit at small scale |
77
- | 100-500 tests | 4-8 | Good balance of speed improvement vs agent cost |
78
- | 500-2000 tests | 8-16 | Significant time reduction |
79
- | 2000+ tests | 16-32 | Large suites benefit most; diminishing returns above 32 |
80
-
81
- The optimal value depends on test runtime distribution. Check Test Engine analytics to see if agents finish at roughly the same time — if one agent consistently takes much longer, increase parallelism or enable split-by-example.
82
-
83
- ## Custom test commands
84
-
85
- Override the default test command when the test runner needs additional flags or setup:
86
-
87
- ```yaml
88
- env:
89
- BUILDKITE_TEST_ENGINE_TEST_CMD: "bundle exec rspec --format documentation"
90
- BUILDKITE_TEST_ENGINE_RETRY_CMD: "bundle exec rspec --format documentation --only-failures"
91
- ```
92
-
93
- bktec appends the assigned test files to the command automatically.