Unverified Commit 3ae6e1c9 authored by Donny/강동윤's avatar Donny/강동윤 Committed by GitHub

feat(turbopack): Print error message for `next/font` fetching failure (#64008)

### What?

Print an error message to stdout if stylesheet fetching fails.

### Why?

To align behavior with the default mode. This PR fixes one integration
test case.

### How?



Closes PACK-2896
parent adccea6f
...@@ -237,7 +237,13 @@ impl NextFontGoogleCssModuleReplacer { ...@@ -237,7 +237,13 @@ impl NextFontGoogleCssModuleReplacer {
.await? .await?
.clone_value(), .clone_value(),
), ),
None => None, None => {
println!(
"Failed to download `{}` from Google Fonts. Using fallback font instead.",
options.await?.font_family
);
None
}
}; };
let css_asset = VirtualSource::new( let css_asset = VirtualSource::new(
......
...@@ -6543,10 +6543,10 @@ ...@@ -6543,10 +6543,10 @@
"runtimeError": false "runtimeError": false
}, },
"test/e2e/next-font/google-fetch-error.test.ts": { "test/e2e/next-font/google-fetch-error.test.ts": {
"passed": [], "passed": [
"failed": [
"next/font/google fetch error should use a fallback font in dev" "next/font/google fetch error should use a fallback font in dev"
], ],
"failed": [],
"pending": [], "pending": [],
"flakey": [], "flakey": [],
"runtimeError": false "runtimeError": false
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment