Closed
Description
Symfony version(s) affected
6.4.6
Description
If you have no permissions to write to assets
directrory you'll just get a php warning in prod enviroment (as warnings does not converts to exceptions there).
It is not right to say "all right" when it is not I think. And return exit code 0. bash scripts with set -e
continue executing with not installed assets in CI (for example). Good that assets:compile
throw exeption like "you did not run importmap:install", but problem was in another place.
21:14:28 WARNING [php] Warning: file_put_contents(/var/www/html/assets/vendor/installed.php): Failed to open stream: No such file or directory ["exception" => ErrorException { …}]
[OK] Downloaded 1 package into assets/vendor.
How to reproduce
./bin/console imp:req bootstrap
rm -rf assets/vendor
echo 'APP_ENV=prod' >> .env.local
chmod 555 assets
./bin/console imp:inst
Possible Solution
Check that downloded package exists and throw exception otherwise.