I have installed a brand new install of 4.0.2.2
in the administration menus when entering data and for the site viewer we get the following error:
Warning: Zend OPcache API is restricted by "restrict_api" configuration directive in </mnt/location/mydomain.com>/web/storage/vendor/twig/twig/src/Cache/FilesystemCache.php on line 67
The message goes away when when i refresh the screen each time the message appears. I have read some conflicting messages that say to ignore this message.
However, If this is browser dependent, this would be a very bad look for customers who see the website and the first time they come in to view product they get an error message. They don't know that it may be 'nothing' .
So what is the permanent fix? Thanks.
in the administration menus when entering data and for the site viewer we get the following error:
Warning: Zend OPcache API is restricted by "restrict_api" configuration directive in </mnt/location/mydomain.com>/web/storage/vendor/twig/twig/src/Cache/FilesystemCache.php on line 67
The message goes away when when i refresh the screen each time the message appears. I have read some conflicting messages that say to ignore this message.
However, If this is browser dependent, this would be a very bad look for customers who see the website and the first time they come in to view product they get an error message. They don't know that it may be 'nothing' .
So what is the permanent fix? Thanks.
It's related to this issue in that it's a warning that Twig suppresses. https://github.com/opencart/opencart/issues/12483
Sadly it's been closed without fixing. You could follow my instructions on fixing at the above link or look at the fix for OpenCart 3.x for an idea. https://github.com/opencart/opencart/pull/10835
Sadly it's been closed without fixing. You could follow my instructions on fixing at the above link or look at the fix for OpenCart 3.x for an idea. https://github.com/opencart/opencart/pull/10835
Thank you I will follow on and read the other posts and see how to apply those to our situation.
you mention this has not been permanently fixed, sadly. I see that this error has been around for a while. But what is a head scratcher for me is that OC 4 requires PHP8. And php8 seems to be what throws the error. Therefore all new installs should get this error, ergo should'nt this be permanently fixed in the core distribution? just saying.
you mention this has not been permanently fixed, sadly. I see that this error has been around for a while. But what is a head scratcher for me is that OC 4 requires PHP8. And php8 seems to be what throws the error. Therefore all new installs should get this error, ergo should'nt this be permanently fixed in the core distribution? just saying.
Yes it should be fixed. It think the warning is dependent on the PHP opcache.restrict_api setting. https://www.php.net/manual/en/opcache.c ... strict-api
Not all servers will have the same setting so most users (including the OpenCart developer) probably don't see the warning.
Not all servers will have the same setting so most users (including the OpenCart developer) probably don't see the warning.
I posted a fix here, but sadly it's been rejected. https://github.com/opencart/opencart/pull/12660
Otherwise just make sure error display is switched off in your settings, config and PHP settings, then keep clearing your error logs.
Otherwise just make sure error display is switched off in your settings, config and PHP settings, then keep clearing your error logs.
Rainy Days In Georgia ...I posted a fix here, but sadly it's been rejected.

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Who is online
Users browsing this forum: No registered users and 2 guests