Reputation: 343
I installed Symfony 4.2 via composer
composer create-project Symfony/website-skeleton my-project
everything works correctly, then I put the project in gitlab. a friend of mine tried to clone it on its own computer in order to work on the same project, and when he runs composer install
he got an error :
Script cache:clear returned with error code 255
Frankly, I tried everything I can find on the web and Stack Overflow but unfortunately, i didn't succeed.
Thanks in advance for any help
Upvotes: 14
Views: 33955
Reputation: 636
It happened to me too. Turns out my composer simply did not have enough memory available! Try this (it worked for me):
COMPOSER_MEMORY_LIMIT=-1 composer <your-composer-command-here>
Upvotes: 1
Reputation: 343
First: How I got the error:
Second: How I solved this:
Actually, when you make a CTRL-C and CTRL-V to the content of the symfony project folder, you are not copying everything, all the .files (dot files example .env, .test, .gitignore) are hidden.
in order to copy the other hidden files such as .env you should open your terminal and type "cp .env (to your location)" in my case, it was "cp .env ~/Desktop/newApp"
Hint: in order to display all the folders and files in a folder use "ll" (ll: aliased to "ls -lh") instead of "ls" command.
Upvotes: 8
Reputation: 429
I have this error message but the problem was with cache being deleted, solve it with
console cache:warnup
Upvotes: 1
Reputation: 9295
Downgraded temporarily from composer 2 to composer 1. Then I had this error after doing composer req symfony/orm-pack
.
Executing script cache:clear [KO]
[KO]
Script cache:clear returned with error code 255
[...Stacktrace...]
!!
Script @auto-scripts was called via post-update-cmd
Installation failed, reverting ./composer.json to its original content.
I had to remove @auto-scripts
from my composer.json
file. Not sure if this will lead to correct beahvior, but I was just followiing a tutorial.
Turn
"post-update-cmd": [
"@auto-scripts"
]
into
"post-update-cmd": [
""
]
Upvotes: 2
Reputation: 2945
I have had the same problem, in my case when installing symfony version 4 and 5.
Error:
Executing script cache:clear [KO]
[KO]
Script cache:clear returned with error code 255
I solved it by downloading composer manually and running composer.phar :
php7.1 composer.phar create-project symfony/website-skeleton:"^4.4" symfony4
And now I have no problem installing symfony.
Upvotes: 0
Reputation: 1
I just had this error message.
I removed the SwiftMailer bundle but not the config swiftMailer.yml file Symfony was unable to manage this configuration file
I solved this by removing the yml file
Upvotes: 0
Reputation: 9875
In my case was that I removed some packages that I didn't need from the composer.json
but I forgot to remove them from config/bundle.php
.
So check config/bundle.php
and if you find something there that isn't right, go delete it!
Upvotes: 3