Commit e1ca02e
committed
fix(sdk): drop triggerAndSubscribe from TriggerClient surface
`triggerAndSubscribe_internal` requires `taskContext.ctx` and uses
`ctx.run.id` as the parent run id, so it is fundamentally an
inside-task primitive. Including it on the curated `tasksApi` was a
mistake — with the default `inheritContext: false`, the scoped
taskContext is masked to undefined and the method always throws
"triggerAndSubscribe can only be used from inside a task.run()".
Type test updated to assert the method is no longer reachable from
the instance surface.1 parent 8a8fb97 commit e1ca02e
2 files changed
Lines changed: 5 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 17 | + | |
22 | 18 | | |
23 | 19 | | |
24 | 20 | | |
25 | 21 | | |
26 | 22 | | |
27 | 23 | | |
28 | | - | |
| 24 | + | |
29 | 25 | | |
30 | 26 | | |
31 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
| 55 | + | |
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
| |||
0 commit comments