Skip to content

[pull] canary from vercel:canary#1055

Merged
pull[bot] merged 2 commits into
code:canaryfrom
vercel:canary
May 19, 2026
Merged

[pull] canary from vercel:canary#1055
pull[bot] merged 2 commits into
code:canaryfrom
vercel:canary

Conversation

@pull
Copy link
Copy Markdown

@pull pull Bot commented May 19, 2026

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

sokra and others added 2 commits May 18, 2026 13:43
### What?

Renames the `TaskExecutionReason::Initial` variant to
`TaskExecutionReason::Root` in turbo-tasks, and updates its `as_str()`
representation from `"initial"` to `"root"`.

### Why?

The variant's doc comment already describes it as "A root task was
initially scheduled and is executed". The name `Initial` is misleading
because it suggests "first execution of any task", which overlaps
semantically with other variants like `ActivateInitial` (a task
activated for the first time with no output yet). `Root` accurately
reflects that this reason is specifically used when a root task is
scheduled, making the enum easier to read and reason about at call sites
and in traces.

### How?

- `turbopack/crates/turbo-tasks/src/task_execution_reason.rs`: rename
the enum variant `Initial` → `Root` and update the `as_str()` mapping to
return `"root"`.
- `turbopack/crates/turbo-tasks-backend/src/backend/storage_schema.rs`:
update the single construction site that used
`TaskExecutionReason::Initial` when scheduling a root task.

No behavioral changes — this is a pure rename. The other `*Initial`
variant (`ActivateInitial`) is intentionally left untouched because it
describes a different concept (first-time activation of a non-root
task).

Verified with `cargo check` and `cargo clippy` on `turbo-tasks` and
`turbo-tasks-backend`.

Closes NEXT-
Fixes #

Co-authored-by: v-work-app[bot] <262237222+v-work-app[bot]@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Tobias Koppers <sokra@users.noreply.github.com>
@pull pull Bot locked and limited conversation to collaborators May 19, 2026
@pull pull Bot added the ⤵️ pull label May 19, 2026
@pull pull Bot merged commit 9082740 into code:canary May 19, 2026
0 of 2 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant