As jquery.ui is removed from Core in Drupal 10 and is replaced with contrib module. We are updating the dependencies of existing core libraries with contrib modules in libraries, info and composer files.

Issue fork bootstrap-3427365

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mnk-0210 created an issue. See original summary.

mnk-0210’s picture

StatusFileSize
new960 bytes

updated patch in #1.

siddharthjain’s picture

The above patch applies smoothly and the dependencies has been updated as per this article: https://www.drupal.org/docs/upgrading-drupal/upgrading-from-drupal-8-or-...

siddharthjain’s picture

Status: Active » Needs review

shelane made their first commit to this issue’s fork.

  • shelane committed 6aa46032 on 8.x-3.x authored by mnk-0210
    Issue #3427365 by mnk-0210: Remove jQuery UI Library's Core dependency...
shelane’s picture

Status: Needs review » Fixed
jcnventura’s picture

Status: Fixed » Needs work

I think this may need a 2nd commit. This change only moved the libraries from core to the contrib modules, but it doesn't enable the modules. Which means that the newly added libraries are not enabled now, but the theme depends on them.

This may need the following changes:

shelane’s picture

@jcnventura, yes, you're right. I've added the dependencies to the info file and added an update hook to enable the modules. I'm not sure what to do about the missing jquery libraries that you mentioned though.

jcnventura’s picture

They were declared before in bootstrap.libraries.yml and were removed when the MR was merged. They should be able to be trivially added back, as they are now all provided by the (non-core) jquery_ui module.

elc’s picture

Adding these are dependencies inside the .info.yml means that the update can never be run - Drupal complains that dependencies are missing, and get stuck in "Verifying requirements" preventing updates from running.

I also can't get the theme's hook_update_N to detect. Is it meant to be named something different because it's a base theme? I had to install the 3x modules manually after patching in.

elc’s picture

The name of the module is jquery_ui_resizable and NOT jquery_ui_resizeable

sclsweb made their first commit to this issue’s fork.

shelane’s picture

Status: Needs work » Needs review
grimreaper’s picture

StatusFileSize
new3.72 KB

Hi,

Here is a patch from the MR for Composer usage.

I don't have a modal on my website to test just want to apply the patch to have the modules enabled.

grimreaper’s picture

Status: Needs review » Needs work

On Core 10.3.1, the update is not detected. After applying the patch, drush cr, then drush updb does not detect that there is a pending update.

lmoeni’s picture

I ran into this issue when I created a newsletter (Simplenews) which threw the warnings that the jquery_ui modules are missing:

 User warning: The following theme is missing from the file system: jquery_ui in Drupal\Core\Extension\ExtensionPathResolver->getPathname() (line 63 of core/lib/Drupal/Core/Extension/ExtensionPathResolver.php).
    Deprecated function: dirname(): Passing null to parameter #1 ($path) of type string is deprecated in Drupal\Core\Extension\ExtensionPathResolver->getPath() (line 85 of core/lib/Drupal/Core/Extension/ExtensionPathResolver.php).

Sadly, update hooks do not work in themes as themes do not have the install file like modules do. That's why the update is not detected.
Defining the dependencies in the info.yml breaks the installation process for me:
Unable to install theme: 'theme_name' due to unmet module dependencies: 'jquery_ui, jquery_ui_draggable, jquery_ui_resizable'.
Tested with Drupal 10.2.3 and 10.3.1 + Bootstrap 3.31. I would not recommend using the patch. Instead I would install the modules in your own profile/module till there is a working solution for this issue.

  • shelane committed b50c58fa on 8.x-3.x
    Issue #3427365 by mnk-0210: Remove jQuery UI Library's Core dependency...
shelane’s picture

I'm going to go ahead and do a release with this and include in the notes that users must enable these modules since the theme cannot do it through an update hook.

rosk0’s picture

Status: Needs work » Fixed

Marking as fixed as this was released in the 8.x-3.32 and I was able to run updates without issues, status report shows nothing related as well - tested on the latest Drupal core 10.3.2.

Status: Fixed » Closed (fixed)

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

loopy1492’s picture

We have upgraded to the most recent version of 3.x and we are also getting this:

User warning: The following theme is missing from the file system: jquery_ui_resizable in Drupal\Core\Extension\ExtensionPathResolver->getPathname() (line 63 of core/lib/Drupal/Core/Extension/ExtensionPathResolver.php).
Drupal\Core\Extension\ExtensionPathResolver->getPathname() (Line: 85)
Drupal\Core\Extension\ExtensionPathResolver->getPath() (Line: 154)
Drupal\Core\Asset\LibraryDiscoveryParser->buildByExtension() (Line: 87)
Drupal\Core\Asset\LibraryDiscoveryCollector->getLibraryDefinitions() (Line: 66)
Drupal\Core\Asset\LibraryDiscoveryCollector->resolveCacheMiss() (Line: 149)
Drupal\Core\Cache\CacheCollector->get() (Line: 44)
Drupal\Core\Asset\LibraryDiscovery->getLibrariesByExtension() (Line: 58)
Drupal\Core\Asset\LibraryDiscovery->getLibraryByName() (Line: 68)
Drupal\Core\Asset\LibraryDependencyResolver->doGetDependencies() (Line: 70)
Drupal\Core\Asset\LibraryDependencyResolver->doGetDependencies() (Line: 70)
Drupal\Core\Asset\LibraryDependencyResolver->doGetDependencies() (Line: 70)
Drupal\Core\Asset\LibraryDependencyResolver->doGetDependencies() (Line: 41)
Drupal\Core\Asset\LibraryDependencyResolver->getLibrariesWithDependencies() (Line: 116)
Drupal\Core\Asset\AssetResolver->getLibrariesToLoad() (Line: 175)
Drupal\Core\Asset\AssetResolver->getCssAssets() (Line: 323)
Drupal\Core\Render\HtmlResponseAttachmentsProcessor->processAssetLibraries() (Line: 167)
Drupal\Core\Render\HtmlResponseAttachmentsProcessor->processAttachments() (Line: 97)
Drupal\big_pipe\Render\BigPipeResponseAttachmentsProcessor->processAttachments() (Line: 45)
Drupal\Core\EventSubscriber\HtmlResponseSubscriber->onRespond()
call_user_func() (Line: 111)
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch() (Line: 214)
Symfony\Component\HttpKernel\HttpKernel->filterResponse() (Line: 202)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 53)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle() (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle() (Line: 263)
Drupal\shield\ShieldMiddleware->bypass() (Line: 130)
Drupal\shield\ShieldMiddleware->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 741)
Drupal\Core\DrupalKernel->handle() (Line: 19)