Title: query in debug.log
Last modified: August 28, 2021

---

# query in debug.log

 *  Resolved [islp](https://wordpress.org/support/users/islp/)
 * (@islp)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/query-in-debug-log/)
 * Hi, I found the following in my debug.log file:
 * > `[11-Aug-2021 05:23:12 UTC] WordPress database error Deadlock found when trying
   > to get lock; try restarting transaction for query DELETE FROM`wp_options`WHERE`
   > option_name`= '_transient__wpmem_hidden_posts' made by require('wp-blog-header.
   > php'), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts,
   > do_action_ref_array('pre_get_posts'), WP_Hook->do_action, WP_Hook->apply_filters,
   > WP_Members->do_hide_posts, WP_Members->get_hidden_posts, WP_Members->hidden_posts,
   > get_transient, delete_option`
 * Is this something I should worry about?

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

 *  Plugin Author [Chad Butler](https://wordpress.org/support/users/cbutlerjr/)
 * (@cbutlerjr)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/query-in-debug-log/#post-14818820)
 * A deadlock occurs when two (or more) db transactions mutually hold a request 
   for locks.
 * WP-Members doesn’t request locks on the db, and I’m uncertain as to whether WP
   does.
 * The db transaction that is likely happening at the point of this error (at least
   from where WP-Members is concerned) is the transient that holds the IDs of hidden
   posts is being rewritten. When the transient is checked, if it is expired (if
   it is more than 5 minutes old, in the present version), then a query is run to
   get hidden posts, the old transient is deleted, and a new transient is created.
 * That by itself wouldn’t (shouldn’t?) cause a deadlock, but if you had something
   running before it that did, that would be the reason.
 * If it’s a “one-off” and doesn’t occur again, then you can ignore it. The hidden
   posts transient will be updated the next time it is checked.
 *  Thread Starter [islp](https://wordpress.org/support/users/islp/)
 * (@islp)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/query-in-debug-log/#post-14818846)
 * Ok, thanks for the kind explanation 🙂

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

The topic ‘query in debug.log’ is closed to new replies.

 * ![](https://ps.w.org/wp-members/assets/icon-256x256.png?rev=1226414)
 * [WP-Members Membership Plugin](https://wordpress.org/plugins/wp-members/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-members/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-members/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-members/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-members/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-members/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [islp](https://wordpress.org/support/users/islp/)
 * Last activity: [4 years, 9 months ago](https://wordpress.org/support/topic/query-in-debug-log/#post-14818846)
 * Status: resolved