Commit 4b5e013
Use in_progress workflow_job example, not queued (#22880)
* Use in_progress workflow_job example, not queued
### tl;dr
This changes the example `workflow_job` payload to be an `in_progress` event instead of `queued` event.
### why
In #22174, I added some keys to the example workflow_job json. This was correct, but by adding non-null _values_, **I introduced a subtle bug**.
It's a bug because a `queued` workflow is—by definition—_not_ yet assigned to a runner. So all the `runner_*` attributes will be `null` in the real world.
After the workflow becomes `in_progress`, all the values are guaranteed to exist. So let's change the example to be an `in_progress` event, since it's a better example for documentation.
* Explain more about the runner_* attributes in "workflow_job_properties.md"
* Consistentize naming
Co-authored-by: Martin Lopes <martin389@github.com>
Co-authored-by: hubwriter <hubwriter@github.com>1 parent 04bd69e commit 4b5e013
2 files changed
Lines changed: 16 additions & 3 deletions
File tree
- data/reusables/webhooks
- lib/webhooks/static/dotcom
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
18 | 25 | | |
19 | 26 | | |
20 | 27 | | |
| |||
0 commit comments