YahnisElsts / wp-update-server

A custom update API for WordPress plugins and themes. Intended to be used in conjunction with my plugin-update-checker library.
MIT License
824 stars 176 forks source link

Not showing update. #52

Closed JoeSz closed 7 years ago

JoeSz commented 7 years ago

Hi,

I have testing wp-update-server and Puc_v4_Factory update checker on two sites. The two site set up is the same. On one site it is working well, but on the other site, I have the following error: (I also has a theme with wp-update-server and theme-update-checker, same thing. One working the other is not.)

Warning: The URL [server]/wp-update-server/?action=get_metadata&slug=[plugin]&installed_version=1.0.3 does not point to a valid metadata file. WP HTTP Error: cURL error 28: Connection timed out after 10001 milliseconds in [server-path]/wp-content/plugins/[plugin]/vendor/plugin-update-checker/Puc/v4/UpdateChecker.php on line 297 Failed to retrieve plugin info from the metadata URL.

I did checked the url, it is working and it does not take more then 10 sec.

I also did the following: "Here are a few things to check:

Verify that the correct theme slug is passed to the ThemeUpdateChecker constructor. Usually it should match the theme directory name.

Verify that you have the latest version of the update checker (1.2). -> I instelled 2017, so I think it is the newest, but where can i check it?

Try running $updateChecker->requestUpdate() and var_dump() the result. Does it return a ThemeUpate instance and does it have the expected version number? -> the error above.

Take a look at the external_theme_updates-$themeSlug option in the wp_options table. It should contain a serialized PHP object. Is it present and does it have the right version number? -> valid and correct"

WordPress 4.7.4 PHP 7.0.18 and 5.6.30 cURL 7.29.0

Any idea?

YahnisElsts commented 7 years ago

That sounds like it could be a network problem. Can you ping the update server from the server where the plugin/theme is installed? Can you successfully wget or curl the metadata URL?

JoeSz commented 7 years ago

Sorry for the late answer, it was a busy day.

You are right, from an other site, I can not get url content with curl. So I have the update server in server A, the theme and plugin working well on server A, but server B can not get the JSON from server A, but any other server, it work. Really strange.

I tried only the curl so, I will do further testing. But I think this issue is closed (I do not know, how to close it) because this problem is related to "Alfahosting" web-hosting. I will open a new one, if I have any :)

Thank you very much to point me to the right direction and answer so quick!

Have a nice day!

Joe

YahnisElsts commented 7 years ago

All right, I'll close this issue.