Jump to content
psy

Upgrade synchronicity

Recommended Posts

Noticed a couple of posts in the forums today regarding upgrading from 2.x to 3.x just when I won a new client who has a PW 2.3.0 site that needs upgrading. Yes, you read that right 2.3.0, 5+yo and still going strong without a single security update.

Confident it can be done and welcome any tips/tricks/hints/tutorials to avoid pitfalls

 

Share this post


Link to post
Share on other sites

I maintain a 2.5 instance of ProcessWire which needs to be upgraded in the future, too. Not only ProcessWire itself but design and functionality as well.

1.) My first test-run showed me that several things changed. The biggest issue so far was a field called limit. It worked in that site but with 3.x it doesn't. Some names are not allowed anymore - or are already pre-defined somewhere but there are easy ways to avoid that. Just rename those fields before upgrading. Which brings us to the next point.

2.) Always use a test instance and have a working backup. 😉 

3.) Modules are a big roadblock. Some don't work anymore with 3.x, some just say they don't support 3.x and others just need to be updated. By now I downloaded the most recent version of all modules manually. Switched old modules for newer ones and changed the ProcessWire core at the same time. It worked pretty well - after hitting refresh a few times. 😎

4.) Compiled files cache, markup cache, sessions... just drop them. At least that's what worked for me.

5.) Crawl the whole site after first upgrades to find 3xx, 4xx, 5xx issues - I use ScreamingFrog and the Jumplinks module.

6.) Namespace... I had to add it to some files.

7.) I created a site profile from my upgraded copy and tried to install it. Just to check if everythings works even after exporting it and such things. It worked. Luckily. So I had a first, clean. updated and working version of that project for the upcoming changes.

 

 

  • Like 3
  • Thanks 1

Share this post


Link to post
Share on other sites
6 minutes ago, wbmnfktr said:

I maintain a 2.5 instance of ProcessWire which needs to be upgraded in the future, too. Not only ProcessWire itself but design and functionality as well.

This 2.3.0 site once upgraded will need a redo of design & functionality too. That's Stage 2. Need to get Stage 1 done first

Share this post


Link to post
Share on other sites

Starting fresh and importing the old data might also be an option. When I think of sites that I built 5 years ago I'd definitely build them completely new 😄 If you have to redo the design anyhow that should not be too much work and you can refactor things easily and improve quality and maintainability.

  • Like 2

Share this post


Link to post
Share on other sites

@bernhard would definitely do that if I had the option. The AWOL developer did a fabulous job and the code is beautifully written. I need to do the upgrade first to prove myself to the client.

The rebuilt site will use the old data and redesigned to take advantage of the power of today's PW - hopefully mainly template work with a few new modules.

Client has used WP in the past and couldn't believe the PW2.3.0 site still worked and hadn't needed one security update in all that time

  • Like 2

Share this post


Link to post
Share on other sites
5 hours ago, bernhard said:

Starting fresh and importing the old data might also be an option.

I loved doing that. Especially with my own projects. No matter how long they have been online. 2 years or 2 weeks. The slightest change and I started a rebuild. I try to stop this behaviour as it costs too much time. In case of a client project there is most of the time neither the money, nor the time for going this way.

But... yeah, starting with a fresh copy is always great.

  • Like 3

Share this post


Link to post
Share on other sites

@wbmnfktr thanks for the tips 👍

Version so old, cache had only one folder LOL

Tested in a staging environment.

Upgrade of PW core - almost 150 versions from 2.3.0 to 3.0.141 - worked first time. Gotta love it!

Couple of modules needed upgrading and most went smoothly.

Solved issues with ProcessCustomAdminPages. Couldn't upgrade so recreated the admin pages and assigned the necessary templates

Now resolving a few hiccoughs with custom template code and confident I'll get through

 

  • Like 5

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...