Skip to Content Skip to Menu

gantry 5 CB menu throws Exception

  • pludikar
  • pludikar
  • OFFLINE
  • Posts: 3
  • Thanks: 1
  • Karma: 0
1 year 11 months ago #331852 by pludikar
gantry 5 CB menu throws Exception was created by pludikar
Hi, 
Using latest Joomla 4, Gantry 5 and CB versions. Any attempt to select/activate any CB menu item throws the following exception messages:

```
Error: During inheritance of Countable: Uncaught Whoops\Exception\ErrorException: Return type of Twig\Node\Node::count() should either be compatible with Counta ▶
Stack trace:
#0 /home/**/tst.****.org/libraries/gantry5/src/classes/Gantry/Component/Whoops/SystemFacade.php(112): Whoops\Run->handleError()
#1 /home/**/tst.****.org/libraries/gantry5/compat/vendor/twig/twig/src/Node/Node.php(23): Gantry\Component\Whoops\SystemFacade->handleError()
#2 /home/**/tst.****.org/libraries/vendor/composer/ClassLoader.php(571): include('/home/**/...')
#3 /home/**/tst.****.org/libraries/vendor/composer/ClassLoader.php(428): Composer\Autoload\includeFile()
#4 [internal function]: Composer\Autoload\ClassLoader->loadClass()
#5 /home/**/tst.****.org/libraries/gantry5/compat/vendor/twig/twig/src/TwigFilter.php(128): class_exists()
#6 /home/**/tst.****.org/libraries/vendor/composer/ClassLoader.php(571): include('/home/**/...')
#7 /home/**/tst.****.org/libraries/vendor/composer/ClassLoader.php(428): Composer\Autoload\includeFile()
#8 /home/**/tst.****.org/libraries/gantry5/src/classes/Gantry/Component/Theme/AbstractTheme.php(107): Composer\Autoload\ClassLoader->loadClass() ▶
#9 /home/**/tst.****.org/libraries/gantry5/src/classes/Gantry/Framework/Theme.php(70): Gantry\Component\Theme\AbstractTheme->extendTwig()
#10 /home/**/tst.****.org/libraries/gantry5/src/classes/Gantry/Component/Theme/AbstractTheme.php(158): Gantry\Framework\Theme->extendTwig()
#11 /home/**/tst.****.org/libraries/gantry5/src/classes/Gantry/Component/Theme/AbstractTheme.php(176): Gantry\Component\Theme\AbstractTheme->ren ▶
#12 /home/**/tst.****.org/templates/g5_hydrogen/index.php(35): Gantry\Component\Theme\AbstractTheme->render()
#13 /home/**/tst.****.org/libraries/src/Document/HtmlDocument.php(736): require('/home/**/...')
#14 /home/**/tst.****.org/libraries/src/Document/HtmlDocument.php(791): Joomla\CMS\Document\HtmlDocument->_loadTemplate()
#15 /home/**/tst.****.org/libraries/src/Document/HtmlDocument.php(608): Joomla\CMS\Document\HtmlDocument->_fetchTemplate()
#16 /home/**/tst.****.org/libraries/src/Application/CMSApplication.php(1004): Joomla\CMS\Document\HtmlDocument->parse()
#17 /home/**/tst.****.org/libraries/src/Application/SiteApplication.php(714): Joomla\CMS\Application\CMSApplication->render()
#18 /home/**/tst.****.org/libraries/src/Application/CMSApplication.php(299): Joomla\CMS\Application\SiteApplication->render()
#19 /home/**/tst.****.org/includes/app.php(61): Joomla\CMS\Application\CMSApplication->execute()
#20 /home/**/tst.****.org/index.php(32): require_once('/home/**/...')
#21 {main}
```

you can try it here: tst.beetonrcflyers.org

any help to get this resolved would be appreciated.  I posted a similar question on gantry’s forum, but I suspect this is a CB issue

regards
Peter

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48536
  • Thanks: 8290
  • Karma: 1445
1 year 11 months ago #331855 by krileon
Replied by krileon on topic gantry 5 CB menu throws Exception
We're not the developers of Gantry 5 or your template. Please contact the developer of your template.

Why would you suspect CB? The error nor the stack trace has no mention of CB. The error points directly at them using an old version of Twig, which isn't compatible with your version of PHP (guessing 8.1 in this case). It appears to already be reported to them on Github.

github.com/gantry/gantry5/issues/3088


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: pludikar

Please Log in or Create an account to join the conversation.

  • pludikar
  • pludikar
  • OFFLINE
  • Posts: 3
  • Thanks: 1
  • Karma: 0
1 year 11 months ago #331856 by pludikar
Replied by pludikar on topic gantry 5 CB menu throws Exception
Many thanks for the prompt response. At least it gives me a clue where to push next.

BTW the reason I suspected CB was because it is the only Joomla component I have that misbehaves, but I’m happy to be shown that my suspicions were wrong.

Peter

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48536
  • Thanks: 8290
  • Karma: 1445
1 year 11 months ago #331857 by krileon
Replied by krileon on topic gantry 5 CB menu throws Exception

the reason I suspected CB was because it is the only Joomla component I have that misbehaves

Misbehaves in what way? If you're experiencing a bug in CB itself please be sure to report it. We certainly try to make CB as stable as possible.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • pludikar
  • pludikar
  • OFFLINE
  • Posts: 3
  • Thanks: 1
  • Karma: 0
1 year 11 months ago #331860 by pludikar
Replied by pludikar on topic gantry 5 CB menu throws Exception

the reason I suspected CB was because it is the only Joomla component I have that misbehaves

Misbehaves in what way? If you're experiencing a bug in CB itself please be sure to report it. We certainly try to make CB as stable as possible.
 
sorry for the confusion - misbehave => as in throwing the exception.  As you suggested it appears to be a stale twig version, but I was trying to say that CB was the only Joomla component that throws that exception. 

Peter
The following user(s) said Thank You: krileon

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum