Jump to content

Featured Replies

Posted

Yesterday, I upgraded my IPS site from 4.7.0 to 4.7.1. Suddenly, I got numerous System error records into System log that indicates the issue within Calendar app. When I tried accessing Calendar, it shows the following error message:

Error: Call to undefined method DateTime::getDateInformation() (0)

My IPS site is running on PHP 8.1.9. There is no issue like this on IPS 4.7.0 with the same PHP version. Therefore, I'm pretty sure that this issue is not related to PHP. Also, I tried clearing system cache and disable / re-enable the Calendar app but still unable to resolve this issue.

Any help or suggestion would be appreciated. Thank you in advance for your support.

Could contain: Text

Could contain: Text

 

Solved by Stuart Silvester

Go to solution

Thanks for reporting this. I have moved this to a ticket so we can better investigate this for you. Please watch your email for further correspondence.

Identical issue, same behaviour. Also running PHP 8, IPS 4.7.1 with all patches (was not happening with 4.7.0). Started this morning.

Note: I can see individual calendars and add entries but not view the main/summary calendar page (/calendar) – that throws up exactly the same errors as described by @Foolboy.

-----------

Error: Call to undefined method DateTime::getDateInformation() (0)
#0 /applications/calendar/sources/Event/Event.php(363): IPS\calendar\_Event::_findOccurances(Object(IPS\calendar\Date), NULL, Object(IPS\calendar\Date), Object(IPS\calendar\Date), Array)
#1 /applications/calendar/sources/Event/Event.php(2127): IPS\calendar\_Event->findOccurrences(Object(IPS\calendar\Date), Object(IPS\calendar\Date))
#2 /applications/calendar/widgets/upcomingEvents.php(153): IPS\calendar\_Event::retrieveEvents(Object(IPS\calendar\Date), Object(IPS\calendar\Date), NULL, 3, false)
#3 /system/Widget/Widget.php(833): IPS\calendar\widgets\_upcomingEvents->render()
#4 /system/Widget/Widget.php(888): IPS\_Widget->_render()
#5 /system/Theme/Theme.php(885) : eval()'d code(18162): IPS\_Widget->__toString()
#6 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->widgetContainer('sidebar', 'vertical')
#7 /system/Theme/Theme.php(885) : eval()'d code(15399): IPS\Theme\_SandboxedTemplate->__call('widgetContainer', Array)
#8 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->sidebar('right')
#9 /system/Theme/Theme.php(885) : eval()'d code(6746): IPS\Theme\_SandboxedTemplate->__call('sidebar', Array)
#10 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->globalTemplate('ee2f54666441442...', '\n\n<div class='i...', Array)
#11 /system/Dispatcher/Dispatcher.php(173): IPS\Theme\_SandboxedTemplate->__call('globalTemplate', Array)
#12 /system/Dispatcher/Standard.php(113): IPS\_Dispatcher->finish()
#13 /system/Dispatcher/Front.php(625): IPS\Dispatcher\_Standard->finish()
#14 /system/Dispatcher/Dispatcher.php(155): IPS\Dispatcher\_Front->finish()
#15 /index.php(13): IPS\_Dispatcher->run()
#16 {main}

-----------

Edited by PoC2

Further investigation:

This error only occurs on the /calendar page when it is drawing in multiple calendars to display. If just one calendar is active (viewable) then no error.

Edited by PoC2

  • Author

Thank you. Based on the investigation from @PoC2 , I also found that only calendar with user-defined events will cause this issue. Blank calendars with only member's birthday will not throw this error. Even trying to add new event into the calendar will also cause this error. This is definitely a bug.

In my case I can view and add to any single calendar (including ones with user defined events) but again, not the summary view (/claendar) for displaying multiple calendars at once on a page.

Is this related to the recent patch?

 

 

Same

41 minutes ago, Giray said:

Same

I have created a ticket to investigate this further on your system.

Please do keep us informed when there's a fix available. 🙂

Thank you.

This seems to be an issue with the recent cPanel version, any chance you're also using it @PoC2?

 

We've been looking further into this today, it appears that a bug "fix" in PHP 8.0.22 & 8.1.9 has caused some issues - https://bugs.php.net/bug.php?id=80047 

I suspect this unannounced breaking change may cause issues in other software packages. The bug report suggests this change was actually intended for PHP 8.2 but was committed to 8.0/8.1 anyway.

We're working on a solution. I do not know at this time whether PHP might roll it back in the next release or not so we'll do something to work with either situation.

