Skip to content

Commit

Permalink
Local task resolution
Browse files Browse the repository at this point in the history
  • Loading branch information
bgw committed Aug 22, 2024
1 parent 6381877 commit 5f7cee9
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 20 deletions.
1 change: 1 addition & 0 deletions turbopack/crates/turbo-tasks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ bench = false
default = []
tokio_tracing = ["tokio/tracing"]
hanging_detection = []
local_resolution = []

[lints]
workspace = true
Expand Down
65 changes: 45 additions & 20 deletions turbopack/crates/turbo-tasks/src/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,7 @@ impl CurrentGlobalTaskState {
fn create_local_task(

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rustdoc check / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rust check / build

method `create_local_task` is never used

Check failure on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rust check / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / build-native / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / build / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo benches / Test

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo benches / Test

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test unit (18) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test unit (20) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - aarch64-unknown-linux-gnu - node@16

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-unknown-linux-gnu - node@16

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo unit / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test next-swc wasm / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Run devlow benchmarks (--turbopack=false, --scenario=heavy-npm-deps --page=homepage) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / types and precompiled / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Run devlow benchmarks (--turbopack=true, --scenario=heavy-npm-deps --page=homepage) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr integration / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / lint / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (2/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (5/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test firefox and safari / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (4/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (3/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (1/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (2/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (3/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (1/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (5/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (6/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (3/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (2/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (11/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (1/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (4/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (9/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (10/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (3/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (1/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (8/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (4/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (2/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (7/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (12/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (3/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (4/12) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (5/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (2/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (5/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (4/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (5/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (1/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (4/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (3/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (5/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (2/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (1/5) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (2/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (1/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (3/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (4/4) / build

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-pc-windows-msvc - node@16

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - aarch64-apple-darwin - node@16

method `create_local_task` is never used

Check warning on line 439 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-apple-darwin - node@16

method `create_local_task` is never used
&mut self,
ty: CachedTaskType,
// if this is a `CachedTaskType::Resolve*`, we'll spawn another task with this persistence
persistence: TaskPersistence,
) -> LocalTaskId {
self.local_tasks
Expand Down Expand Up @@ -475,7 +476,7 @@ struct CurrentLocalTaskState {
local_task_id: Option<LocalTaskId>,

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rustdoc check / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rust check / build

field `local_task_id` is never read

Check failure on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / rust check / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / build-native / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / build / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo benches / Test

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo benches / Test

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test unit (18) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test unit (20) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - aarch64-unknown-linux-gnu - node@16

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-unknown-linux-gnu - node@16

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test cargo unit / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test next-swc wasm / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Run devlow benchmarks (--turbopack=false, --scenario=heavy-npm-deps --page=homepage) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / types and precompiled / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Run devlow benchmarks (--turbopack=true, --scenario=heavy-npm-deps --page=homepage) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr integration / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (prod) (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests for flakes (dev) (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / lint / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (2/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (5/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test firefox and safari / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (4/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (3/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack development integration (1/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (2/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (3/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (1/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (5/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (6/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (3/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (2/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (11/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (1/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (4/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (9/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (10/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (3/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (1/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (8/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (4/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (2/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (7/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (12/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (3/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test integration (4/12) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (5/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (2/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (5/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr dev (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production integration (4/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack dev (5/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test dev (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test turbopack production (1/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (4/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (3/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (5/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (2/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test prod (1/5) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / test ppr prod (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (2/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (1/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (3/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / Test new tests when deployed (4/4) / build

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-pc-windows-msvc - node@16

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - aarch64-apple-darwin - node@16

field `local_task_id` is never read

Check warning on line 476 in turbopack/crates/turbo-tasks/src/manager.rs

View workflow job for this annotation

GitHub Actions / stable - x86_64-apple-darwin - node@16

field `local_task_id` is never read

/// A unique identifier created for each unique[`CurrentLocalTaskState`]. Used to check that
/// [`CurrentTaskState::local_cells`] are valid for the current [`RawVc::LocalCell`].
/// [`CurrentTaskState::local_cells`] are valid for the currant [`RawVc::LocalCell`].
execution_id: ExecutionId,

/// The function's metadata if this is a persistent task. Contains information about arguments
Expand Down Expand Up @@ -678,28 +679,32 @@ impl<B: Backend + 'static> TurboTasks<B> {
if registry::get_function(func).arg_meta.is_resolved(&*arg) {
return self.native_call(func, arg, persistence);
}
let task_type = CachedTaskType::ResolveNative {
fn_type: func,
this: None,
arg,
};
#[cfg(feature = "local_resolution")]
return CURRENT_GLOBAL_TASK_STATE.with(move |gts| {
let mut gts_write = gts.write().unwrap();
let local_task_id = gts_write.create_local_task(task_type, persistence);
RawVc::LocalOutput(gts_write.task_id, local_task_id)
});
#[cfg(not(feature = "local_resolution"))]
match persistence {
TaskPersistence::LocalCells => {
todo!("bgw: local tasks");
}
TaskPersistence::Transient => {
RawVc::TaskOutput(self.backend.get_or_create_transient_task(
CachedTaskType::ResolveNative {
fn_type: func,
this: None,
arg,
},
task_type,
current_task("turbo_function calls"),
self,
))
}
TaskPersistence::Persistent => {
RawVc::TaskOutput(self.backend.get_or_create_persistent_task(
CachedTaskType::ResolveNative {
fn_type: func,
this: None,
arg,
},
task_type,
current_task("turbo_function calls"),
self,
))
Expand All @@ -722,7 +727,14 @@ impl<B: Backend + 'static> TurboTasks<B> {
this: Some(this),
arg,
};
match persistence {
#[cfg(feature = "local_resolution")]
return CURRENT_GLOBAL_TASK_STATE.with(move |gts| {
let mut gts_write = gts.write().unwrap();
let local_task_id = gts_write.create_local_task(task_type, persistence);
RawVc::LocalOutput(gts_write.task_id, local_task_id)
});
#[cfg(not(feature = "local_resolution"))]
return match persistence {
TaskPersistence::LocalCells => {
todo!("bgw: local tasks");
}
Expand All @@ -740,7 +752,7 @@ impl<B: Backend + 'static> TurboTasks<B> {
self,
))
}
}
};
}

pub fn trait_call(
Expand Down Expand Up @@ -772,7 +784,15 @@ impl<B: Backend + 'static> TurboTasks<B> {
this,
arg,
};
match persistence {

#[cfg(feature = "local_resolution")]
return CURRENT_GLOBAL_TASK_STATE.with(move |gts| {
let mut gts_write = gts.write().unwrap();
let local_task_id = gts_write.create_local_task(task_type, persistence);
RawVc::LocalOutput(gts_write.task_id, local_task_id)
});
#[cfg(not(feature = "local_resolution"))]
return match persistence {
TaskPersistence::LocalCells => {
todo!("bgw: local tasks");
}
Expand All @@ -790,7 +810,7 @@ impl<B: Backend + 'static> TurboTasks<B> {
self,
))
}
}
};
}

#[track_caller]
Expand Down Expand Up @@ -2165,12 +2185,17 @@ pub(crate) fn read_local_cell(
}

pub(crate) async fn read_local_output(
_this: &dyn TurboTasksApi,
_task_id: TaskId,
_local_output_id: LocalTaskId,
_consistency: ReadConsistency,
this: &dyn TurboTasksApi,
parent_task_id: TaskId,
local_task_id: LocalTaskId,
consistency: ReadConsistency,
) -> Result<RawVc> {
todo!("bgw: local outputs");
loop {
match this.try_read_local_output(parent_task_id, local_task_id, consistency)? {
Ok(raw_vc) => return Ok(raw_vc),
Err(event_listener) => event_listener.await,
}
}
}

/// Panics if the [`ExecutionId`] does not match the current task's
Expand Down

0 comments on commit 5f7cee9

Please sign in to comment.