Skip to content

Commit 2b550e3

Browse files
committed
fixup! fix(material/schematics): gracefully skip broken css files
1 parent 34323ff commit 2b550e3

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

src/material/schematics/ng-generate/mdc-migration/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ jasmine_node_test(
9191
"//src/material/schematics:collection_assets",
9292
"//src/material/schematics:ng_generate_assets",
9393
],
94+
shard_count = 10,
9495
deps = [
9596
":unit_tests_bundle",
9697
# Runtime dependencies needed by the test and actual migration sources. These need

src/material/schematics/ng-generate/mdc-migration/rules/theming-styles.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ export class ThemingStylesMigration extends Migration<ComponentMigrator[], Schem
4040
try {
4141
return processor.process(styles, {syntax: scss}).toString();
4242
} catch (e) {
43-
console.warn(`Failed to process stylesheet: `, filename);
43+
console.error(e);
44+
console.warn(`Failed to process stylesheet: ${filename} (see error above).`);
4445
return styles;
4546
}
4647
}

src/material/schematics/ng-update/migrations/legacy-components-v15/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ export class LegacyComponentsMigration extends Migration<null> {
4040
try {
4141
processor.process(stylesheet.content, {syntax: scss}).sync();
4242
} catch (e) {
43-
console.warn(`Failed to process stylesheet: `, stylesheet.filePath);
43+
console.error(e);
44+
console.warn(`Failed to process stylesheet: ${stylesheet.filePath} (see error above).`);
4445
}
4546
}
4647

0 commit comments

Comments
 (0)