Missing neilime/php-css-lint library Error even after Ludwig Download

Created on 4 January 2024, 6 months ago

Problem/Motivation

I am trying to install this module directly without composer using Ludwig. Ludwig successfully downloads the neilime/php-css-lint library and I can even see it in the "lib" sub-folder in the module folder. But it still always gives the error:

"The neilime/php-css-lint library is required. See README.md."

Steps to reproduce

1. Copy module files directly or use the built-in Drupal installer.
2. Visit "Packages" page from "Reports" menu. It successfully downloads the required library.
3. Try to install this module. It will show the above error.

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

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

Comments & Activities

  • Issue created by @Samk11
  • πŸ‡ΊπŸ‡ΈUnited States Chris Burge

    All that layout_builder_component_attributes_requirements() does is check if the CssLint\Linter class exists:

    /**
     * Implements hook_requirements().
     */
    function layout_builder_component_attributes_requirements($phase) {
      $requirements = [];
    
      if (!class_exists('CssLint\Linter')) {
        $requirements['lbca_php_css_lint']['title'] = t('Layout Builder Component Attributes');
        $requirements['lbca_php_css_lint']['description'] = t('The neilime/php-css-lint library is required. See README.md.');
        $requirements['lbca_php_css_lint']['severity'] = REQUIREMENT_ERROR;
      }
    
      return $requirements;
    }
    

    You've confirmed the package is correctly downloaded, so the Layout Builder Component Attributes module has done it's part with ludwig.json. It appears that Ludwig may be failing to register the project with the autoloader.

    Have you tried clearing Drupal cache?

Production build 0.69.0 2024