Skip to content

Instantly share code, notes, and snippets.

@shyim
Last active November 19, 2019 15:53
Show Gist options
  • Save shyim/d0d0d306c785c9c7341fce2260a2645f to your computer and use it in GitHub Desktop.
Save shyim/d0d0d306c785c9c7341fce2260a2645f to your computer and use it in GitHub Desktop.
Shopware 5.7 Update Prepare Guide

List of compability issues with Shopware 5.7

Updates

  • Symfony 3.4 => Symfony 4.4
  • Guzzle 5 => Guzzle 6.4 (Consider using PSR18 Http Client)
  • Monolog 1 => Monolog 2

Breaking things

Symfony services and parameters are case sensitive now

This can be done also in versions before. Check all service ids and parameters

Symfony services are private by default

With the update you can only use public services. With following code can you override the public default back to true

<services>
<defaults public="true" />

<service id="......

Services inside container has to be objects

It's not allowed to have arrays or strings inside the container anymore

$form->isValid() calling without calling first isSubmitted throws an error

Change

if ($form->isValid()) {

to

if ($form->isSubmitted() && $form->isValid()) {

Don't use deprecated Monolog methods

https://github.com/rectorphp/rector/blob/master/config/set/monolog/monolog20.yaml#L5-L16

Removeals of unused packages

  • egulias/email-validator
  • symfony/translation
  • php-http/curl-client
  • psr/link
  • symfony/polyfill-ctype
  • symfony/polyfill-iconv
  • symfony/polyfill-iconv
  • symfony/polyfill-php56
  • symfony/polyfill-php70
  • symfony/polyfill-php71
  • symfony/polyfill-php72
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment