Skip to content

fix(turbopack): keep the original sourcemap of styles after source transform #79700

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: canary
Choose a base branch
from

Conversation

xusd320
Copy link
Contributor

@xusd320 xusd320 commented May 27, 2025

Why

The original sourcemap be lost after source transform. For example, axyz.sass file processed by sass-loader, return a xyz.sass.css, the output css chunk only contains the sourcemap of xyz.sass.css produced by lightningcss, xyz.sass associated sourcemap been lost.

How

Extend lightningcss generated sourcemap with the original sourcemap, see:
https://github.com/parcel-bundler/lightningcss/blob/f2dc67c4d3fe92f26693c02366db1e60cae0db27/napi/src/lib.rs#L776

Related issue

umijs/mako#1915

@ijjk ijjk added the Turbopack Related to Turbopack with Next.js. label May 27, 2025
Copy link

changeset-bot bot commented May 27, 2025

⚠️ No Changeset found

Latest commit: 15b323e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ijjk
Copy link
Member

ijjk commented May 27, 2025

Allow CI Workflow Run

  • approve CI run for commit: 15b323e

Note: this should only be enabled once the PR is ready to go and can only be enabled by a maintainer

@xusd320 xusd320 force-pushed the fix/upstream-css-sourcemap-after-transform branch from 40fc7e3 to 9d5acfb Compare May 28, 2025 02:30
@xusd320 xusd320 changed the title fix(turbopack): keep the original sourcemap after source transform fix(turbopack): keep the original sourcemap of styles after source transform May 28, 2025
@bgw
Copy link
Member

bgw commented May 29, 2025

What do you think about propagating the errors?

Because the webpack loaders are user-provided, probably the best solution here is to assume they're not guaranteed to be correct and emit some sort of non-fatal diagnostic or issue collectible of some sort, falling back to None like you're doing.

But I also think it's close enough to just assume webpack loaders emit correct source maps unless we find evidence to the contrary.

