bassangler Posted October 31, 2022 Share Posted October 31, 2022 I'm getting this error ever since I upgraded to the latest version 4.7.3 (theme was updated too). TypeError: flock(): Argument #1 ($stream) must be of type resource, bool given in /system/Theme/Cache/Template.php:90 Stack trace: #0 /system/Theme/Cache/Template.php(90): flock(false, 1) #1 /system/Theme/Theme.php(802): IPS\Theme\Cache\_Template->exists() #2 /applications/core/sources/Achievements/Rank.php(179): IPS\_Theme->getTemplate('global', 'core', 'global') #3 /uploads/template_28_7a734b11232065691bc1176040cb26ad_topics.php(2321): IPS\core\Achievements\_Rank->html('cAuthorPane_bad...') #4 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\Cache\class_forums_front_topics->postContainer(Object(IPS\forums\Topic), Object(IPS\forums\Topic\Post), Array, '') #5 /uploads/template_28_7a734b11232065691bc1176040cb26ad_topics.php(5116): IPS\Theme\_SandboxedTemplate->__call('postContainer', Array) #6 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\Cache\class_forums_front_topics->topic(Object(IPS\forums\Topic), Array, NULL, Array, NULL, NULL, Array) #7 /applications/forums/modules/front/forums/topic.php(576): IPS\Theme\_SandboxedTemplate->__call('topic', Array) #8 /system/Dispatcher/Controller.php(118): IPS\forums\modules\front\forums\_topic->manage() #9 /system/Content/Controller.php(50): IPS\Dispatcher\_Controller->execute() #10 /applications/forums/modules/front/forums/topic.php(39): IPS\Content\_Controller->execute() #11 /system/Dispatcher/Dispatcher.php(153): IPS\forums\modules\front\forums\_topic->execute() #12 /index.php(13): IPS\_Dispatcher->run() #13 {main} BACKTRACE #0 /system/Theme/SandboxedTemplate.php(71): IPS\_Log::log(Object(TypeError), 'template_error') #1 /uploads/template_28_7a734b11232065691bc1176040cb26ad_topics.php(5116): IPS\Theme\_SandboxedTemplate->__call('postContainer', Array) #2 /system/Theme/SandboxedTemplate.php(61): IPS\Theme\Cache\class_forums_front_topics->topic(Object(IPS\forums\Topic), Array, NULL, Array, NULL, NULL, Array) #3 /applications/forums/modules/front/forums/topic.php(576): IPS\Theme\_SandboxedTemplate->__call('topic', Array) #4 /system/Dispatcher/Controller.php(118): IPS\forums\modules\front\forums\_topic->manage() #5 /system/Content/Controller.php(50): IPS\Dispatcher\_Controller->execute() #6 /applications/forums/modules/front/forums/topic.php(39): IPS\Content\_Controller->execute() #7 /system/Dispatcher/Dispatcher.php(153): IPS\forums\modules\front\forums\_topic->execute() #8 /index.php(13): IPS\_Dispatcher->run() #9 {main} Link to comment Share on other sites More sharing options...
Marc Posted October 31, 2022 Share Posted October 31, 2022 Where is it you are seeing this on the site? Also could you please check this on a default unaltered theme, and ensure all 3rd party items are disabled? Link to comment Share on other sites More sharing options...
Martin A. Posted November 6, 2022 Share Posted November 6, 2022 Should catch the \TypeError exception thrown by flock() and/or check if $f isn't bool before using flock(). Link to comment Share on other sites More sharing options...
Recommended Posts