Skip to content

Can't upgrade 2.8.1 packages to 2.9.0 #907

Closed
@adrolter

Description

@adrolter

I'm not sure if the issue is with my setup, the new symfony/stimulus-bundle, or UX, but my service container won't build with any UX 2.9.0 packages installed. I can explicitly require symfony/stimulus-bundle 2.9.0 with UX 2.8.1 packages and all is fine, but upgrading UX packages results in service resolution errors.

composer.json:

image

Running a composer update results in:

  Gathering patches from patch file.
  Loading composer repositories with package information
  Restricting packages listed in "symfony/symfony" to "^6"
  Updating dependencies
  Lock file operations: 1 install, 6 updates, 0 removals
    - Upgrading symfony/flex (v2.3.0 => v2.3.1)
    - Locking symfony/stimulus-bundle (v2.9.0)
    - Upgrading symfony/ux-chartjs (v2.8.1 => v2.9.0)
    - Upgrading symfony/ux-dropzone (v2.8.1 => v2.9.0)
    - Upgrading symfony/ux-live-component (v2.8.1 => v2.9.0)
    - Upgrading symfony/ux-notify (v2.8.1 => v2.9.0)
    - Upgrading symfony/ux-turbo (v2.8.1 => v2.9.0)
  Writing lock file
  Installing dependencies from lock file (including require-dev)
  Package operations: 1 install, 6 updates, 0 removals
    - Downloading symfony/flex (v2.3.1)
    - Downloading symfony/stimulus-bundle (v2.9.0)
    - Downloading symfony/ux-chartjs (v2.9.0)
    - Downloading symfony/ux-dropzone (v2.9.0)
    - Downloading symfony/ux-live-component (v2.9.0)
    - Downloading symfony/ux-notify (v2.9.0)
    - Downloading symfony/ux-turbo (v2.9.0)
  Gathering patches from patch file.
  Gathering patches for dependencies. This might take a minute.
    - Upgrading symfony/flex (v2.3.0 => v2.3.1): Extracting archive
    - Installing symfony/stimulus-bundle (v2.9.0): Extracting archive
    - Upgrading symfony/ux-chartjs (v2.8.1 => v2.9.0): Extracting archive
    - Upgrading symfony/ux-dropzone (v2.8.1 => v2.9.0): Extracting archive
    - Upgrading symfony/ux-live-component (v2.8.1 => v2.9.0): Extracting archive
    - Upgrading symfony/ux-notify (v2.8.1 => v2.9.0): Extracting archive
    - Upgrading symfony/ux-turbo (v2.8.1 => v2.9.0): Extracting archive
  Package fgrosse/phpasn1 is abandoned, you should avoid using it. No replacement was suggested.
  Package php-http/message-factory is abandoned, you should avoid using it. Use psr/http-factory instead.
  Generating optimized autoload files
  157 packages you are using are looking for funding.
  Use the `composer fund` command to find out more!
  Endroid Installer detected project type "symfony"
  
  What about running composer global require symfony/thanks && composer thanks now?
  This will spread some 💖  by sending a ★  to the GitHub repositories of your fellow package maintainers.
  
  Run composer recipes at any time to see the status of your Symfony recipes.
  
  Executing script cache:clear [KO]
   [KO]
  Script cache:clear returned with error code 255
  !!  Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException {#16135
- !!    #message: "The service "chartjs.twig_extension" has a dependency on a non-existent service "stimulus.helper"."
  !!    #code: 0
  !!    #file: "/data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php"
  !!    #line: 83
  !!    -id: "stimulus.helper"
  !!    -sourceId: "chartjs.twig_extension"
  !!    -alternatives: []
  !!    trace: {
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php:83 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php:80 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php:46 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php:89 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php:46 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php:80 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php:46 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php:44 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php:37 { …}
  !!      /data/app/vendor/symfony/dependency-injection/Compiler/Compiler.php:73 { …}
  !!      /data/app/vendor/symfony/dependency-injection/ContainerBuilder.php:721 { …}
  !!      /data/app/vendor/symfony/http-kernel/Kernel.php:499 { …}
  !!      /data/app/vendor/symfony/http-kernel/Kernel.php:721 { …}
  !!      /data/app/vendor/symfony/http-kernel/Kernel.php:123 { …}
  !!      ./src/App/Kernel.php:66 {
  !!        Moyer\App\Kernel->boot(): void
  !!        › {
  !!        ›     parent::boot();
  !!        › 
  !!      }
  !!      ./bin/console:44 { …}
  !!    }
  !!  }
  !!  2023-05-27T19:09:41+00:00 [critical] Uncaught Exception: The service "chartjs.twig_extension" has a dependency on a non-existent service "stimulus.helper".
  !!  
  Script @auto-scripts was called via post-update-cmd

Whereas this configuration works:

image

  Gathering patches from patch file.
  Loading composer repositories with package information
  Restricting packages listed in "symfony/symfony" to "^6"
  Updating dependencies
  Lock file operations: 1 install, 1 update, 0 removals
    - Upgrading symfony/flex (v2.3.0 => v2.3.1)
    - Locking symfony/stimulus-bundle (v2.9.0)
  Writing lock file
  Installing dependencies from lock file (including require-dev)
  Package operations: 0 installs, 1 update, 0 removals
  Gathering patches from patch file.
  Gathering patches for dependencies. This might take a minute.
    - Upgrading symfony/flex (v2.3.0 => v2.3.1): Extracting archive
  Package fgrosse/phpasn1 is abandoned, you should avoid using it. No replacement was suggested.
  Package php-http/message-factory is abandoned, you should avoid using it. Use psr/http-factory instead.
  Generating optimized autoload files
  157 packages you are using are looking for funding.
  Use the `composer fund` command to find out more!
  Endroid Installer detected project type "symfony"
  
  What about running composer global require symfony/thanks && composer thanks now?
  This will spread some 💖  by sending a ★  to the GitHub repositories of your fellow package maintainers.
  
  Run composer recipes at any time to see the status of your Symfony recipes.
  
+ Executing script cache:clear [OK]
  Executing script assets:install public [OK]
  
  No security vulnerability advisories found

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions