Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CRITICAL Uncaught InvalidArgumentException: The group "rocket-rucss" does not exist. #972

Closed
alewolf opened this issue Aug 2, 2023 · 22 comments
Labels
needs feedback The issue/PR needs a response from any of the parties involved in the issue. type: task The issue is an internally driven task (e.g. from another A8c team). type: technical debt This issue/PR represents/solves the technical debt of the project.

Comments

@alewolf
Copy link

alewolf commented Aug 2, 2023

On some installs, our users get a CRITICAL Uncaught InvalidArgumentException: The group "rocket-rucss" does not exist. error.

This might be related to #882 and #970.

This should be fixed or a safeguard built in to prevent the critical error.

Here's the error log:

2023-08-02T00:02:12+00:00 CRITICAL Uncaught InvalidArgumentException: The group "rocket-rucss" does not exist. in /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php:907
Stack trace:
#0 /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php(799): ActionScheduler_DBStore->claim_actions(392029, 25, NULL, '', 'rocket-rucss')
#1 /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/ActionScheduler_QueueRunner.php(157): ActionScheduler_DBStore->stake_claim(25)
#2 /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/ActionScheduler_QueueRunner.php(136): ActionScheduler_QueueRunner->do_batch(25, 'WP Cron')
#3 /usr/www/users/redacted/wp-includes/class-wp-hook.php(307): ActionScheduler_QueueRunner->run('WP Cron')
#4 /usr/www/users/redacted/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters('', Array)
#5 /usr/www/users/redacted/wp-includes/plugin.php(522): WP_Hook->do_action(Array)
#6 /usr/www/users/redacted/wp-cron.php(138): do_action_ref_array('action_schedule...', Array)
#7 {main}
  thrown in /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php on line 907
@rrennick
Copy link
Contributor

rrennick commented Aug 3, 2023

@alewolf Thanks for reporting the issue. By default Action Scheduler does not filter by groups when running actions.

However, if you install WP Crontrol you may be able to find the offending cron job and delete it. If you have recently removed or deactivated a plugin then look for a cron job associated with that plugin.

We'll leave this issue open as a reminder to evaluate how to handle this exception.

@rrennick rrennick added the type: task The issue is an internally driven task (e.g. from another A8c team). label Aug 3, 2023
@alewolf
Copy link
Author

alewolf commented Aug 3, 2023

@rrennick This was reported to me by a user of my plugin, the Pixel Manager for WooCommerce /woocommerce-google-adwords-conversion-tracking-tag/.

I can't replicate the error because it doesn't occur on my installs.

The way the Action Scheduler works, it can be a third-party plugin triggering the error. But the Action Scheduler is executed from the Pixel Manager folder because I pack the newest version, so the error log shows /woocommerce-google-adwords-conversion-tracking-tag/.

That's why I get the support requests. I assume many other users are blaming the Pixel Manager without telling me.

I'm considering downgrading the Action Scheduler version in the Pixel Manager to one version lower than the one packed with WooCommerce to avoid that problem and redirect support requests to WooCommerce that way. But that would not be a good solution on a larger scale.

@rrennick
Copy link
Contributor

rrennick commented Aug 3, 2023

@alewolf Thanks for the quick follow up. Can you ask one of the customers for their Woo SSR? Hopefully the rocket-rucss slug will point to an inactive plugin in their install.

@alewolf
Copy link
Author

alewolf commented Aug 3, 2023

@rrennick What do you mean by "Woo SSR" ?

@piotrbak
Copy link

piotrbak commented Aug 4, 2023

@alewolf @rrennick rocket-rucss is related to WP Rocket plugin:
https://github.com/wp-media/wp-rocket/blob/901911571c027b0b4a5979651a52ef3c0edfbe5f/inc/Engine/Optimization/RUCSS/Controller/Queue.php#L22

I'd suggest asking customer to contact our Support Team, I can see that we had one case like this in the pas but we were not able to reproduce this problem. If it's reproducible, it would be great to provide us access to this website.

@rrennick
Copy link
Contributor

rrennick commented Aug 4, 2023

@alewolf Sorry, SSR refers to the Woo System Status Report.

@piotrbak Thanks for chiming in on this one.

@rrennick rrennick added the type: technical debt This issue/PR represents/solves the technical debt of the project. label Aug 4, 2023
@alewolf
Copy link
Author

alewolf commented Aug 5, 2023

@piotrbak @rrennick I've sent our customer the link to this issue and encouraged him to contact you.

@sagestephens
Copy link

Hi I am the customer with the issue do you need my website link?

@barryhughes
Copy link
Member

