0

I have tried this on a clean install of magento 2.4.1

I then went to a magento 2.3.6 ran grunt exec and grunt less both worked After upgrading the 2.3.6 to 2.4.1 the grunt exec then failed with the same error as the clean 2.4.1

Im running MAMP Pro on mac os

Running "exec:blank" (exec) task Running "clean:blank" (clean) task

405 paths cleaned.

Done.

Execution Time (2021-02-05 16:40:48 UTC-0) loading tasks 49ms ▇▇▇▇▇▇▇▇▇▇▇ 22% clean:blank 167ms ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 77% Total 218ms

Exited with code: 255. Error executing child process: Error: Process exited with code 255. Warning: Task "exec:blank" failed. Use --force to continue.

Aborted due to warnings.

Execution Time (2021-02-05 16:40:47 UTC-0) loading tasks 82ms ▇▇▇▇ 7% exec:blank 1.1s ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 93% Total 1.2s

bin/magento deploy static content methods work without error

0

Try with the force flag as suggested. Does that work ?

Use --force to continue

Also try these commands first

php bin/magento setup:upgrade
php bin/magento cache:flush
php bin/magento cache:clean
php bin/magento di:compile
php bin/magento setup:static-content:deploy -f

if you see any permission issue run this chown -R www-data:www-data *

0

I found an answer to this is to downgrade to the node version

I found that Magento 2.4.1 does not work with the latest version of node i downgraded my version of node to 10 and now grunt exec and grunt less run as expected

I followed this answer to downgrade my version of node to 10 on mac os

https://stackoverflow.com/questions/47008159/how-to-downgrade-node-version

1
  • I also have 2.4.1 and grunt exec:theme and grunt less:theme doesn't work. There are no commands defined in the "dev:source-theme" namespace.>> Exited with code: 1. I have downgraded Node to 10.0.0 and grunt exec too after seeing someone with a similar problem. "grunt-exec": "~1.0.0", Have you any other ideas how to fix this? I never had a problem up to 2.3.x It's only with 2.4.x
    – SilkSpin
    Mar 13 '21 at 23:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.