Not compatible anymore with Drupal 8

Created on 12 October 2023, about 1 year ago
Updated 13 October 2023, about 1 year ago

Problem/Motivation

After 8.x-2.16, this module is not compatible anymore with Drupal 8, even 8.9.20.
service.yml introduce a dependency to file.repository but it doesn't exist !

Steps to reproduce

The website encountered an unexpected error. Please try again later.
Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: The service "blazy.svg" has a dependency on a non-existent service "file.repository". in Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processValue() (line 31 of /var/www/myproject/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php).
Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processValue(Object, ) (Line: 60)
Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass->processValue(Array, ) (Line: 28)
Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processValue(Array) (Line: 67)
Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass->processValue(Object, 1) (Line: 28)
Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processValue(Object, 1) (Line: 60)
Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass->processValue(Array, 1) (Line: 28)
Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass->processValue(Array, 1) (Line: 39)
Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass->process(Object) (Line: 140)
Symfony\Component\DependencyInjection\Compiler\Compiler->compile(Object) (Line: 789)
Symfony\Component\DependencyInjection\ContainerBuilder->compile() (Line: 1335)
Drupal\Core\DrupalKernel->compileContainer() (Line: 916)
Drupal\Core\DrupalKernel->initializeContainer() (Line: 477)
Drupal\Core\DrupalKernel->boot() (Line: 707)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Fixed

Version

2.20

Component

Code

Created by

🇫🇷France Striknin Lyon

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @Striknin
  • 🇮🇩Indonesia gausarts

    An obvious oversight. This is the second issue I had with Drupal versions. Last time, D8.7.

    Honestly I no longer have D8 :)

    We should up Drupal requirement instead since we cannot downgrade it FWIW.

    ATM, please lock it to your working version till you have time to upgrade to D9 or so.

    We'll keep it open till Blazy:2.21 release with a minimum D9.3 to avoid dups.

    Thank you.

  • 🇺🇸United States jghyde

    I just upgraded from D8.9 to 9.2.* and have the same problem:

    shell$ drush cr
    The service "blazy.svg" has a dependency on a non-existent service "file.repository".  
    

    I have commented out the "file.repository" on the blazy.info.yml to try to get beyond this until I land on D9.5 (incrementally upgrading 9.1... 9.2... )because of these issues! Right now I am at 9.2.x. The issue emerged from the upgrade from 8.9 to 9.0.

  • 🇺🇸United States jghyde

    The blazy.svg file.repositiory error is also stopping the drush updb for all of the Drupal 9.2 site:

    shell$ drush updb
     Do you wish to run the specified pending updates? (yes/no) [yes]:
     > yes
    
    >  [notice] Update started: blazy_post_update_schema_formatter_grid_int_to_string
    >  [error]  The "blazy.svg" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead. 
    >  [error]  Update failed: blazy_post_update_schema_formatter_grid_int_to_string 
     [error]  Update aborted by: blazy_post_update_schema_formatter_grid_int_to_string 
     [error]  Finished performing updates. 
    
  • 🇺🇸United States jghyde

    Regarding #4 - An upgrade to D9.3.0 fixed everything.

  • Status changed to Needs review about 1 year ago
  • Open in Jenkins → Open on Drupal.org →
    Core: 9.5.x + Environment: PHP 7.4 & MySQL 5.7
    last update about 1 year ago
    50 pass
  • 🇮🇩Indonesia gausarts

    Yes, D9.3 should be the minimum:
    https://git.drupalcode.org/project/drupal/-/blob/9.3.0/core/modules/file...

    On second thought, that service was internally a @todo/ non-functional, so safe to remove it till blazy:3.x out with a min D9.3.

    Attached an immediate solution for D8.8.

    If anyone still had problems with service addition and removal WSOD issues, please read the Update SOP.

  • Open in Jenkins → Open on Drupal.org →
    Core: 9.5.x + Environment: PHP 7.4 & MySQL 5.7
    last update about 1 year ago
    50 pass
  • 🇮🇩Indonesia gausarts

    Added a hook update to inform the change.

    • gausarts committed 79120e23 on 8.x-2.x
      Issue #3393539 by gausarts, jghyde, Striknin: Not compatible anymore...
  • Status changed to Fixed about 1 year ago
  • 🇮🇩Indonesia gausarts

    We'll have a new release this weekend.

    Committed. Thank you for contribution.

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024