@sagestephens (and @alewolf), we're a little confused as to what is happening here. Flipping the backtrace upside down, here are how things seem to be unfolding:

#6 /usr/www/users/redacted/wp-cron.php(138): 
do_action_ref_array('action_schedule...', Array)

☝🏼 We basically start here, inside WP's cron code. This means WordPress is in the middle of processing any scheduled events that have been registered and, in this case, that seems to mean the Action Scheduler queue runner event.

#3 /usr/www/users/redacted/wp-includes/class-wp-hook.php(307): 
ActionScheduler_QueueRunner->run('WP Cron')

☝🏼 I think we can skip a few entries until we get here. Note that this method only accepts one parameter (the context, which in this case will be 'wp-cron').

ActionScheduler_QueueRunner->do_batch(25, 'WP Cron')

☝️ Next, the do_batch() method is called, which then tries to 'stake a claim'.

#1 /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/ActionScheduler_QueueRunner.php(157): 
ActionScheduler_DBStore->stake_claim(25)

☝️ Here we are, staking a claim and the only information we pass is the number of actions we want to claim (25, based on the backtrace).

#0 /usr/www/users/redacted/wp-content/plugins/woocommerce-google-adwords-conversion-tracking-tag/vendor/woocommerce/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php(799):
ActionScheduler_DBStore->claim_actions(392029, 25, NULL, '', 'rocket-rucss')

☝️ Closing in on the point-of-failure, when we try to claim the actual actions the default behavior would be to not specify any group (see code here) yet the backtrace tells us rocket-rucss is being specified.

This is what's confusing us (ie, where is rocket-rucss coming from) ... is it possible that this code was manually modified? If (@sagestephens) you re-install woocommerce-google-adwords-conversion-tracking-tag from source, does the same problem persist?

@barryhughes barryhughes added the needs feedback The issue/PR needs a response from any of the parties involved in the issue. label Aug 16, 2023
@PanosSynetos
Copy link

We have another report of the same issue in https://wordpress.org/support/topic/customers-is-not-working/#post-17011606

InvalidArgumentException: Группы «rocket-rucss» не существует.
InvalidArgumentException: Group 'rocket-rucss' does not exist.

rocket-rucss is coming from WP Rocket as @piotrbak mentioned about a month ago

https://github.com/wp-media/wp-rocket/blob/901911571c027b0b4a5979651a52ef3c0edfbe5f/inc/Engine/Optimization/RUCSS/Controller/Queue.php#L22

2023-08-30T00:19:30+00:00 CRITICAL Uncaught InvalidArgumentException: Группы «rocket-rucss» не существует. in /var/www/u1894878/data/www/studio-parfum.ru/wp-content/plugins/woocommerce/packages/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php:907
Stack trace:
#0 /var/www/u1894878/data/www/studio-parfum.ru/wp-content/plugins/woocommerce/packages/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php(799): ActionScheduler_DBStore->claim_actions(9761, 25, NULL, '', 'rocket-rucss')
#1 /var/www/u1894878/data/www/studio-parfum.ru/wp-content/plugins/woocommerce/packages/action-scheduler/classes/ActionScheduler_QueueRunner.php(157): ActionScheduler_DBStore->stake_claim(25)
#2 /var/www/u1894878/data/www/studio-parfum.ru/wp-content/plugins/woocommerce/packages/action-scheduler/classes/ActionScheduler_QueueRunner.php(136): ActionScheduler_QueueRunner->do_batch(25, 'WP Cron')
#3 /var/www/u1894878/data/www/studio-parfum.ru/wp-includes/class-wp-hook.php(310): ActionScheduler_QueueRunner->run('WP Cron')
#4 /var/www/u1894878/data/www/studio-parfum.ru/wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters('', Array)
#5 /var/www/u1894878/data/www/studio-parfum.ru/wp-includes/plugin.php(565): WP_Hook->do_action(Array)
#6 /var/www/u1894878/data/www/studio-parfum.ru/wp-cron.php(191): do_action_ref_array('action_schedule...', Array)
#7 {main}
  thrown в /var/www/u1894878/data/www/studio-parfum.ru/wp-content/plugins/woocommerce/packages/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php на строке 907

@barryhughes
Copy link
Member

Thanks, @PanosSynetos. I somehow missed (or misinterpreted) @piotrbak's note. Given this is the result of a custom queue runner, it seems appropriate to close this (the raised exception does not seem inappropriate to me). For anyone else experiencing this problem, please do reach out to the WP Rocket team.

@engahmeds3ed
Copy link

@barryhughes @rrennick

May I ask why here:

