Title: Fatal error using ORM with Object Caching
Last modified: September 1, 2026

---

# Fatal error using ORM with Object Caching

 *  Resolved [Brian Hogg](https://wordpress.org/support/users/brianhogg/)
 * (@brianhogg)
 * [2 weeks, 1 day ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/)
 * In the latest version, running a query like this:
 *     ```wp-block-code
       tribe_events()->by( 'id', $post->ID )->first()->venues
       ```
   
 * results in a fatal error:
 *     ```wp-block-code
       TypeError: call_user_func(): Argument #1 ($callback) must be a valid callback, no array or string given#0 /wp-content/plugins/the-events-calendar/common/src/Tribe/Utils/Lazy_Collection.php(86): call_user_func#1 /wp-content/plugins/the-events-calendar/common/src/Tribe/Utils/Lazy_Collection.php(86): Tribe\Utils\Lazy_Collection::resolve#2 /wp-content/plugins/the-events-calendar/common/src/Tribe/Utils/Lazy_Collection.php(71): Tribe\Utils\Lazy_Collection::all#3 /wp-content/plugins/the-events-calendar/common/src/Tribe/Utils/Collection_Trait.php(125): Tribe\Utils\Lazy_Collection::valid
       ```
   
 * Disabling object caching resolves it. The workaround is to fetch venue and organizer
   IDs using `tec_get_venue_ids`, `tec_get_venue_id` or directly via `get_post_meta(
   $post_id, '_EventVenueID' );` but ideally using the ORM as before wouldn’t cause
   a fatal error.
 * If any other details are needed, let me know. Thanks!
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ffatal-error-using-orm-with-object-caching%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 8 replies - 1 through 8 (of 8 total)

 *  Plugin Author [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/)
 * (@dpantazis)
 * [2 weeks, 1 day ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19008710)
 * Hey [@brianhogg](https://wordpress.org/support/users/brianhogg/) ,
   Thanks for
   reaching out with your issue. Your report seems quite detailed, we will take 
   a look to try and reproduce it.If we can, we will fix it. If not, we will reach
   out to you for more details.Thank you for using The Events Calendar.
    -  This reply was modified 2 weeks, 1 day ago by [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/).
 *  [ajeffcoat](https://wordpress.org/support/users/ajeffcoat/)
 * (@ajeffcoat)
 * [2 weeks, 1 day ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19009100)
 * I can confirm what appears to be the same issue on a production site.
 * Versions:
    - The Events Calendar 6.17.3.1
    - Event Tickets 5.29.3.1
    - Redis Object Cache 2.8.0
    - PHP 8.2.33
    - WordPress running under Plesk/AlmaLinux
 * The site began intermittently producing critical errors after the recent TEC/
   Event Tickets updates.
 * The PHP fatal is:
 * PHP Fatal error: Uncaught TypeError: call_user_func(): Argument #1 ($callback)
   must be a valid callback, no array or string given in /wp-content/plugins/event-
   tickets/common/src/Tribe/Utils/Lazy_Collection.php:86
 * Stack trace includes:
 * Tribe\Utils\Lazy_Collection->resolve()
   Tribe\Utils\Lazy_Collection->all()Tribe\
   Utils\Lazy_Collection->__serialize()serialize()WP_Object_Cache
 * I confirmed that The Events Calendar and Event Tickets contain identical copies
   of Lazy_Collection.php.
 * We use Redis Object Cache with a site-specific cache key salt. I identified approximately
   2,186 keys in the `tribe-events`Redis cache group.
 * As a test, I removed only this site’s `tribe-events` Redis keys. The cache immediately
   began rebuilding and the same Lazy_Collection.php:86 fatal returned within seconds.
   Therefore, simply clearing the object cache does not resolve the problem.
 * I then disabled Redis Object Cache for this WordPress installation. The `object-
   cache.php` drop-in was removed and the fatal errors immediately stopped.
 * After approximately 10 minutes of additional site traffic, no new Lazy_Collection.
   php:86 errors were logged. The site is currently operating normally with persistent
   object caching disabled.
 * I also tested PHP 8.2 and PHP 8.3 during troubleshooting. The problem occurs 
   under PHP 8.2 as well, so this does not appear to be specific to PHP 8.3.
 * I have left Redis Object Cache disabled on this site as a temporary workaround.
 * Please let me know if additional logs, Redis key examples, or system information
   would help reproduce this.
 *  Plugin Author [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/)
 * (@dpantazis)
 * [2 weeks ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19009933)
 * Thank you [@ajeffcoat](https://wordpress.org/support/users/ajeffcoat/) and [@brianhogg](https://wordpress.org/support/users/brianhogg/)!
   We were able to reproduce the issue and we already have implemented a fix. We
   are aiming to include it in our next release. I will let you know when its out.
   
   Once again thank you for the report!
 *  [guillaumejoubert](https://wordpress.org/support/users/guillaumejoubert/)
 * (@guillaumejoubert)
 * [2 weeks ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19010019)
 * Bonjour j’ai un message d’erreur sur cette page : [https://culturemarche.com/agenda-marche-2026/](https://culturemarche.com/agenda-marche-2026/)
 * cela fait deux jours et malgré les renseignements de wordpress, aucun dépannage…
   comment faire pour que cette page soit de nouveaux accessibles ?
 *  [guillaumejoubert](https://wordpress.org/support/users/guillaumejoubert/)
 * (@guillaumejoubert)
 * [2 weeks ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19010257)
 * Lorsque vous les contacterez, veuillez inclure l’erreur fatale PHP que nous avons
   partagée précédemment, en particulier cette partie :
 * `Call to a member function count() on null in .../the-events-calendar/src/views/
   v2/list/event/[venue.php](https://venue.php/):23` (traduit par IA)
 *  [NumanZahid](https://wordpress.org/support/users/numanzahid/)
 * (@numanzahid)
 * [1 week, 6 days ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19010688)
 * Hi [@dpantazis](https://wordpress.org/support/users/dpantazis/),
 * Thanks for confirming you were able to reproduce this and that a fix is planned
   for the next release.
 * We are seeing the same issue on a production site (The Events Calendar 6.17.3.1,
   Event Tickets 5.29.3.1, with Redis object caching on Cloudways Autonomous). The
   site was down intermittently with the same Lazy_Collection.php:86 fatal error.
 * Could you share an estimated timeline for when the fix will be released? We need
   to plan next steps with our client, since disabling object cache is not an option
   on our hosting setup.
 * Thanks.
 *  Plugin Author [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/)
 * (@dpantazis)
 * [1 week, 6 days ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19011115)
 * Hey once again to all of you! Version **6.17.4** is out and it should be fixing
   that issue. Please test it out by updating safely – we always recommend testing
   the updates in a staging site and taking a backup of a production site before
   you apply them, but it should be smooth sailing – and let me know!
   Thank you
 *  Plugin Author [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/)
 * (@dpantazis)
 * [1 week, 3 days ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19012927)
 * Hey since I haven’t heard back from you for a while, im going to go ahead and
   assume that the issue is resolved for you and mark as such this ticket. If by
   any chance you are still facing this issue, please open a new ticket.
   Thank you!

Viewing 8 replies - 1 through 8 (of 8 total)

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ffatal-error-using-orm-with-object-caching%2F%3Foutput_format%3Dmd&locale=en_US)
to reply to this topic.

 * ![](https://ps.w.org/the-events-calendar/assets/icon-256x256.gif?rev=2516440)
 * [The Events Calendar](https://wordpress.org/plugins/the-events-calendar/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/the-events-calendar/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/the-events-calendar/)
 * [Active Topics](https://wordpress.org/support/plugin/the-events-calendar/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/the-events-calendar/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/the-events-calendar/reviews/)

 * 8 replies
 * 5 participants
 * Last reply from: [Dimitris Pantazis](https://wordpress.org/support/users/dpantazis/)
 * Last activity: [1 week, 3 days ago](https://wordpress.org/support/topic/fatal-error-using-orm-with-object-caching/#post-19012927)
 * Status: resolved