• I’ve checked the PHP error log on my server and found these errors related to WP statistics, probably checking for IP exclusions:

    PHP Fatal error:  Uncaught ValueError: str_repeat(): Argument #2 ($times) must be greater than or equal to 0 in /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-ip.php:266
    Stack trace:
    #0 /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-ip.php(266): str_repeat('0', -32)
    #1 /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-exclusion.php(366): WP_STATISTICS\IP::checkIPRange(Array)
    #2 [internal function]: WP_STATISTICS\Exclusion::exclusion_iP_match(Object(WP_Statistics\Service\Analytics\VisitorProfile))
    #3 /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-exclusion.php(70): call_user_func(Array, Object(WP_Statistics\Service\Analytics\VisitorProfile))
    #4 /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-hits.php(147): WP_STATISTICS\Exclusion::check(Object(WP_Statistics\Service\Analytics\VisitorProfile))
    #5 /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-hits.php(268): WP_STATISTICS\Hits::record()
    #6 /www/doc/<site>/www/wp-includes/class-wp-hook.php(324): WP_STATISTICS\Hits::trackServerSideCallback(Object(WP))
    #7 /www/doc/<site>/www/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)
    #8 /www/doc/<site>/www/wp-includes/plugin.php(565): WP_Hook->do_action(Array)
    #9 /www/doc/<site>/www/wp-includes/class-wp.php(830): do_action_ref_array('wp', Array)
    #10 /www/doc/<site>/www/wp-includes/functions.php(1336): WP->main('')
    #11 /www/doc/<site>/www/wp-blog-header.php(16): wp()
    #12 /www/doc/<site>/www/index.php(17): require('/www/doc/<site>...')
    #13 {main}
    thrown in /www/doc/<site>/www/wp-content/plugins/wp-statistics/includes/class-wp-statistics-ip.php on line 266

    WP Statistics version is the currently latest one, so v14.11.2
    WordPress version also latest v6.6.2, running on PHP 8.1.30
    My Exclusion IP list has about 15 entries, mix of IPv4 and IPv6 addresses on separate lines.

    There are dozens of these errors in log. Any suggestions how to avoid these?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Matthew

    (@mhdizmni)

    Hi @kraken2k,

    Thank you for opening the thread!

    Could you please share your exclusion settings with us, specifically the IP exclusions?

    Please also refer to our guide at https://wp-statistics.com/resources/exclude-ip-addresses/ to ensure your IP exclusions are following the correct format.

    Thank you!

    Regards

    Thread Starter kraken2k

    (@kraken2k)

    Hello, my IP exclusion list is here – made previously using the guide you referred:

    31.15.10.50
    2a02:4a8:ac24:110::10:50
    31.15.10.143
    2a02:4a8:ac24:110::10:143
    31.15.10.124
    2a02:4a8:ac24:110::10:124
    95.85.254.156
    2a01:510:d502:5700:4a8f:5aff:fefb:28fc/64
    185.140.245.146
    84.42.176.134
    82.142.107.152
    89.103.214.237
    127.0.0.1/24
    fc00::/7

    I keep it here for a short time – please copy it – because I don’t want this to be a public info.

    Plugin Support Matthew

    (@mhdizmni)

    Hi @kraken2k,

    Thank you for providing the IPs!

    After reviewing them, we have identified that 2a01:510:d502:5700:4a8f:5aff:fefb:28fc/64 is causing the error. Kindly remove it for the time being.

    We are actively investigating the issue and will resolve it in an upcoming release. We’ll be sure to update you on our progress here.

    Thank you for your understanding and patience!

    Regards

    Plugin Support Matthew

    (@mhdizmni)

    Dear @kraken2k,

    I’m pleased to inform you that we have addressed the issue in our recent update, version 14.11.3.

    Could you please update WP Statistics and let us know if the issue has been resolved?

    We look forward to your response!

    Regards,
    Matthew

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.