Jump to content

Module: ProcessWire Core Upgrade


ryan

Recommended Posts

I've found the problem. There is a method getCoreBranches which returns the branches already loaded in session if the second parameter is false. But it is never called with the second parameter set to true:

https://github.com/ryancramerdesign/ProcessWireUpgrade/blob/5333322703f0f47a6d6454e8fdb3107db330eec4/ProcessWireUpgradeCheck.module#L171

So I changed temporarily the call and it works now. But I gues it should be enough to relogin.

  • Like 3
Link to comment
Share on other sites

1 minute ago, Richard Jedlička said:

I've found the problem. There is a method getCoreBranches which returns the branches already loaded in session if the second parameter is false. But it is never called with the second parameter to true: https://github.com/ryancramerdesign/ProcessWireUpgrade/blob/master/ProcessWireUpgradeCheck.module#L171

So I changed temporarily the call and it works now. But I gues it should be enough to relogin.

 

Nice sleuthing - sorry, I should have thought to mention that since I posted this issues ages ago: https://github.com/ryancramerdesign/ProcessWireUpgrade/issues/10

  • Like 1
Link to comment
Share on other sites

  • 3 months later...
On 12/10/2016 at 8:50 PM, adrian said:

Have you done a Modules > Refresh? Maybe it is caching the source?

Thanks @adrian that worked for me - was getting 'Error loading GitHub branches' etc, but only for core. That fixed it.

<edit>..or at least it did temporarily. It let me upgrade the core (3.0.42 => 3.0.55) and install the new Uikit admin, and now it's back to saying there's a 403 error loading the core repository. Hmmm.</edit>

Edited by DaveP
Update (and it's not good...)
  • Like 1
Link to comment
Share on other sites

  • 1 month later...
  • 2 months later...

Hi Ryan

Great module as it lets less able users do updates (even though they aren't required - people feel more comfortable keeping their site up to date). These days I think it is a required part of any program (even if it is more only for comfort not security!!!)

I tend to ship out Processwire to my clients to change content and leave it up to them. This means that a couple of them have found the Update module and I end up getting calls about what all the versions are and which one is the right one (they're all used WordPress and updates messing things up so they don't want to do anything wrong   ;)

I had a look around the module to added a check mark in the config section that would only list the One Master version so that it was clearer as to which version (only the one) needed updating (or not) but I couldn't make heads nor tails of the rest of it [no time for a deep analysis]. I've included the updated ProcessWireUpgradeCheck.config.php which just adds a 'dontuseDeveloper' variable/array.

If you think it would benefit people to include it otherwise maybe just a quick point in the direction of how to list only the one Master update that would be great.

 

Thanks for the great modules you do... and of course for Processwire itself - which is a very welcome relief from WP and the other bloated CMSes.

ProcessWireUpgradeCheck.config.php

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

I'm still experiencing "Error loading GitHub branches" on different sites with different PW versions. 3.0.36 and 3.0.42 for instance still give the error. A final solution for this would be a great help as now it seems more like a procession of trial and error via FTP.

Link to comment
Share on other sites

Okay,  I've had in the past some installations that were manually done or a combination of manual/different updating methods.  Sometimes this gets things out-of-whack where upgrading is concerned.

I suggest you:

pw-update1.png.4a14544fa614241821a89534d1bd7983.png

(1) FTP to your actual files and manually delete the ProcessWire Upgrade module.  This will alleviate any left-over files that may have accumulated.

pw-update2.thumb.png.127dc9e4d059ae38673b0279229abab0.png 

(2) Click the Refresh button after manually deleting the ProcessWire Upgrade module.  This will refresh the cache and alleviate any other problems.

pw-update3.thumb.png.26437d987cbccfe0e81a8680f90f3eb4.png

(3) Reinstall the ProcessWire Upgrade module using this method.  This goes directly to the modules.processwire.com website and pulls an official version of this module.

pw-update4.thumb.png.bdb14890432a1d450e7b0f3cef4e2ef9.pngpw-update5.thumb.png.0fc3489fa0b19780c7cffc3daeb44b4d.png

(4) Once you have the ProcessWire Upgrade module reinstalled, check to make sure you are at the latest version (0.0.7 as of this writing). 

One thing to remember, the ProcessWire Upgrade module requires ProcessWire 2.5.20 or newer to reliably function.

(5) Please let us know what version of PHP and ProcessWire you are having this problem with?  Are you having this problem with all your ProcessWire sites?  If not, what are the differences that you know about?  All this will help us to troubleshoot the issues you are having.   This does not mean there aren't problems with the module, however we need to eliminate as many factors as possible to get your installations working.

 

 

  • Like 1
Link to comment
Share on other sites

1 hour ago, BFD Calendar said:

I'm still experiencing "Error loading GitHub branches" on different sites with different PW versions. 3.0.36 and 3.0.42 for instance still give the error. A final solution for this would be a great help as now it seems more like a procession of trial and error via FTP.

This is the only posting that I have seen that refers to that error:

 

  • Like 1
Link to comment
Share on other sites

Ok, I tried all this, to no avail. I'm using PW 3.0.42 on one site and 3.0.62 on another one, same problem.

I noticed a .ProcessWireUpgrade folder in the modules folder so I also removed that.

Three sites are hosted with OVH.net, one with a different provider doesn't have the problem. So that's where to look, but still I wouldn't know where exactly. PHP version is 5.6 if I'm right.

Link to comment
Share on other sites

If you have the ability, on a new installation of ProcessWIre with only the ProcessWire Upgrade module installed, what happens? 

Are all the errors associated with one hosting provider?  If so, have you inquired whether they have some security script running that could erroneously flag these websites when the ProcessWire Upgrade module is running?

Just looking at all possible explanations.  I know it can be very frustrating whenever someone has these types of issues.  We will eventually figure out what's happening and correct the issue.

 

  • Like 2
Link to comment
Share on other sites

Same provider - two sites - PHP 7.0 - PW 2.6.23 rc2 upgrades works - PW 3.0.42 upgrades gives error.

But... there was some old .gitignore file that PW installed in the old days. Removed that and yes! Upgrades are back. I'll keep my fingers crossed and see if they stay...

  • Like 3
Link to comment
Share on other sites

14 hours ago, BFD Calendar said:

But... there was some old .gitignore file that PW installed in the old days. Removed that and yes! Upgrades are back. I'll keep my fingers crossed and see if they stay...

Unfortunately my luck only lasted 14 hours... Upon logging in today the error is back.

Link to comment
Share on other sites

I have had random failures on an old shared host that I no longer use. I never got around to debugging, but I wondering if it's a curl issue. I'd be curious if you have better luck disabling curl here: https://github.com/processwire/processwire/blob/57b297fd1d828961b20ef29782012f75957d6886/wire/core/WireHttp.php#L639

Just remove 'curl' from the $allowMethods array. It should resort to fopen and socket consecutively if curl fails completely, but maybe there is some curl setting on that host that is randomly problematic with Github. Not sure, but maybe worth a try.

  • Like 2
Link to comment
Share on other sites

  • 3 months later...

I'm having problems upgrading pw using the upgrade tool.

The file "dev.zip" is being downloaded to /users/pwdev/www//site/assets/cache/ProcessWireUpgrade/. It seems a valid zip, I can open it using FTP.

After pressing "> Skip Database Backup" I'm getting the message: "Unable to locate ZIP: /users/pwdev/www/site/assets/cache/ProcessWireUpgrade/dev.zip"

After that, the file and folder is indeed deleted.

It's free hoster: http://phpinfo.square7.ch/

Any ideas? I think this worked before.

Thank you.

pwup1.png

pwup2.png

Link to comment
Share on other sites

I did the update manually now.

Interestingly, all the files were there, like "wire-3.0.87"-folder and then new htaccess and index.php.

I just had to rename them and refresh module cache and the update was done.

Not sure what the problem is. To me it does not look like a problem with the Webhosting.

Thank you.

Happy new year to everyone!

 

  • Like 1
Link to comment
Share on other sites

  • 2 months later...

Hi Theo,

We have been experiencing what appears to be exactly the same problem too.

It works every time if you do not skip the backup. Of course this does mean you have to then manually remove the renamed folders and the backup.

Just requesting our hosting provider disables "mod_security" as this can cause problems with "Processwire".

Regards,

Hackasacka

Link to comment
Share on other sites

Hi Theo,

Just to confirm that "mod_security" was indeed the problem on our particular hosting environment with the "ProcessWireUpgrade " module downloading the requisite .zip file for upgrade to the cache, but not being unable to access it to install.

With "mod_security" disabled it was possible to install without creating a backup first.

Hope this helps.

Regards,

Hackasacka

  • Like 3
Link to comment
Share on other sites

  • 3 weeks later...

Hello all. I just tried to upgrade an existing profile from 3.0.95 to 3.0.96 and noticed similar behavior as it was mentioned by @theo and @Hackasacka . The upgrade was working perfectly fine on my local server and hosting, however now trying to upgrade automatically the core led me to a folder 'wire' and 'wire-3.0.96' (where 3.0.95 should be the old backup). 

Strange enough, this only happens with the core of PW but all other modules work just fine. I will proceed to upgrade this one manually and try to do another automated upgrade on next release to see how it would behave.

P.S. Manual upgrade works perfectly fine and all I had to do was to extract from the latest version archive the wire, install.php and .htaccess and after a backup of the existing ones to place them in the root domain folder. Tested the frontend and backend - all seems to be fine and the module reports no newer upgrades.

Edited by MilenKo
Report upon a manual upgrade
  • Like 1
Link to comment
Share on other sites

  • 4 months later...

Hi @BFD Calendar

I know it’s been a long time since you have reported your issue-almost one year. But I experienced the same issue on the same provider (OVH) and I found a solution. Maybe it can help: in my client interface my global PHP configuration was still set to "Legacy", I changed it to « stable » and I am now able to use the Processwire upgrade module.

It can also be done in the .ovhconfig file by changing "container.image=legacy" to "container.image=stable".

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...