diff --git a/turbopack/crates/turbopack-css/src/process.rs b/turbopack/crates/turbopack-css/src/process.rs
index 051b30b3eb..8abee18589 100644
--- a/turbopack/crates/turbopack-css/src/process.rs
+++ b/turbopack/crates/turbopack-css/src/process.rs
@@ -96,7 +96,7 @@ impl StyleSheetLike<'_, '_> {
             debug_assert_eq!(ss.sources.len(), 1);

             if let Some(origin_source_map) = origin_source_map.as_mut() {
-                let _ = srcmap.extends(origin_source_map);
+                srcmap.extends(origin_source_map)?;
             } else {
                 srcmap.add_sources(ss.sources.clone());
                 srcmap.set_source_content(0, code)?;
@@ -266,17 +266,11 @@ pub async fn finalize_css(
                 _ => bail!("this case should be filtered out while parsing"),
             };

-            let origin_source_map = origin_source_map.await?.as_ref().map(|rope| rope.clone());
-
-            let origin_source_map = origin_source_map.as_ref().and_then(|rope| {
-                rope.to_str().ok().and_then(|cow| {
-                    if cow.is_empty() {
-                        None
-                    } else {
-                        parcel_sourcemap::SourceMap::from_json("", &cow).ok()
-                    }
-                })
-            });
+            let origin_source_map = if let Some(rope) = &*origin_source_map.await? {
+                Some(parcel_sourcemap::SourceMap::from_json("", &rope.to_str()?)?)
+            } else {
+                None
+            };

             let (result, srcmap) =
                 stylesheet.to_css(&code, minify_type, true, true, origin_source_map)?;

@ijjk
Copy link
Member

ijjk commented May 29, 2025

Failing test suites

Commit: b2372e3

pnpm test-dev test/e2e/app-dir/app-basepath/index.test.ts

  • app dir - basepath > should successfully hard navigate from pages -> app
Expand output

● app dir - basepath › should successfully hard navigate from pages -> app

page.waitForSelector: Timeout 10000ms exceeded.
Call log:
  - waiting for locator('#page-2')

  454 |   waitForElementByCss(selector: string, timeout = 10_000) {
  455 |     return this.startChain(async () => {
> 456 |       const el = await page.waitForSelector(selector, {
      |                             ^
  457 |         timeout,
  458 |         state: 'attached',
  459 |       })

  at waitForSelector (lib/browsers/playwright.ts:456:29)
  at Playwright._chain (lib/browsers/playwright.ts:568:23)
  at Playwright._chain [as startChain] (lib/browsers/playwright.ts:549:17)
  at Playwright.startChain [as waitForElementByCss] (lib/browsers/playwright.ts:455:17)
  at Object.waitForElementByCss (e2e/app-dir/app-basepath/index.test.ts:16:19)

Read more about building and testing Next.js in contributing.md.

__NEXT_EXPERIMENTAL_PPR=true pnpm test-dev test/e2e/socket-io/index.test.ts (PPR)

  • socket-io > should support socket.io without falling back to polling
Expand output

● socket-io › should support socket.io without falling back to polling

TIMED OUT: /hello world/



undefined

  736 |
  737 |   if (hardError) {
> 738 |     throw new Error('TIMED OUT: ' + regex + '\n\n' + content + '\n\n' + lastErr)
      |           ^
  739 |   }
  740 |   return false
  741 | }

  at check (lib/next-test-utils.ts:738:11)
  at Object.<anonymous> (e2e/socket-io/index.test.ts:34:5)

Read more about building and testing Next.js in contributing.md.

pnpm test-start test/e2e/app-dir/rsc-basic/rsc-basic.test.ts

  • app dir - rsc basics > should correctly render page returning null
  • app dir - rsc basics > should correctly render component returning null
  • app dir - rsc basics > should correctly render layout returning null
  • app dir - rsc basics > should correctly render page returning undefined
  • app dir - rsc basics > should correctly render component returning undefined
  • app dir - rsc basics > should correctly render layout returning undefined
  • app dir - rsc basics > should handle named client components imported as page
  • app dir - rsc basics > should handle client components imported as namespace
  • app dir - rsc basics > should render server components correctly
  • app dir - rsc basics > should reuse the inline flight response without sending extra requests
  • app dir - rsc basics > should support multi-level server component imports
  • app dir - rsc basics > should create client reference successfully for all file conventions
  • app dir - rsc basics > should be able to navigate between rsc routes
  • app dir - rsc basics > should handle streaming server components correctly
  • app dir - rsc basics > should track client components in dynamic imports
  • app dir - rsc basics > should support next/link in server components
  • app dir - rsc basics > should link correctly with next/link without mpa navigation to the page
  • app dir - rsc basics > should escape streaming data correctly
  • app dir - rsc basics > should render built-in 404 page for missing route if pagesDir is not presented
  • app dir - rsc basics > should suspense next/legacy/image in server components
  • app dir - rsc basics > should suspense next/image in server components
  • app dir - rsc basics > should handle various kinds of exports correctly
  • app dir - rsc basics > should support native modules in server component
  • app dir - rsc basics > should resolve different kinds of components correctly
  • app dir - rsc basics > should stick to the url without trailing /page suffix
  • app dir - rsc basics > should support streaming for flight response
  • app dir - rsc basics > should support partial hydration with inlined server data
  • app dir - rsc basics > should not apply rsc syntax checks in pages/api
  • app dir - rsc basics > should not use bundled react for pages with app
  • app dir - rsc basics > should use canary react for app
  • app dir - rsc basics > should be able to call legacy react-dom/server APIs in client components
  • app dir - rsc basics > should generate edge SSR manifests for Node.js
  • app dir - rsc basics > client references with TLA (edge) > should support TLA in sync client reference imports
  • app dir - rsc basics > client references with TLA (edge) > should support TLA in lazy client reference
  • app dir - rsc basics > client references with TLA (node) > should support TLA in sync client reference imports
  • app dir - rsc basics > client references with TLA (node) > should support TLA in lazy client reference
  • app dir - rsc basics > next internal shared context > should not error if just load next/navigation module in pages/api
  • app dir - rsc basics > next internal shared context > should not error if just load next/router module in app page
Expand output

● app dir - rsc basics › next internal shared context › should not error if just load next/navigation module in pages/api

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › next internal shared context › should not error if just load next/router module in app page

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render page returning null

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render component returning null

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render layout returning null

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render page returning undefined

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render component returning undefined

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should correctly render layout returning undefined

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should handle named client components imported as page

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should handle client components imported as namespace

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should render server components correctly

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should reuse the inline flight response without sending extra requests

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support multi-level server component imports

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should create client reference successfully for all file conventions

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should be able to navigate between rsc routes

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should handle streaming server components correctly

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should track client components in dynamic imports

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › client references with TLA (node) › should support TLA in sync client reference imports

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › client references with TLA (node) › should support TLA in lazy client reference

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › client references with TLA (edge) › should support TLA in sync client reference imports

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › client references with TLA (edge) › should support TLA in lazy client reference

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support next/link in server components

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should link correctly with next/link without mpa navigation to the page

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should escape streaming data correctly

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should render built-in 404 page for missing route if pagesDir is not presented

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should suspense next/legacy/image in server components

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should suspense next/image in server components

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should handle various kinds of exports correctly

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support native modules in server component

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should resolve different kinds of components correctly

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should stick to the url without trailing /page suffix

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support streaming for flight response

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support partial hydration with inlined server data

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should not apply rsc syntax checks in pages/api

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should not use bundled react for pages with app

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should use canary react for app

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should be able to call legacy react-dom/server APIs in client components

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should support partial hydration with inlined server data in browser

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

● app dir - rsc basics › should generate edge SSR manifests for Node.js

next build failed with code/signal 1

  106 |           if (code || signal)
  107 |             reject(
> 108 |               new Error(`next build failed with code/signal ${code || signal}`)
      |               ^
  109 |             )
  110 |           else resolve()
  111 |         })

  at ChildProcess.<anonymous> (lib/next-modes/next-start.ts:108:15)

Read more about building and testing Next.js in contributing.md.

pnpm test-dev test/e2e/app-dir/actions/app-action.test.ts

  • app-dir action handling > should forward action request to a worker that contains the action handler (node)
Expand output

● app-dir action handling › should forward action request to a worker that contains the action handler (node)

page.waitForSelector: Timeout 10000ms exceeded.
Call log:
  - waiting for locator('#other-page')

  454 |   waitForElementByCss(selector: string, timeout = 10_000) {
  455 |     return this.startChain(async () => {
> 456 |       const el = await page.waitForSelector(selector, {
      |                             ^
  457 |         timeout,
  458 |         state: 'attached',
  459 |       })

  at waitForSelector (lib/browsers/playwright.ts:456:29)
  at e2e/app-dir/actions/app-action.test.ts:908:7
  at Proxy._chain (lib/browsers/playwright.ts:568:23)
  at Proxy._chain (lib/browsers/playwright.ts:549:17)
  at Proxy.startChain (lib/browsers/playwright.ts:455:17)
  at waitForElementByCss (e2e/app-dir/actions/app-action.test.ts:911:10)

Read more about building and testing Next.js in contributing.md.

@xusd320
Copy link
Contributor Author

xusd320 commented May 29, 2025

@bgw I thought about propagating the errors before, choosing to fallback to None because that the soucemap correctness may not be a fatal point, it's for user experience. With falling back to None when error occurred in webpack loaders, the sourcemap generated by lightningcss will be used still.

@xusd320 xusd320 force-pushed the fix/upstream-css-sourcemap-after-transform branch from 9d5acfb to e607852 Compare May 29, 2025 07:04
@xusd320 xusd320 force-pushed the fix/upstream-css-sourcemap-after-transform branch from e607852 to ea60c2a Compare May 29, 2025 07:05
Copy link

codspeed-hq bot commented May 29, 2025

CodSpeed Performance Report

Merging #79700 will not alter performance

Comparing umijs:fix/upstream-css-sourcemap-after-transform (b2372e3) with canary (cc3c42f)

Summary

✅ 108 untouched benchmarks
⁉️ 9 dropped benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/date-fns-all 2.7 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/date-fns-single 1.6 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/framer-motion-all 3.8 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/framer-motion-single 2.6 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/joy 2.5 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/lucide-react-all 12.5 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/lucide-react-single 1 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/mui 3.7 s N/A N/A
⁉️ /home/runner/work/next.js/next.js/turbopack/benchmark-apps/shiki 6.9 s N/A N/A

@ijjk ijjk added the tests label May 29, 2025
@xusd320
Copy link
Contributor Author

xusd320 commented May 29, 2025

Snapshots updated , and removed redundant clone and add some comments.

@xusd320
Copy link
Contributor Author

xusd320 commented May 29, 2025

Sorry, change my mind, propagating the errors is better, which can help webpack loader's maintainer being aware of sourcemap corruption.

@xusd320 xusd320 closed this May 29, 2025
@xusd320 xusd320 deleted the fix/upstream-css-sourcemap-after-transform branch May 29, 2025 15:07
@xusd320 xusd320 restored the fix/upstream-css-sourcemap-after-transform branch May 29, 2025 17:09
@xusd320 xusd320 reopened this May 29, 2025
@xusd320 xusd320 force-pushed the fix/upstream-css-sourcemap-after-transform branch 2 times, most recently from 105ba66 to 3d57b72 Compare May 30, 2025 07:08
@bgw bgw enabled auto-merge (squash) May 30, 2025 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests Turbopack Related to Turbopack with Next.js.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants