When trying to do a "composer upgrade", it fails in "@auto-scripts" when reaching doctrine/doctrine-bundle.
The error is:
Executing script cache:clear [KO]
[KO]
Script cache:clear returned with error code 1
!!
!! In ArrayNode.php line 304:
!!
!! Unrecognized option "use_savepoints" under "doctrine.dbal.connections.defau
!! lt". Available options are "MultipleActiveResultSets", "application_name",
!! "auto_commit", "charset", "connectstring", "dbname", "dbname_suffix", "defa
!! ult_dbname", "default_table_options", "driver", "driver_class", "host", "id
!! le_connection_ttl", "instancename", "keep_replica", "logging", "mapping_typ
!! es", "memory", "options", "password", "path", "persistent", "pooled", "port
!! ", "profiling", "profiling_collect_backtrace", "profiling_collect_schema_er
!! rors", "protocol", "replicas", "result_cache", "schema_filter", "schema_man
!! ager_factory", "server", "server_version", "service", "servicename", "sessi
!! onMode", "sslcert", "sslcrl", "sslkey", "sslmode", "sslrootcert", "unix_soc
!! ket", "url", "user", "wrapper_class".
!!
!!
!!
Script @auto-scripts was called via post-update-cmd
My composer.json:
{
"type": "project",
"license": "proprietary",
"minimum-stability": "stable",
"require": {
"symfony/framework-bundle": "^7.3",
"symfony/console": "^7.3",
"symfony/flex": "^2.8",
"symfony/runtime": "^7.3",
"symfony/http-client": "^7.3",
"symfony/twig-bundle": "^7.3",
"symfony/dotenv": "^7.3",
"symfony/uid": "^7.3",
"symfony/yaml": "^7.3",
"doctrine/orm": "^3.5",
"doctrine/doctrine-bundle": "^3.0",
"doctrine/doctrine-migrations-bundle": "^3.5",
"amphp/file": "^3.2"
},
"config": {
"allow-plugins": {
"symfony/flex": true,
"symfony/runtime": true
}
},
"scripts": {
"auto-scripts": {
"cache:clear": "symfony-cmd",
"assets:install %PUBLIC_DIR%": "symfony-cmd"
},
"post-install-cmd": [
"@auto-scripts"
],
"post-update-cmd": [
"@auto-scripts"
]
},
"autoload": {
"psr-4": {
"App\\": "src/"
}
}
}
This is reproducible.
- Create a new, empty directory
- Add my composer.json
- Run "composer install"
More context, as requested by stackoverflow to let me post: I run a website using php, symfony and doctrine, managed by composer. Now I tried upgrading from symfony 7.2 to 7.3, which didn't work. For testing purposes, I then created a new directory and let composer handle composer.json (almost) completely, by only running "composer require" and "composer require --dev". The only addition I made is the post-update-cmd and post-install-cmd, so I see the problem directly and don't have to set up a webserver serving the new directory.