Support from Acquia helps fund testing for Drupal Acquia logo

Comments

pyxio created an issue. See original summary.

pyxio’s picture

Version: 8.x-3.x-dev » 8.x-4.x-dev
pyxio’s picture

Version: 8.x-4.x-dev » 8.x-4.3
aperedos’s picture

+1 I have the same problem.

scotthooker’s picture

+1 same

desierto’s picture

Yes, indeed same problem. Panels Version: 8.x-4.3. Drupal 8.6.9.

Also clicking "Content" under "Variants" does not drop down the sub-menu in Seven theme unless I hit update and save, then it will only once. In Adaptive Theme it will not at all.

aperedos’s picture

Priority: Major » Critical
aperedos’s picture

It´s not possible to work with panels in this version, because you cannot create new blocks, delete or edit existing blocks, or create new context...It fails for any action.

george.karaivanov’s picture

Same story

remkoklein’s picture

downgrade ctools to 3.0.0 until this issue is fixed.

gaspounet’s picture

Downgrading ctools to 3.0 worked for me and resolved another critical error with panels and easy breadcrumbs, thank you!

lamp5’s picture

The same issue on my sites. Downgrade ctools to 3.0 works. Thanks.

iyyappan.govind’s picture

Same issue here, But ctools required by lot of other modules. So I can't downgrade the ctools module. Is there other way to do it? Thanks

artematem’s picture

@iyyappan.govind

But ctools required by lot of other modules. So I can't downgrade the ctools module.

what is blocking you from downgrading?
In composer "drupal/ctools": "3.0" or "drupal/ctools": "3.0 as 3.1" (if it will work).

manuel.adan’s picture

#2936263: User's temp stores has been moved to core for 8.5.x in ctools makes panels to fail.

The SharedTempStoreFactory was moved in D8.5 from the user module to the main core. Although the old class extends the new one, they do not share the same storage. Panels still uses the SharedTempStoreFactory from the user module, that stores values in the "user.shared_tempstore.$collection" store, while ctools uses the new factory which stores its values in the "tempstore.shared.$collection" store.

Panels must be refactored to use the same SharedTempStoreFactory instance as ctools.

cobenash’s picture

+1 same

lyalyuk’s picture

subscribe

drupgirl’s picture

+1, downgrading ctools to 3.0 works. thx, remkoklein, for the heads up.

iyyappan.govind’s picture

@artematem

If I downgrade the module means, It will affect the database updates if present. How could we manage database updates? Thanks

iyyappan.govind’s picture

FileSize
52.22 KB

I am getting error which is attachment.

nickolaj’s picture

Title: ajax errors prevents adding blocks or conditions » Change panels store
Issue summary: View changes
Status: Active » Needs review
FileSize
18.96 KB
iyyappan.govind’s picture

@nickolaj

Let me test your patch. Thanks

lamp5’s picture

manuel.adan’s picture

Status: Needs review » Needs work

After the patch, there are still references to the deprecated class:

panels_ipe/src/Controller/PanelsIPEPageController.php:55:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Form/PanelsIPELayoutForm.php:28:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Form/PanelsIPEBlockPluginForm.php:43:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Helpers/RequestHandlerBase.php:10:use Drupal\user\SharedTempStore;
panels_ipe/src/Helpers/RequestHandlerBase.php:25:   * @var \Drupal\user\SharedTempStore */
panels_ipe/src/Plugin/DisplayBuilder/InPlaceEditorDisplayBuilder.php:29:   * @var \Drupal\user\SharedTempStore
src/Form/PanelsContentForm.php:22:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/PanelsContentForm.php:64:   * @return \Drupal\user\SharedTempStore
src/Form/PanelsDeleteBlockForm.php:21:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/LayoutChangeSettings.php:31:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/LayoutChangeRegions.php:26:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/LayoutPluginSelector.php:26:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/PanelsBlockConfigureFormBase.php:25:   * @var \Drupal\user\SharedTempStoreFactory
src/Form/PanelsBlockConfigureFormBase.php:81:   * @return \Drupal\user\SharedTempStore
tests/src/Unit/panels_ipe/RequestHandlerTestBase.php:9:use Drupal\user\SharedTempStore;
iyyappan.govind’s picture

Hi @nickolaj

Patch works fine. Also we need to change the panelizer pattern to use the core's tempstore. Here is the issue

https://www.drupal.org/project/panelizer/issues/3034080

Thanks

nickolaj’s picture

Hi @iyyappangovind-0!
You're welcome!
Thank you.

iyyappan.govind’s picture

Here is the updated patch file. Thanks to nickolaj and manuel.adan

iyyappan.govind’s picture

Status: Needs work » Needs review
manuel.adan’s picture

Status: Needs review » Needs work

After #27, still:

panels_ipe/src/Controller/PanelsIPEPageController.php:55:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Form/PanelsIPELayoutForm.php:28:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Form/PanelsIPEBlockPluginForm.php:43:   * @var \Drupal\user\SharedTempStore
panels_ipe/src/Helpers/RequestHandlerBase.php:10:use Drupal\user\SharedTempStore;
panels_ipe/src/Helpers/RequestHandlerBase.php:25:   * @var \Drupal\user\SharedTempStore */
panels_ipe/src/Plugin/DisplayBuilder/InPlaceEditorDisplayBuilder.php:29:   * @var \Drupal\user\SharedTempStore
src/Form/PanelsContentForm.php:64:   * @return \Drupal\user\SharedTempStore
src/Form/PanelsBlockConfigureFormBase.php:81:   * @return \Drupal\user\SharedTempStore
tests/src/Unit/panels_ipe/RequestHandlerTestBase.php:9:use Drupal\user\SharedTempStore;
iyyappan.govind’s picture

Here is the updated patch file.

Thanks

iyyappan.govind’s picture

Status: Needs work » Needs review
iyyappan.govind’s picture

Status: Needs review » Needs work
iyyappan.govind’s picture

Fixed below error identified by testing

PHP Parse error: syntax error, unexpected 'use' (T_USE), expecting ',' or ';' in /var/www/html/modules/contrib/panels/panels_ipe/src/Helpers/RequestHandlerBase.php on line 11

sameer_khan’s picture

Thanks @iyyappan.govind and @nickolaj for your patches.

I had a few issues with the previous patches, so made some changes. Replacing \Drupal\user\SharedTempStore with \Drupal\Core\TempStore\SharedTempStore and Drupal\user\SharedTempStoreFactory with Drupal\Core\TempStore\SharedTempStoreFactory.

Seems to be working fine for me.

sameer_khan’s picture

Status: Needs work » Needs review
manuel.adan’s picture

Status: Needs review » Needs work

Patch #34 doesn't apply for me (syntax error at line 10).

iyyappan.govind’s picture

iyyappan.govind’s picture

Status: Needs work » Needs review
cobenash’s picture

#37 works for me.

Drupal 8.6.10
Panels 8.x-4.3
Ctools 8.x-3.2

iyyappan.govind’s picture

Hi @cobenash,

Thanks for the testing.

PunamShelke’s picture

Works for me as well

PunamShelke’s picture

Status: Needs review » Reviewed & tested by the community
MaxMendez’s picture

Works as well, thanks.

proweb.ua’s picture

#37 works

iyyappan.govind’s picture

Thanking you all for the testing.

pyxio’s picture

is this patch still needed with release of new ctools https://www.drupal.org/node/3033634

markdc’s picture

#37 works, thanks.

YurkinPark’s picture

Confirm, patch from #37 is good solution. Tested on same instance like described in #39.

iyyappan.govind’s picture

@pyxio

Yes we need this patch to be included. Thanks

manuel.adan’s picture

