Skip to content

Commit

Permalink
Revert "update turbopack (#50819)"
Browse files Browse the repository at this point in the history
This reverts commit 0d46361.
  • Loading branch information
ijjk authored Jun 8, 2023
1 parent 0d46361 commit 9cec603
Show file tree
Hide file tree
Showing 9 changed files with 86 additions and 95 deletions.
115 changes: 52 additions & 63 deletions Cargo.lock

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@ next-transform-strip-page-exports = { path = "packages/next-swc/crates/next-tran

# SWC crates
# Keep consistent with preset_env_base through swc_core
swc_core = { version = "0.76.41" }
swc_core = { version = "0.76.37" }
testing = { version = "0.33.13" }

# Turbo crates
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230608.1" }
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230601.3" }
# [TODO]: need to refactor embed_directory! macro usages, as well as resolving turbo_tasks::function, macros..
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230608.1" }
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230601.3" }
# [TODO]: need to refactor embed_directory! macro usage in next-core
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230608.1" }
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230601.3" }

# General Deps

Expand Down
4 changes: 2 additions & 2 deletions packages/next-swc/crates/next-core/js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"check": "tsc --noEmit"
},
"dependencies": {
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-230608.1",
"@vercel/turbopack-node": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-node/js?turbopack-230608.1",
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-230601.3",
"@vercel/turbopack-node": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-node/js?turbopack-230601.3",
"anser": "^2.1.1",
"css.escape": "^1.5.1",
"next": "*",
Expand Down
4 changes: 0 additions & 4 deletions packages/next-swc/crates/next-core/src/app_source.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ use turbopack_binding::{
},
env::ProcessEnvAssetVc,
node::{
debug::should_debug,
execution_context::ExecutionContextVc,
render::{
node_api_source::create_node_api_source,
Expand Down Expand Up @@ -588,7 +587,6 @@ async fn create_app_page_source_for_route(
.into(),
fallback_page,
render_data,
should_debug("app_source"),
);

Ok(source.issue_context(app_dir, &format!("Next.js App Page Route {pathname}")))
Expand Down Expand Up @@ -632,7 +630,6 @@ async fn create_app_not_found_page_source(
.into(),
fallback_page,
render_data,
should_debug("app_source"),
);

Ok(source.issue_context(app_dir, "Next.js App Page Route /404"))
Expand Down Expand Up @@ -676,7 +673,6 @@ async fn create_app_route_source_for_route(
.cell()
.into(),
render_data,
should_debug("app_source"),
);

Ok(source.issue_context(app_dir, &format!("Next.js App Route {pathname}")))
Expand Down
3 changes: 1 addition & 2 deletions packages/next-swc/crates/next-core/src/next_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ use turbopack_binding::{
styled_components::StyledComponentsTransformConfig,
},
node::{
debug::should_debug,
evaluate::evaluate,
execution_context::{ExecutionContext, ExecutionContextVc},
transforms::webpack::{WebpackLoaderItem, WebpackLoaderItemsVc},
Expand Down Expand Up @@ -689,7 +688,7 @@ pub async fn load_next_config_internal(
None,
vec![],
config_changed,
should_debug("next_config"),
/* debug */ false,
)
.await?;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ async fn get_mock_stylesheet(
ecmascript::{
EcmascriptInputTransformsVc, EcmascriptModuleAssetType, EcmascriptModuleAssetVc,
},
node::{debug::should_debug, evaluate::evaluate, execution_context::ExecutionContext},
node::{evaluate::evaluate, execution_context::ExecutionContext},
turbopack::evaluate_context::node_evaluate_asset_context,
},
};
Expand Down Expand Up @@ -473,7 +473,7 @@ async fn get_mock_stylesheet(
None,
vec![],
CompletionVc::immutable(),
should_debug("next_font::google"),
/* debug */ false,
)
.await?;

Expand Down
5 changes: 0 additions & 5 deletions packages/next-swc/crates/next-core/src/page_source.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ use turbopack_binding::{
},
env::ProcessEnvAssetVc,
node::{
debug::should_debug,
execution_context::ExecutionContextVc,
render::{
node_api_source::create_node_api_source,
Expand Down Expand Up @@ -423,7 +422,6 @@ async fn create_page_source_for_file(
.cell()
.into(),
render_data,
should_debug("page_source"),
)
} else {
let data_pathname = pathname_for_path(client_root, client_path, PathType::Data);
Expand Down Expand Up @@ -467,7 +465,6 @@ async fn create_page_source_for_file(
ssr_entry,
fallback_page,
render_data,
should_debug("page_source"),
),
create_node_rendered_source(
project_path,
Expand All @@ -479,7 +476,6 @@ async fn create_page_source_for_file(
ssr_data_entry,
fallback_page,
render_data,
should_debug("page_source"),
),
create_page_loader(
client_root,
Expand Down Expand Up @@ -595,7 +591,6 @@ async fn create_not_found_page_source(
ssr_entry,
fallback_page,
render_data,
should_debug("page_source"),
),
page_loader,
])
Expand Down
3 changes: 1 addition & 2 deletions packages/next-swc/crates/next-core/src/router.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ use turbopack_binding::{
},
dev::DevChunkingContextVc,
node::{
debug::should_debug,
evaluate::evaluate,
execution_context::{ExecutionContext, ExecutionContextVc},
source_map::{trace_stack, StructuredError},
Expand Down Expand Up @@ -377,7 +376,7 @@ async fn route_internal(
JsonValueVc::cell(serde_json::to_value(ServerInfo::try_from(&*server_addr)?)?),
],
CompletionsVc::all(vec![next_config_changed, routes_changed]),
should_debug("router"),
/* debug */ false,
)
.await?;

Expand Down
35 changes: 24 additions & 11 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 9cec603

Please sign in to comment.