2 hours ago, Daniel F said:

This seems to be an issue with the recent cPanel version, any chance you're also using it @PoC2?

I probably am. 🙂 That would explain why 4.7.1 was fine one day and seemingly not the next!

9 minutes ago, Stuart Silvester said:

The bug report suggests this change was actually intended for PHP 8.2 but was committed to 8.0/8.1 anyway.

I'm on 8.0 rather than 8.2 so it looks like they've actually done that to the earlier version as well as you suggest.

10 minutes ago, Stuart Silvester said:

We're working on a solution. I do not know at this time whether PHP might roll it back in the next release or not so we'll do something to work with either situation.

Thank you. Invision support has always been superb and that means a lot.

Meanwhile I can tick along with just showing one calendar. Not a dealbreaker for me once I figured that out. 😉

Cheers!

I thought it is 3rd parties but actually my problem is same here

Error: Call to undefined method DateTime::getDateInformation() (0)
#0 /home/media/public_html/forum/applications/calendar/sources/Event/Event.php(363): IPS\calendar\_Event::_findOccurances(Object(IPS\calendar\Date), NULL, Object(IPS\calendar\Date), Object(IPS\calendar\Date), Array)
#1 /home/media/public_html/forum/applications/calendar/sources/Event/Event.php(2127): IPS\calendar\_Event->findOccurrences(Object(IPS\calendar\Date), Object(IPS\calendar\Date))
#2 /home/media/public_html/forum/applications/calendar/widgets/upcomingEvents.php(153): IPS\calendar\_Event::retrieveEvents(Object(IPS\calendar\Date), NULL, NULL, 5, false)
#3 /home/media/public_html/forum/system/Widget/Widget.php(833): IPS\calendar\widgets\_upcomingEvents->render()
#4 /home/media/public_html/forum/system/Widget/Widget.php(888): IPS\_Widget->_render()
#5 /home/media/public_html/forum/system/Theme/Theme.php(885) : eval()'d code(18416): IPS\_Widget->__toString()
#6 /home/media/public_html/forum/system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->widgetContainer('sidebar', 'vertical')
#7 /home/media/public_html/forum/system/Theme/Theme.php(885) : eval()'d code(15680): IPS\Theme\_SandboxedTemplate->__call('widgetContainer', Array)
#8 /home/media/public_html/forum/system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->sidebar('right')
#9 /home/media/public_html/forum/system/Theme/Theme.php(885) : eval()'d code(6787): IPS\Theme\_SandboxedTemplate->__call('sidebar', Array)
#10 /home/media/public_html/forum/system/Theme/SandboxedTemplate.php(61): IPS\Theme\class_core_front_global->globalTemplate('e3ca3fcdf018d96...', '\n\n<div class='i...', Array)
#11 /home/media/public_html/forum/system/Dispatcher/Dispatcher.php(173): IPS\Theme\_SandboxedTemplate->__call('globalTemplate', Array)
#12 /home/media/public_html/forum/system/Dispatcher/Standard.php(113): IPS\_Dispatcher->finish()
#13 /home/media/public_html/forum/system/Dispatcher/Front.php(625): IPS\Dispatcher\_Standard->finish()
#14 /home/media/public_html/forum/system/Dispatcher/Dispatcher.php(155): IPS\Dispatcher\_Front->finish()
#15 /home/media/public_html/forum/index.php(13): IPS\_Dispatcher->run()

PHP Version 8.1.9

Also, I am getting this on my forum homepage site....

Edited by media

Because it is effecting my home page my site is going down every time that triggers the error message

Temporally I have disabled the Calander app, looks like all good 

Switching back to PHP 7.4 should work too as a temporary fix in case disabling the calendar app is not an option.

See Stuarts message above also for full explanation of whats happening here @media

  • Solution

We have released a patch for 4.7.1 to workaround this issue.

To install, go to AdminCP > System > Support and click "optional patch available" in the top left block.

If you do not see this, you may already have the patch since it is included with and upgrades or downloads of the software after the date of this post.

  • Author
6 hours ago, Stuart Silvester said:

We have released a patch for 4.7.1 to workaround this issue.

To install, go to AdminCP > System > Support and click "optional patch available" in the top left block.

If you do not see this, you may already have the patch since it is included with and upgrades or downloads of the software after the date of this post.

Yep. This patch does the trick. Thank you very much for your support. 👍

You're welcome, glad the issue is resolved. 🙂

Thank you.

Recently Browsing 0

  • No registered users viewing this page.