Skip Navigation

[Resolved] Lots of ‘Deprecated’ messages in PHP log

This thread is resolved. Here is a description of the problem and solution.

Problem: Toolset's plugins seem to be generating a large number of "Deprecated code (suppressed)" warnings in wp-admin. While not affecting the front-end of the site, it does tend to cause performance problems when using Query Monitor. What can we do to resolve the deprecated warnings?

Solution: Update to Types 3.3.10 to get the fix for this issue.

This support ticket is created 4 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

Tagged: 

This topic contains 9 replies, has 2 voices.

Last updated by geraldM 4 years, 1 month ago.

Assisted by: Christian Cox.

Author
Posts
#1473513

Dear Support,

I found Types is throwing lots and lots of 'Deprecated (Suppressed)' messages , all similar to this:

Passing a name as a first argument to the OTGS\Toolset\Twig\Environment::addFunction method is deprecated since version 1.21. Pass an instance of "Twig_SimpleFunction" instead when defining function "unique_name". in  wp-content/plugins/types/vendor/toolset/toolset-common/lib/Twig/src/Environment.php:1125

On some pages that make use of Toolset Views, over 800 of these are being generated with each call. I understant that this probably doesn't affect functioning of the site itself. But when I'm using 'Query Monitor', I experience severe slow-downs. Their support mentioned that a large number of PHP error messages could be the cause.

Is there any way to not have Types generate these messages, or fix the deprecation issue?

Thanks!

#1473667

Hello, this warning isn't normal, and you shouldn't see it generated by Toolset. I suspect something else is going on. First, be sure your site's WordPress version is up-to-date. Then, be sure your Toolset plugins are all up-to-date. If that does not solve the problem, please check and let me know if your site meets the minimum requirements for Toolset:
https://toolset.com/toolset-requirements/

Can you share your site debug information so I can see some of your configurations including your site's PHP version and other plugin versions? We have instructions for sharing debug information available here: https://toolset.com/faq/provide-debug-information-faster-support/

I see a similar warning message in this older ticket: https://toolset.com/forums/topic/warnings-and-deprecated-messages-wp-4-7-2/
Do you see any errors or warnings about open_basedir in effect?

#1473797

Thanks for getting back to me!

Yes, everything is up-to-date. I have attached the debug info as requested.

#1475045

Okay thank you, I have asked my 2nd tier support team to take a look because I was able to replicate some of these deprecation notices as well on my local environment. They seem to be specific to a third-party library used by Toolset, so I will try to find out if we can update that dependency. I'll let you know what I find out.

#1479431

Quick update to let you know my 2nd tier support team has escalated this to our developers for resolution. We hope to include an update to the Twig library in an upcoming release. That update should resolve the deprecated function messages and improve the performance of the site when Query Monitor is in use. I'll keep the ticket updated here when I receive more information about the schedule for that update and when the fix will be available. Thanks for the report, and I'll update you when I have more information.

#1480405

Thanks for looking into this, Christian!

#1482959

This will be resolved in the upcoming Types release, tentatively scheduled for tomorrow. I'll let you know when it's ready.

#1484327

Great! Once again, thanks for your excellent support!

#1484831

Hi, Types 3.3.10 has been released as scheduled. You can now use the automatic update feature to update, or you can download the plugin from https://toolset.com/account/downloads to update manually. Please update to the latest version and let me know if the deprecation notice issue is not completely resolved.

#1489251

I just updated the plugin. Types now no longer generates any deprecation notices for me. Thank you!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.