Status: Reviewed & tested by the community » Needs work
  1. Still some reference to old class after patch:

    tests/src/Unit/panels_ipe/RequestHandlerTestBase.php:9

    use Drupal\user\SharedTempStore;
    
  2. Some references to old \Drupal\user\TempStoreException, moved to \Drupal\Core\TempStore\TempStoreException:

    panels_ipe/src/Controller/PanelsIPEPageController.php:137: * @throws \Drupal\user\TempStoreException
    panels_ipe/src/Helpers/RequestHandlerBase.php:100: * @throws \Drupal\user\TempStoreException
    panels_ipe/src/Helpers/RequestHandlerBase.php:113: * @throws \Drupal\user\TempStoreException
    panels_ipe/src/Helpers/RequestHandlerBase.php:124: * @throws \Drupal\user\TempStoreException

  3. +++ b/panels_ipe/src/Controller/PanelsIPEPageController.php
    @@ -52,7 +52,7 @@ class PanelsIPEPageController extends ControllerBase {
       /**
    -   * @var \Drupal\user\SharedTempStore
    +   * @var \Drupal\Core\TempStore\SharedTempStore
        */
       protected $tempStore;
    

    Not mandatory but recommended to fix CS in updated lines. In this case, missing property description in PHPDoc.

YurkinPark’s picture

iyyappan.govind’s picture

@YurkinPark

Thanks for test fix.

thalles’s picture

Status: Needs review » Reviewed & tested by the community
FileSize
126.48 KB

Thanks!
Works fine!

iyyappan.govind’s picture

Hi @thalles

Thanks for your test and screenshot.

andrewkamm’s picture

I'm rolling back CTools to work around this, but is there any word on when a new release will be issued that includes the reviewed and tested fixes above?

rafiqasad’s picture

#51 works for me,

Thanks

xeM8VfDh’s picture

I have the same questionas @andrewkamm... since this fix has been verified by multiple users, and this is a crucial problem, can we get an update as to when this fix be released? Seems we haven't had a panels release since April 14 2018, so we're long overdue.

manuel.adan’s picture

My personal recommendation is not to update the ctools module and any other module that depends on it until a stable release of all of them were launched.

To do so, if you are using composer for your project:

...
  "require": {
    "drupal/ctools": "<3.1",
    "drupal/panels": "<4.4",
    "drupal/page_manager": "<4.0-beta4"
...
binnythomas’s picture

Patch #51 is working for me. I was working on setting up Varbase Dashboard when I ran into the error when trying to get the panel layout changed.

ifrik’s picture

Patch #51 works for me for Drupal 8.6

thalles’s picture

Hi everyone, why not commit this patch?
It is likely that it will be of great help.

xeM8VfDh’s picture

Agreed, commit and publish a new release (assuming Page Manager gets on board and releases their related patch as well)

  • japerry committed 835d619 on 8.x-4.x authored by YurkinPark
    Issue #3031778 by iyyappan.govind, YurkinPark, skhanbwm, nickolaj,...
japerry’s picture

Issue summary: View changes
Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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

tdnshah’s picture

I am using acquia's lighting profile and facing the same issue below are the version of the modules I have :-
1. Ctools - 8.x-3.0
2. Page Manager andd page manager UI - 8.x-4.0-beta3
3. Panels - 8.x-4.4

In my console I am getting an AJAX Error as below

"
An AJAX HTTP error occurred.
HTTP Result Code: 200
Debugging information follows.
Path: /admin/structure/panels/page_manager.page/moderation_dashboard--moderation_dashboard-panels_variant-0/select_block?region&destination=/admin/structure/page_manager/manage/moderation_dashboard/page_variant__moderation_dashboard-panels_variant-0__content%3Fjs%3Dnojs
StatusText: OK
ResponseText: Error: Call to a member function getVariant() on null in Drupal\panels\Controller\Panels-&gt;getCachedValues() (line 39 of /var/www/newsroom-cms/docroot/modules/contrib/panels/src/CachedValuesGetterTrait.php)."

I tired installing layout plugin module but even after enabling it, the problem didn't got resolved.

When I tried applying #51 patch but I get the message saying previously applied .