2

I have been having server 500 errors on 3 separate WordPress websites over the last while. (The problem BTW does seems to be related to the wordpress_logged_in***** cookie because deleting that always solves the problem temporarily) but this is not really my question ...

In the course of investigating this issue I turned on debugging and logging on two of he websites and I got this message in each site

[07-Jul-2017 12:21:51 UTC] WP_Community_Events::maybe_log_events_response: Valid response received. Details:

{"api_url":"https://api.wordpress.org/events/1.0/","request_args":{"body":{"number":5,"ip":"212.126.42.0","locale":"en_US","timezone":"Europe/Dublin"}},"response_code":200,"response_body":{"location":{"ip":"212.126.42.0"},"events":"1 events trimmed."}}

Does anybody know what it might be referring to. The IP address is local, and it's from MY IP provider, but it's not my IP, or the IP of my client, plus it's the same IP on both sites ( which have no connection except me )

I couldn't find much information but this page https://developer.wordpress.org/reference/classes/wp_community_events/maybe_log_events_response/ seems to suggest that it might not be an error. Could anyone confirm this?

1 Answer 1

5

The log message says "Valid response received" and the response code in the JSON object is 200, which is typically a response for a success request. I think it is not an error. Note that the docs for WP_Community_Events::maybe_log_events_response() says "All responses are logged when debugging, even if they’re not WP_Errors". I understand that if WP_DEBUG is on, then all responses are logged, even when success.

The IP, according with the code comments, usually is the same that made the request. In some cases it can be different (for example when the IP is private). The IP used in the request is the client IP converted to a network ID in order no anonymize the ID. See WP_Community_Events::get_unsafe_client_ip().

Update: after viewing the source code, all responses are logged when WP_DEBUG_LOG is on, not just WP_DEBUG.

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.