WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 5 years ago

#28920 closed defect (bug) (wontfix)

Two PHP warnings

Reported by: Looimaster Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.0
Component: Upgrade/Install Keywords:
Focuses: administration Cc:

Description

I don't know what are those but I run WAMP localhost with default configuration and it appears once a day:

Warning: An unexpected error occurred. Something may be wrong with WordPress.org or this server&#8217;s configuration. If you continue to have problems, please try the <a href="https://wordpress.org/support/">support forums</a>. (WordPress could not establish a secure connection to WordPress.org. Please contact your server administrator.) in C:\wamp\www\wp\wp-includes\update.php on line 294

Warning: An unexpected error occurred. Something may be wrong with WordPress.org or this server&#8217;s configuration. If you continue to have problems, please try the <a href="https://wordpress.org/support/">support forums</a>. (WordPress could not establish a secure connection to WordPress.org. Please contact your server administrator.) in C:\wamp\www\wp\wp-includes\update.php on line 449

I can use Dashboard > Updates to update WordPress or Plugins > Add New to install new plugins from wordpress.org. Also, automatic updates work on my localhost (from 3.9 to 3.9.1 for example).

Version: 4.0-beta1-20140714

I'm reporting it because maybe someone knows what happens and maybe that's a bug.

Change History (7)

#1 @michalzuber
6 years ago

This might be the cron job that checks plugins and themes for update on wordpress.org and during that it has no access to the internet. Try clicking on Update now under wp-admin/update-core.php if it works?
I reproduced it with firewall blocking the api.wordpress.org http://i.imgur.com/X1Ce17O.png

#2 @michalzuber
6 years ago

  • Component changed from General to Upgrade/Install
  • Focuses administration added

#3 @dd32
6 years ago

This generally occurs due to timeouts connecting to WordPress.org, or, in some rare cases a bad PHP installation that can't make HTTPS calls.

Short of increasing the timeouts (Which are currently set to 3 seconds IIRC) there's not much that can be done here. 3s is generally plenty of time for a server on a faster connection, but often too short for a local install.
As the HTTP request is blocking, the page will be delayed for $timeout_seconds while loading, which is why it's set to the bare minimum.

You could try running this code in a mu-plugin plugin to increase the timeouts:

add_filter( 'http_request_args', function( $r ) {
   $r['timeout'] = max( $r['timeout'], 10 ); // Set a minimum of 10s for all outgoing connections.
   return $r;
} );

#4 @Looimaster
6 years ago

Thank you for the information and the code but I'm not going to use it. It's fine with me that this error appears because it doesn't break anything and it appears only once a day.

  • I can use wp-admin/update-core.php and it works.
  • Plugins and themes installation from the Internet works.
  • Automatic WordPress installations works (almost every day nightly builds are applied automatically).

My Internet connection is fast (30mb/s or more). I open my computer at 8AM in the morning and I see the same warnings everyday. Then for the rest of the day they are not there. They only appear once a day.

I'm reporting this only because I thought that maybe someone will be interested in this and maybe someone will consider this as a bug that needs a fix.

Last edited 6 years ago by Looimaster (previous) (diff)

#6 @helen
6 years ago

  • Keywords reporter-feedback added

So - you open your computer, and this loads immediately? What happens if you load it a few minutes after starting your computer? I have a suspicion that it's loading the site because it's local, but hasn't yet connected to the network. Would also be good to know if this just started happening during 4.0 development or if you just happened to notice it now.

#7 @afercia
5 years ago

  • Keywords reporter-feedback removed
  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

No feedback in 15 months. Also, this is usually related to network issues, closing out. Please do feel free to re-open if it happens consistently in a non-local installation.

Note: See TracTickets for help on using tickets.