Skip to content

Component level CSS optimization error - Invalid version: "TP"  #21700

@zackschuster

Description

@zackschuster

Which @angular/* package(s) are the source of the bug?

compiler

Is this a regression?

Yes

Description

see title. this occurs for all css, whether inlined using styles or referenced via styleUrls, and occurs for scss compilation as well. global css compiles fine.

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw

Error: [REDACTED].scss from Css Minimizer
Error: Transform failed with 1 error:
error: Invalid version: "TP"
    at failureErrorWithLog (/Users/zschuster/Source/SARC_V2_Client/node_modules/esbuild/lib/main.js:1451:15)
    at /Users/zschuster/Source/SARC_V2_Client/node_modules/esbuild/lib/main.js:1262:29
    at /Users/zschuster/Source/SARC_V2_Client/node_modules/esbuild/lib/main.js:609:9
    at handleIncomingPacket (/Users/zschuster/Source/SARC_V2_Client/node_modules/esbuild/lib/main.js:706:9)
    at Socket.readFromStdout (/Users/zschuster/Source/SARC_V2_Client/node_modules/esbuild/lib/main.js:576:7)
    at Socket.emit (node:events:394:28)
    at addChunk (node:internal/streams/readable:312:12)
    at readableAddChunk (node:internal/streams/readable:287:9)
    at Socket.Readable.push (node:internal/streams/readable:226:10)
    at Pipe.onStreamRead (node:internal/stream_base_commons:190:23)

Please provide the environment you discovered this bug in

Angular CLI: 12.2.3
Node: 14.17.4
Package Manager: npm 7.20.3
OS: darwin x64

Angular: 12.2.3
... animations, cdk, cli, common, compiler, compiler-cli, core
... forms, material, platform-browser, platform-browser-dynamic
... router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1202.3
@angular-devkit/build-angular   12.2.3
@angular-devkit/core            12.2.3
@angular-devkit/schematics      12.2.3
@schematics/angular             12.2.3
rxjs                            7.3.0
typescript                      4.3.5

Anything else?

this appears to be a bug in esbuild browser version detection

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions