Skip to content

Commit 7349acb

Browse files
committed
Merge remote-tracking branch 'origin/main' into feat/compute-workload-manager
2 parents bc05705 + c00dae0 commit 7349acb

File tree

244 files changed

+35130
-821
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

244 files changed

+35130
-821
lines changed

.changeset/ai-prompt-management.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@trigger.dev/sdk": patch
3+
---
4+
5+
Define and manage AI prompts with `prompts.define()`. Create typesafe prompt templates with variables, resolve them at runtime, and manage versions and overrides from the dashboard without redeploying.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"trigger.dev": patch
3+
---
4+
5+
Fix dev CLI leaking build directories on rebuild, causing disk space accumulation. Deprecated workers are now pruned (capped at 2 retained) when no active runs reference them. The watchdog process also cleans up `.trigger/tmp/` when the dev CLI is killed ungracefully (e.g. SIGKILL from pnpm).
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@trigger.dev/core": patch
3+
---
4+
5+
Fix `list_deploys` MCP tool failing when deployments have null `runtime` or `runtimeVersion` fields.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@trigger.dev/core": patch
3+
---
4+
5+
Propagate run tags to span attributes so they can be extracted server-side for LLM cost attribution metadata.

.changeset/mcp-get-span-details.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
"@trigger.dev/core": patch
3+
"trigger.dev": patch
4+
---
5+
6+
Add `get_span_details` MCP tool for inspecting individual spans within a run trace.
7+
8+
- New `get_span_details` tool returns full span attributes, timing, events, and AI enrichment (model, tokens, cost, speed)
9+
- Span IDs now shown in `get_run_details` trace output for easy discovery
10+
- New API endpoint `GET /api/v1/runs/:runId/spans/:spanId`
11+
- New `retrieveSpan()` method on the API client

