tailwind-bundle icon indicating copy to clipboard operation
tailwind-bundle copied to clipboard

bun crashes when doing tailwind:build on old CPUs

Open sebastian0119 opened this issue 1 year ago • 1 comments

Hi there.

I recently ran php bin/console tailwind:build on an old Intel(R) Core(TM)2 Duo CPU, E7200, @ 2.53GHz, and got a critical error:

! [NOTE] Executing Tailwind (pass -v to see more details).

============================================================
Bun v1.1.43 (76800b04) Linux x64 (baseline)
Linux Kernel v6.8.0 | glibc v2.39
Args:
Features: no_avx2 no_avx
Elapsed: 0ms | User: 0ms | Sys: 2ms
RSS: 0B  | Peak: 55.12MB | Commit: 0B  | Faults: 0

CPU lacks AVX support. Please consider upgrading to a newer CPU.
panic: Illegal instruction at address 0x3E1E803
oh no: Bun has crashed. This indicates a bug in Bun, not your code.

{"message":"Error thrown while running command \"tailwind:build --minify\". Message: \"The process has been signaled with signal \"4\".\"","context":{"exception":{"class":"Symfony\\Component\\Process\\Exception\\ProcessSignaledException","message":"The process has been signaled with signal \"4\".","code":0,"file":"/var/www/betasym/vendor/symfony/process/Process.php:462"},"command":"tailwind:build --minify","message":"The process has been signaled with signal \"4\"."},"level":500,"level_name":"CRITICAL","channel":"console","datetime":"2025-02-12T15:23:58.314801+00:00","extra":{}}
15:23:58 CRITICAL  [console] Error thrown while running command "tailwind:build --minify". Message: "The process has been signaled with signal "4"." ["exception" => Symfony\Component\Process\Exception\ProcessSignaledException^ { …},"command" => "tailwind:build --minify","message" => "The process has been signaled with signal "4"."]
{"message":"Command \"tailwind:build --minify\" exited with code \"1\"","context":{"command":"tailwind:build --minify","code":1},"level":100,"level_name":"DEBUG","channel":"console","datetime":"2025-02-12T15:23:58.327010+00:00","extra":{}}

I also reported this error on https://github.com/oven-sh/bun/issues/17288 because it clearly states that it has to do with Bun.

One of the suggestions was to upgrade bun to v1.2.2, but I am unfamiliar with if this has to be integrated directly into the TailwindBundle. So this is just a report :-)

BTW it happened when building Tailwind v4.0.6; in the meantime, I ran the build on another computer and just transferred the tailwind.build.css back to the old computer with the problem.

sebastian0119 avatar Feb 12 '25 21:02 sebastian0119

Hey @sebastian0119 ,

This bundle is not Tailwind v4 ready yet, see the related PR: #81 . I wonder if that PR somehow will help with this issue.

Also, this kinda sounds to me as an upstream problem, not something related to the bundle in particular. Indeed, I would recommend you to upgrade bun to the latest first, probably that will be resolved.

Actually, I'm not familiar with Bun at all, is it something that is installed on your laptop? Or a Tailwind dependency? Because this bundle has nothing in common with Bun I think

bocharsky-bw avatar Feb 27 '25 16:02 bocharsky-bw