Posted: August 31, 2023 at 11:53 am
Hello, We’re having a strange production issue today. Attempting to edit an event produces a Fatal Error. This is only happening for one event – all other events seem to work fine. Perhaps there’s a data corruption issue with the event? We’re unable to grant access to the website, but hopefully the stack trace will help: PHP Fatal error: Uncaught Error: Object of class __PHP_Incomplete_Class could not be converted to string in /wp-includes/formatting.php:1104\\nStack trace:\\n#0 /wp-includes/formatting.php(4690): wp_check_invalid_utf8(Object(__PHP_Incomplete_Class))\\n#1 /wp-includes/post.php(2833): esc_attr(Object(__PHP_Incomplete_Class))\\n#2 /wp-includes/post.php(2733): sanitize_post_field(‘EE_Event’, Object(__PHP_Incomplete_Class), 13234, ‘edit’)\\n#3 /wp-includes/class-wp-post.php(367): sanitize_post(Object(WP_Post), ‘edit’)\\n#4 /wp-includes/post.php(1035): WP_Post->filter(‘edit’)\\n#5 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page_CPT.core.php(1438): get_post(13234, ‘OBJECT’, ‘edit’)\\n#6 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page.core.php(1142): EE_Admin_Page_CPT->_edit_cpt_item()\\n#7 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page_CPT.core.php(394): EE_Admin_Page->_route_admin_request()\\n#8 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page.core.php(747): EE_Admin_Page_CPT->_load_page_dependencies()\\n#9 /wp-includes/class-wp-hook.php(310): EE_Admin_Page->load_page_dependencies(”)\\n#10 /wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters(”, Array)\\n#11 /wp-includes/plugin.php(517): WP_Hook->do_action(Array)\\n#12 /wp-admin/admin.php(237): do_action(‘load-toplevel_p…’)\\n#13 {main}\\n\\nNext RuntimeException: Page route "_edit_cpt_item" with the supplied arguments () threw the following exception: Object of class __PHP_Incomplete_Class could not be converted to string in /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page.core.php:1150\\nStack trace:\\n#0 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page_CPT.core.php(394): EE_Admin_Page->_route_admin_request()\\n#1 /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page.core.php(747): EE_Admin_Page_CPT->_load_page_dependencies()\\n#2 /wp-includes/class-wp-hook.php(310): EE_Admin_Page->load_page_dependencies(”)\\n#3 /wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters(”, Array)\\n#4 /wp-includes/plugin.php(517): WP_Hook->do_action(Array)\\n#5 /wp-admin/admin.php(237): do_action(‘load-toplevel_p…’)\\n#6 {main}\\n thrown in /wp-content/plugins/event-espresso-core-reg/core/admin/EE_Admin_Page.core.php on line 1150, referer: https://skillbuilders.com/wp-admin/admin.php?s=tuning&_wpnonce=bbef246253&_wp_http_referer=%2Fwp-admin%2Fadmin.php%3Fpage%3Despresso_events&action=-1&month_range&active_status=none&venue&EVT_CAT=-1&use_filters=no&page=espresso_events&route=default&perpage=20&trash_events_nonce=92e3fd218d&paged=1&action2=-1&default_nonce=99b39e5480 |
|
Thank you. Can you give us more information about the system? Can you go to your EE Dashboard -> Help and Support. https://monosnap.com/file/b3zSACx5nwmyhLzgsGouVIw4tHgd0F Thanks |
|
Certainly… WordPress Version: 6.3.1 |
|
Have you recently deactivated any plugins/add-ons on the site? |
|
Not recently – is there a particular plugin that you have in mind? The error is only happening when trying to edit a particular Event. We can edit all other Events without issue. |
|
No plugin in mind. To explain why I’m asking, you will get that error if an object is serialised and saved to the database but then when it tries to load again it can’t find the class related to that object. PHP switches it to So, I was wondering it there was something saved with that event which now doesnr load on the site and causes the error. Hmm so yeah there’s something missing/corrupted I can’t tell you want from the above. If you can send over temp login details AND ftp credentials I can add some debug code to the site to see what is being pulled from the database which will hopefully shed some more light on what is going on. If that’s OK send them over using this form: |
|
Hello – now we’re seeing a different fatal error with the latest version of the plugin: Same user action (trying to edit an existing Event), but a different error. PHP Fatal error: Uncaught Error: Class “EE_Datetime_Field” not found in /wp-content/plugins/event-espresso-core-reg/core/domain/entities/DbSafeDateTime.php:170 |
|
Hello David, May we know if you get the chance to send your log-in details? Thanks. |
|
After a lot of research, we have the same issue as reported your forum here: https://eventespresso.com/topic/event-posts-unable-to-be-edited/ With Object Caching turned off, we see this error when creating a new Event, possibly relating to timestamp issues: “PHP Fatal error: Uncaught InvalidArgumentException: The "edit_tickets" array is invalid therefore the event can not be updated. in /nas/content/live/***/wp-content/plugins/event-espresso-core-reg/caffeinated/admin/extend/events/espresso_events_Events_Hooks_Extend.class.php:457” In the background, the event is actually created. We also notice that a number of old events now have publish timestamps of “Nov 30, 1999” which is a PHP default timestamp. So, my theory is at some point all events were updated/migrated along with an EE plugin update and there was a bug with datestamps. Now, the class DbSafeDateTime is breaking for an unknown reason relating to Object Caching. |
|
Hi there, The check for that exception is this:
So Can I take a look at the event to see if anything stands out? If so please send temp login details over using this form: https://eventespresso.com/send-login-details/ Include the ID of an event I can check this within the form on and I’ll take a look |
|
After performing some debugging on the plugin code, this seems to be related to Object Caching. With Object Caching enabled, the class Anyway, when Object Caching is enabled and
The issue is that This is why we get…
|
|
The support post ‘PHP Fatal error – Editing Event’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.