$group_ids = $this->get_group_ids( $group, false );

$create_if_not_exists argument is false?

@barryhughes
Copy link
Member

Hi @engahmeds3ed,

This method is responsible for claiming actions. So, I'd flip the question around: if the specified group or groups do not already exist, and so there are no actions to be claimed, why would we create one or more empty groups? It doesn't feel to me like a step the claiming process should take.

Building on that, my initial thoughts are that it seems reasonable for us to avoid creating empty groups and also that it is the responsibility of any custom code calling this method to anticipate and catch any exceptions it might throw.

Let me know your thoughts (though, Ron may also have valuable input to add on this one).

@rrennick
Copy link
Contributor

rrennick commented Sep 5, 2023

Ron may also have valuable input to add on this one

I agree. We should not be creating groups during the claim process.

@engahmeds3ed
Copy link

That's a valid point, thanks @barryhughes @rrennick for taking time explaining that.

@engahmeds3ed
Copy link

After some investigation about this issue, let me share with u my findings so u can decide if we need to fix that in action Scheduler's core or not.

Assume we have a custom queue runner like this one and as u see, there we are not setting the store object so it's null exactly like the default queue runner here
and both (custom runner and default runner) are running every_minute.

So Based on that code, both runners will share the store instance (because it's singleton design pattern).

What happens here is that the custom runner is running before the default runner passing the group to the store stake_claim method here

and based on that code that was added in this pull request you are setting the group item inside claim_filters and as we use the same object for store in both queue runners, the group will be kept the one that added in the custom queue runner.

You can also check the following full backtrace:

array (
  0 => 
  array (
    'file' => '/var/www/html/wordpress/wp-content/plugins/action-scheduler/classes/data-stores/ActionScheduler_DBStore.php',
    'line' => 799,
    'function' => 'claim_actions',
    'class' => 'ActionScheduler_DBStore',
    'object' => 
    ActionScheduler_DBStore::__set_state(array(
       'claim_before_date' => NULL,
       'claim_filters' => 
      array (
        'group' => 'rocket-rucss',
        'hooks' => '',
        'exclude-groups' => '',
      ),
    )),
    'type' => '->',
    'args' => 
    array (
      0 => 13316,
      1 => 25,
      2 => NULL,
      3 => '',
      4 => 'rocket-rucss',
    ),
  ),
  1 => 
  array (
    'file' => '/var/www/html/wordpress/wp-content/plugins/action-scheduler/classes/ActionScheduler_QueueRunner.php',
    'line' => 160,
    'function' => 'stake_claim',
    'class' => 'ActionScheduler_DBStore',
    'object' => 
    ActionScheduler_DBStore::__set_state(array(
       'claim_before_date' => NULL,
       'claim_filters' => 
      array (
        'group' => 'rocket-rucss',
        'hooks' => '',
        'exclude-groups' => '',
      ),
    )),
    'type' => '->',
    'args' => 
    array (
      0 => 25,
    ),
  ),
  2 => 
  array (
    'file' => '/var/www/html/wordpress/wp-content/plugins/action-scheduler/classes/ActionScheduler_QueueRunner.php',
    'line' => 139,
    'function' => 'do_batch',
    'class' => 'ActionScheduler_QueueRunner',
    'object' => 
    ActionScheduler_QueueRunner::__set_state(array(
       'async_request' => 
      ActionScheduler_AsyncRequest_QueueRunner::__set_state(array(
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'prefix' => 'as',
         'action' => 'async_request_queue_runner',
         'identifier' => 'as_async_request_queue_runner',
         'data' => 
        array (
        ),
      )),
       'processed_actions_count' => 0,
       'cleaner' => 
      ActionScheduler_QueueCleaner::__set_state(array(
         'batch_size' => 20,
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'month_in_seconds' => 2678400,
         'default_statuses_to_purge' => 
        array (
          0 => 'complete',
          1 => 'canceled',
        ),
      )),
       'monitor' => 
      ActionScheduler_FatalErrorMonitor::__set_state(array(
         'claim' => NULL,
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'action_id' => 0,
      )),
       'store' => 
      ActionScheduler_DBStore::__set_state(array(
         'claim_before_date' => NULL,
         'claim_filters' => 
        array (
          'group' => 'rocket-rucss',
          'hooks' => '',
          'exclude-groups' => '',
        ),
      )),
       'created_time' => 1693943820.477584,
    )),
    'type' => '->',
    'args' => 
    array (
      0 => 25,
      1 => 'WP Cron',
    ),
  ),
  3 => 
  array (
    'file' => '/var/www/html/wordpress/wp-includes/class-wp-hook.php',
    'line' => 308,
    'function' => 'run',
    'class' => 'ActionScheduler_QueueRunner',
    'object' => 
    ActionScheduler_QueueRunner::__set_state(array(
       'async_request' => 
      ActionScheduler_AsyncRequest_QueueRunner::__set_state(array(
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'prefix' => 'as',
         'action' => 'async_request_queue_runner',
         'identifier' => 'as_async_request_queue_runner',
         'data' => 
        array (
        ),
      )),
       'processed_actions_count' => 0,
       'cleaner' => 
      ActionScheduler_QueueCleaner::__set_state(array(
         'batch_size' => 20,
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'month_in_seconds' => 2678400,
         'default_statuses_to_purge' => 
        array (
          0 => 'complete',
          1 => 'canceled',
        ),
      )),
       'monitor' => 
      ActionScheduler_FatalErrorMonitor::__set_state(array(
         'claim' => NULL,
         'store' => 
        ActionScheduler_DBStore::__set_state(array(
           'claim_before_date' => NULL,
           'claim_filters' => 
          array (
            'group' => 'rocket-rucss',
            'hooks' => '',
            'exclude-groups' => '',
          ),
        )),
         'action_id' => 0,
      )),
       'store' => 
      ActionScheduler_DBStore::__set_state(array(
         'claim_before_date' => NULL,
         'claim_filters' => 
        array (
          'group' => 'rocket-rucss',
          'hooks' => '',
          'exclude-groups' => '',
        ),
      )),
       'created_time' => 1693943820.477584,
    )),
    'type' => '->',
    'args' => 
    array (
      0 => 'WP Cron',
    ),
  ),
  4 => 
  array (
    'file' => '/var/www/html/wordpress/wp-includes/class-wp-hook.php',
    'line' => 332,
    'function' => 'apply_filters',
    'class' => 'WP_Hook',
    'object' => 
    WP_Hook::__set_state(array(
       'callbacks' => 
      array (
        10 => 
        array (
          '000000000b907149000000004766d3efrun' => 
          array (
            'function' => 
            array (
              0 => 
              ActionScheduler_QueueRunner::__set_state(array(
                 'async_request' => 
                ActionScheduler_AsyncRequest_QueueRunner::__set_state(array(
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'prefix' => 'as',
                   'action' => 'async_request_queue_runner',
                   'identifier' => 'as_async_request_queue_runner',
                   'data' => 
                  array (
                  ),
                )),
                 'processed_actions_count' => 0,
                 'cleaner' => 
                ActionScheduler_QueueCleaner::__set_state(array(
                   'batch_size' => 20,
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'month_in_seconds' => 2678400,
                   'default_statuses_to_purge' => 
                  array (
                    0 => 'complete',
                    1 => 'canceled',
                  ),
                )),
                 'monitor' => 
                ActionScheduler_FatalErrorMonitor::__set_state(array(
                   'claim' => NULL,
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'action_id' => 0,
                )),
                 'store' => 
                ActionScheduler_DBStore::__set_state(array(
                   'claim_before_date' => NULL,
                   'claim_filters' => 
                  array (
                    'group' => 'rocket-rucss',
                    'hooks' => '',
                    'exclude-groups' => '',
                  ),
                )),
                 'created_time' => 1693943820.477584,
              )),
              1 => 'run',
            ),
            'accepted_args' => 1,
          ),
        ),
      ),
       'iterations' => 
      array (
        0 => 
        array (
          0 => 10,
        ),
      ),
       'current_priority' => 
      array (
        0 => 10,
      ),
       'nesting_level' => 1,
       'doing_action' => true,
    )),
    'type' => '->',
    'args' => 
    array (
      0 => '',
      1 => 
      array (
        0 => 'WP Cron',
      ),
    ),
  ),
  5 => 
  array (
    'file' => '/var/www/html/wordpress/wp-includes/plugin.php',
    'line' => 565,
    'function' => 'do_action',
    'class' => 'WP_Hook',
    'object' => 
    WP_Hook::__set_state(array(
       'callbacks' => 
      array (
        10 => 
        array (
          '000000000b907149000000004766d3efrun' => 
          array (
            'function' => 
            array (
              0 => 
              ActionScheduler_QueueRunner::__set_state(array(
                 'async_request' => 
                ActionScheduler_AsyncRequest_QueueRunner::__set_state(array(
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'prefix' => 'as',
                   'action' => 'async_request_queue_runner',
                   'identifier' => 'as_async_request_queue_runner',
                   'data' => 
                  array (
                  ),
                )),
                 'processed_actions_count' => 0,
                 'cleaner' => 
                ActionScheduler_QueueCleaner::__set_state(array(
                   'batch_size' => 20,
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'month_in_seconds' => 2678400,
                   'default_statuses_to_purge' => 
                  array (
                    0 => 'complete',
                    1 => 'canceled',
                  ),
                )),
                 'monitor' => 
                ActionScheduler_FatalErrorMonitor::__set_state(array(
                   'claim' => NULL,
                   'store' => 
                  ActionScheduler_DBStore::__set_state(array(
                     'claim_before_date' => NULL,
                     'claim_filters' => 
                    array (
                      'group' => 'rocket-rucss',
                      'hooks' => '',
                      'exclude-groups' => '',
                    ),
                  )),
                   'action_id' => 0,
                )),
                 'store' => 
                ActionScheduler_DBStore::__set_state(array(
                   'claim_before_date' => NULL,
                   'claim_filters' => 
                  array (
                    'group' => 'rocket-rucss',
                    'hooks' => '',
                    'exclude-groups' => '',
                  ),
                )),
                 'created_time' => 1693943820.477584,
              )),
              1 => 'run',
            ),
            'accepted_args' => 1,
          ),
        ),
      ),
       'iterations' => 
      array (
        0 => 
        array (
          0 => 10,
        ),
      ),
       'current_priority' => 
      array (
        0 => 10,
      ),
       'nesting_level' => 1,
       'doing_action' => true,
    )),
    'type' => '->',
    'args' => 
    array (
      0 => 
      array (
        0 => 'WP Cron',
      ),
    ),
  ),
  6 => 
  array (
    'file' => '/var/www/html/wordpress/wp-cron.php',
    'line' => 188,
    'function' => 'do_action_ref_array',
    'args' => 
    array (
      0 => 'action_scheduler_run_queue',
      1 => 
      array (
        0 => 'WP Cron',
      ),
    ),
  ),
)

what do u think @barryhughes @rrennick ?

@rrennick
Copy link
Contributor

rrennick commented Sep 6, 2023

So Based on that code, both runners will share the store instance (because it's singleton design pattern).

@alewolf Simgletons are not shared among worker threads/processes. Each thread will have its own singleton.

@engahmeds3ed
Copy link

I believe WP Cron is calling both of CRON schedules in the same thread/request.

List of crons are being fetched here:
https://github.com/WordPress/wordpress-develop/blob/240f914e4f4bc28bba0d0705ade7d08a45487350/src/wp-cron.php#L84

and then Core is looping on them here:
https://github.com/WordPress/wordpress-develop/blob/240f914e4f4bc28bba0d0705ade7d08a45487350/src/wp-cron.php#L191

I believe that's because both of them are running every minute and used time() so both are on the same thread already.

The trace is showing that.

@rrennick
Copy link
Contributor

rrennick commented Sep 6, 2023

that was added in this #905 you are setting the group item inside claim_filters

That PR only changes the WP CLI run command where the context is WP CLI. The WP cron runner is https://github.com/woocommerce/action-scheduler/blob/trunk/classes/ActionScheduler_QueueRunner.php.

@rrennick
Copy link
Contributor

rrennick commented Sep 6, 2023

I believe WP Cron is calling both of CRON schedules in the same thread/request.

@alewolf Also, you are getting sidetracked from the root issue which is that the AS group does not exist. The custom runner is trying to claim actions from that group.

@engahmeds3ed
Copy link

That PR only changes the WP CLI run command where the context is WP CLI. The WP cron runner is https://github.com/woocommerce/action-scheduler/blob/trunk/classes/ActionScheduler_QueueRunner.php.

u changed in the store class here:
https://github.com/woocommerce/action-scheduler/pull/905/files#diff-187a2644998973fd6a8b8e9455ad006ad4d502273b21f76607137c7c0acf9f1bR861

@alewolf Also, you are getting sidetracked from the root issue which is that the AS group does not exist. The custom runner is trying to claim actions from that group.

I know exactly what I'm saying, I'm not getting sidetracked at all, I'm very clear with full trace and every line of code.

Anyway, I'll stop here and fix this in our side by creating our own store, just consider this conversation if u want/need.

Thanks for ur time.

@rrennick
Copy link
Contributor

rrennick commented Sep 6, 2023

u changed in the store class here:

The WP CLI classes are only loaded when the process is WP CLI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs feedback The issue/PR needs a response from any of the parties involved in the issue. type: task The issue is an internally driven task (e.g. from another A8c team). type: technical debt This issue/PR represents/solves the technical debt of the project.
Projects
None yet
Development

No branches or pull requests

7 participants