.changeset/mcp-query-tools.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
"@trigger.dev/core": patch
3+
"trigger.dev": patch
4+
---
5+
6+
MCP server improvements: new tools, bug fixes, and new flags.
7+
8+
**New tools:**
9+
- `get_query_schema` — discover available TRQL tables and columns
10+
- `query` — execute TRQL queries against your data
11+
- `list_dashboards` — list built-in dashboards and their widgets
12+
- `run_dashboard_query` — execute a single dashboard widget query
13+
- `whoami` — show current profile, user, and API URL
14+
- `list_profiles` — list all configured CLI profiles
15+
- `switch_profile` — switch active profile for the MCP session
16+
- `start_dev_server` — start `trigger dev` in the background and stream output
17+
- `stop_dev_server` — stop the running dev server
18+
- `dev_server_status` — check dev server status and view recent logs
19+
20+
**New API endpoints:**
21+
- `GET /api/v1/query/schema` — query table schema discovery
22+
- `GET /api/v1/query/dashboards` — list built-in dashboards
23+
24+
**New features:**
25+
- `--readonly` flag hides write tools (`deploy`, `trigger_task`, `cancel_run`) so the AI cannot make changes
26+
- `read:query` JWT scope for query endpoint authorization
27+
- `get_run_details` trace output is now paginated with cursor support
28+
- MCP tool annotations (`readOnlyHint`, `destructiveHint`) for all tools
29+
30+
**Bug fixes:**
31+
- Fixed `search_docs` tool failing due to renamed upstream Mintlify tool (`SearchTriggerDev``search_trigger_dev`)
32+
- Fixed `list_deploys` failing when deployments have null `runtime`/`runtimeVersion` fields (#3139)
33+
- Fixed `list_preview_branches` crashing due to incorrect response shape access
34+
- Fixed `metrics` table column documented as `value` instead of `metric_value` in query docs
35+
- Fixed dev CLI leaking build directories on rebuild — deprecated workers now clean up their build dirs when their last run completes
36+
37+
**Context optimizations:**
38+
- `get_query_schema` now requires a table name and returns only one table's schema (was returning all tables)
39+
- `get_current_worker` no longer inlines payload schemas; use new `get_task_schema` tool instead
40+
- Query results formatted as text tables instead of JSON (~50% fewer tokens)
41+
- `cancel_run`, `list_deploys`, `list_preview_branches` formatted as text instead of raw JSON
42+
- Schema and dashboard API responses cached to avoid redundant fetches

.changeset/tame-oranges-change.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
"@trigger.dev/redis-worker": patch
3+
"@trigger.dev/sdk": patch
4+
"trigger.dev": patch
5+
"@trigger.dev/core": patch
6+
---
7+
8+
Adapted the CLI API client to propagate the trigger source via http headers.

.github/VOUCHED.td

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,8 @@ samejr
1313
isshaddad
1414
# Outside contributors
1515
gautamsi
16-
capaj
16+
capaj
17+
chengzp
18+
bharathkumar39293
19+
bhekanik
20+
jrossi

.github/workflows/vouch-check-pr.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ permissions:
1010
issues: read
1111

1212
jobs:
13-
check-pr:
13+
check-vouch:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- uses: mitchellh/vouch/action/check-pr@c6d80ead49839655b61b422700b7a3bc9d0804a9 # v1.4.2
@@ -20,3 +20,25 @@ jobs:
2020
require-vouch: true
2121
env:
2222
GH_TOKEN: ${{ github.token }}
23+
24+
require-draft:
25+
needs: check-vouch
26+
if: >
27+
github.event.pull_request.draft == false &&
28+
github.event.pull_request.author_association != 'MEMBER' &&
29+
github.event.pull_request.author_association != 'OWNER' &&
30+
github.event.pull_request.author_association != 'COLLABORATOR'
31+
runs-on: ubuntu-latest
32+
steps:
33+
- name: Close non-draft PR
34+
env:
35+
GH_TOKEN: ${{ github.token }}
36+
run: |
37+
STATE=$(gh pr view ${{ github.event.pull_request.number }} --repo ${{ github.repository }} --json state -q '.state')
38+
if [ "$STATE" != "OPEN" ]; then
39+
echo "PR is already closed, skipping."
40+
exit 0
41+
fi
42+
gh pr close ${{ github.event.pull_request.number }} \
43+
--repo ${{ github.repository }} \
44+
--comment "Thanks for your contribution! We require all external PRs to be opened in **draft** status first so you can address CodeRabbit review comments and ensure CI passes before requesting a review. Please re-open this PR as a draft. See [CONTRIBUTING.md](https://github.com/${{ github.repository }}/blob/main/CONTRIBUTING.md#pr-workflow) for details."
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
---
2+
area: webapp
3+
type: feature
4+
---
5+
6+
AI prompt management dashboard and enhanced span inspectors.
7+
8+
**Prompt management:**
9+
- Prompts list page with version status, model, override indicators, and 24h usage sparklines
10+
- Prompt detail page with template viewer, variable preview, version history timeline, and override editor
11+
- Create, edit, and remove overrides to change prompt content or model without redeploying
12+
- Promote any code-deployed version to current
13+
- Generations tab with infinite scroll, live polling, and inline span inspector
14+
- Per-prompt metrics: total generations, avg tokens, avg cost, latency, with version-level breakdowns
15+
16+
**AI span inspectors:**
17+
- Custom inspectors for `ai.generateText`, `ai.streamText`, `ai.generateObject`, `ai.streamObject` parent spans
18+
- `ai.toolCall` inspector showing tool name, call ID, and input arguments
19+
- `ai.embed` inspector showing model, provider, and input text
20+
- Prompt tab on AI spans linking to prompt version with template and input variables
21+
- Compact timestamp and duration header on all AI span inspectors
22+
23+
**AI metrics dashboard:**
24+
- Operations, Providers, and Prompts filters on the AI Metrics dashboard
25+
- Cost by prompt widget
26+
- "AI" section in the sidebar with Prompts and AI Metrics links
27+
28+
**Other improvements:**
29+
- Resizable panel sizes now persist across page refreshes
30+
- Fixed `<div>` inside `<p>` DOM nesting warnings in span titles and chat messages

0 commit comments

Comments
 (0)