• Resolved mamekichi

    (@mamekichi)


    Hi,
    The number of pending orders always shows the same amount “50”.

    I found that wc_run_batch_process was failing with the following message:

    “get_class(): Argument #1 ($object) must be of type object, null given”

    What should I do to resolve it?

    The argument was

    0 => ‘Automattic\\WooCommerce\\Internal\\DataStores\\Orders\\DataSynchronizer’

    woocommerce 8.2.0
    WordPress6.3.2
    PHP8.2.3

Viewing 8 replies - 1 through 8 (of 8 total)
  • Hi,

    I have the same problem.
    Synchronization (WordPress and HPOS storage) no longer works correctly. I think this problem appeared since the last woocommerce update (8.2.0), because previously it worked.
    Here is the error message in the error_log file

    16-Oct-2023 13:02:58 UTC] WordPress database error Deadlock found when trying to get lock; try restarting transaction for query UPDATE qbwbo_actionscheduler_actions SET attempts = attempts+1, status=’in-progress’, last_attempt_gmt = ‘2023-10-16 13:02:58’, last_attempt_local = ‘2023-10-16 15:02:58’ WHERE action_id = 228571 made by do_action_ref_array(‘action_scheduler_run_queue’), WP_Hook->do_action, WP_Hook->apply_filters, ActionScheduler_QueueRunner->run, ActionScheduler_QueueRunner->do_batch, ActionScheduler_Abstract_QueueRunner->process_action, ActionScheduler_DBStore->log_execution

    Saif

    (@babylon1999)

    Hello @mamekichi,

    Thank you for reaching out!

    The number of pending orders always shows the same amount “50”.
    I found that wc_run_batch_process was failing with the following message:

    I wasn’t able to replicate this on the latest version of WooCommerce & WordPress.


    Link to image: https://d.pr/i/jYHaPZ

    Could you please try performing a full-conflict test before syncing to HPOS? Perhaps one of your plugins doesn’t support HPOS yet. :?)

    Let us know how it goes!

    Saif

    (@babylon1999)

    I understand you have the same problem @gilles24 but we need to handle each request individually in forums.

    Please open your own thread and make sure to include the following:

    – Your site’s System Status. You can find it via WooCommerce > Status. Select “Get system report” and then “Copy for support”.?
    – Some screenshots that describe the issue.?
    – It’s also worth checking if there are any fatal error logs from WooCommerce > Status > Logs and choosing from the drop-down menu the?fatal-errors.log?option.

    Thank you!

    Thread Starter mamekichi

    (@mamekichi)

    Hi,
    I disabled everything except woocommerce and wordfence, but the situation did not change.
    After rolling back Woocommerce version to 7.9 and back to 8.2.1, the number of pending orders decreased from 50 to 2!!
    Is there a way to find out which order the remaining two are?

    Hi,
    I was actually able to determine that the problem, in my case, was with the “in progress” status (physical products not yet shipped).
    When there are no more orders in progress, synchronization is carried out correctly.
    If this helps mamekichi

    Thread Starter mamekichi

    (@mamekichi)

    Hi,
    Thanks @babylon1999 @gilles24
    After executing Status>Tools>[Delete the custom orders tables]
    and starting wc_run_batch_process again,
    there are no pending orders.
    In the end, I didn’t know what caused this problem, but I was able to resolve it. Thank you!

    • This reply was modified 1 year, 5 months ago by mamekichi.

    “Delete the custom orders tables” works for me too…

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @mamekichi and @gilles24

    I’m glad you were able to find a solution to your inquiry here and thanks for sharing it with the community too! ??

    Should you have further inquiries, kindly create a new topic here.

    Thanks!

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘HPOS: wc_run_batch_process was failing’ is closed to new replies.