Skip to content

Incompatibility with php 8.4 #60634

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
julientraitdunion opened this issue Jun 2, 2025 · 1 comment
Closed

Incompatibility with php 8.4 #60634

julientraitdunion opened this issue Jun 2, 2025 · 1 comment

Comments

@julientraitdunion
Copy link

Symfony version(s) affected

7.3.0

Description

After upgrading to php 8.4 i get this when trying to cache:clear on 7.3.0 :

 | Verifying lock file contents can be installed on current platform.
 | Nothing to install, update or remove
 | Package behat/transliterator is abandoned, you should avoid using it. No replacement was suggested.
 | Generating autoload files
 | 147 packages you are using are looking for funding.
 | Use the `composer fund` command to find out more!
 | 
 | Run composer recipes at any time to see the status of your Symfony recipes.
 | 
 | phpstan/extension-installer: Extensions installed
 | Executing script cache:clear [KO]
 |  [KO]
 | Script cache:clear returned with error code 1
 | !!  
 | !!  In ErrorHandler.php line 246:
 | !!                              
 | !!    Unknown error type: 2048  
 | !!                              
 | !!  
 | !!  
 | Script @auto-scripts was called via post-install-cmd
 | [ENTRYPOINT] .env file exists. No need to copy.
 | [ENTRYPOINT] Installing composer dependencies.
 | Installing dependencies from lock file (including require-dev)
 | Verifying lock file contents can be installed on current platform.
 | Nothing to install, update or remove
 | Package behat/transliterator is abandoned, you should avoid using it. No replacement was suggested.
 | Generating autoload files

I tried deleting the cache manually but nothing changed and it keeps repeating.
I downgraded my docker image to php 8.3 and it goes smoothly.

How to reproduce

can't help much on that, i just upgraded my docker image to php8.4, as well as upgrading several other things at once :
symfony 7.3 (from 7.2)
api platform 4.1.9 (from 3.3.)
phpstan 2.1.16 (from 1.4.
)
php 8.4 (from 8.3)

Possible Solution

it probably have to do with php/php-src#13053

Additional Context

composer.json

{
    "type": "project",
    "license": "proprietary",
    "minimum-stability": "stable",
    "prefer-stable": true,
    "require": {
        "php": ">=8.3",
        "ext-ctype": "*",
        "ext-iconv": "*",
        "api-platform/core": "^4.0",
        "doctrine/annotations": "^2.0",
        "doctrine/doctrine-bundle": "^2.8",
        "doctrine/doctrine-migrations-bundle": "^3.2",
        "doctrine/orm": "^2.14",
        "easycorp/easyadmin-bundle": "^4.13",
        "lexik/jwt-authentication-bundle": "^3.0.0",
        "mailjet/mailjet-apiv3-php": "^1.6",
        "nelmio/cors-bundle": "^2.3",
        "phpdocumentor/reflection-docblock": "^5.3",
        "phpstan/phpdoc-parser": "^1.16",
        "ramsey/uuid-doctrine": "*",
        "sentry/sentry-symfony": "^5.0",
        "stof/doctrine-extensions-bundle": "^1.11",
        "stripe/stripe-php": "^14.8",
        "symfony/asset": "7.3.*",
        "symfony/console": "7.3.*",
        "symfony/css-selector": "7.3.*",
        "symfony/debug-bundle": "7.3.*",
        "symfony/doctrine-messenger": "7.3.*",
        "symfony/dom-crawler": "7.3.*",
        "symfony/dotenv": "7.3.*",
        "symfony/expression-language": "7.3.*",
        "symfony/flex": "^2",
        "symfony/framework-bundle": "7.3.*",
        "symfony/http-client": "7.3.*",
        "symfony/lock": "7.3.*",
        "symfony/messenger": "7.3.*",
        "symfony/monolog-bundle": "^3.8",
        "symfony/property-access": "7.3.*",
        "symfony/property-info": "7.3.*",
        "symfony/rate-limiter": "7.3.*",
        "symfony/runtime": "7.3.*",
        "symfony/security-bundle": "7.3.*",
        "symfony/serializer": "7.3.*",
        "symfony/string": "7.3.*",
        "symfony/translation": "7.3.*",
        "symfony/twig-bundle": "7.3.*",
        "symfony/validator": "7.3.*",
        "symfony/yaml": "7.3.*",
        "wyndow/fuzzywuzzy": "^0.6.0",
        "zenstruck/schedule-bundle": "^1.8"
    },
    "require-dev": {
        "doctrine/doctrine-fixtures-bundle": "^3.5",
        "friendsofphp/php-cs-fixer": "^3",
        "phpstan/extension-installer": "^1.4",
        "phpstan/phpstan": "^2.0",
        "phpstan/phpstan-symfony": "^2.0",
        "phpunit/phpunit": "^10.5",
        "roave/security-advisories": "dev-latest",
        "symfony/browser-kit": "7.3.*",
        "symfony/mailer": "7.3.*",
        "symfony/maker-bundle": "^1.48",
        "symfony/phpunit-bridge": "^7.0",
        "symfony/stopwatch": "7.3.*",
        "symfony/web-profiler-bundle": "7.3.*"
    },
    "config": {
        "allow-plugins": {
            "php-http/discovery": true,
            "symfony/flex": true,
            "symfony/runtime": true,
            "phpstan/extension-installer": true
        },
        "sort-packages": true
    },
    "autoload": {
        "psr-4": {
            "App\\": "src/"
        }
    },
    "autoload-dev": {
        "psr-4": {
            "App\\Tests\\": "tests/"
        }
    },
    "replace": {
        "symfony/polyfill-ctype": "*",
        "symfony/polyfill-iconv": "*",
        "symfony/polyfill-php72": "*",
        "symfony/polyfill-php73": "*",
        "symfony/polyfill-php74": "*",
        "symfony/polyfill-php80": "*",
        "symfony/polyfill-php81": "*"
    },
    "scripts": {
        "auto-scripts": {
            "cache:clear": "symfony-cmd",
            "assets:install %PUBLIC_DIR%": "symfony-cmd"
        },
        "post-install-cmd": [
            "@auto-scripts"
        ],
        "post-update-cmd": [
            "@auto-scripts"
        ]
    },
    "conflict": {
        "symfony/symfony": "*"
    },
    "extra": {
        "symfony": {
            "allow-contrib": false,
            "require": "7.3.*"
        }
    }
}

@julientraitdunion
Copy link
Author

nevermind ...
a previous dev had this added into the framework.yaml

php_errors:
        log:
           [...]
            !php/const \E_STRICT: !php/const Psr\Log\LogLevel::ERROR
           [...]

Once removed it is now fine

@xabbuh xabbuh closed this as not planned Won't fix, can't repro, duplicate, stale Jun 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants