Upgrade always available, even after upgrade

Upgrade always available, even after upgrade

by Joshua Johnston -
Number of replies: 13

Hi,

I am running the latest version of moodle, Moodle 2.4.2+ (Build: 20130315) and every time I go to the admin/index.php I get a notification that there is a new version available. The new version shows up as 2.4.3+ 20130318 and says I am running 2012120303.

I have downloaded the new version, unzipped it over my previous version and ran the upgrade process. Once complete, I get the same message. There are no errors during the upgrade process. What is going on here?

See the attached screenshot for the three different version numbers going on.

Attachment moodle-upgrade-woes.png
Average of ratings: -
In reply to Joshua Johnston

Re: Upgrade always available, even after upgrade

by Bret Miller -
Picture of Particularly helpful Moodlers

2.4.2+ is not the latest version of Moodle as of Monday. 2.4.3 is the latest version, and it was released Monday 18 Mar, so your Friday 15 Mar date is 3 days before the latest version was released.

In reply to Bret Miller

Re: Upgrade always available, even after upgrade

by Joshua Johnston -

Hi Bret,

Thanks for the reply. I did upgrade but it did not bump the version number so it keeps thinking I am behind.

I just attempted to upgrade again. I clicked the download link (http://download.moodle.org/download.php/direct/stable24/moodle-latest-24.zip) and unzipped the archive over top of my existing moodle directory. When prompted, I said yes [A] to overwrite all files and when complete I followed the steps in the moodle admin page to perform the upgrade. When completed, I see the same screen telling me I am out of date. This also happened with the 20130315 update.

Any other ideas?

In reply to Joshua Johnston

SOLVED

by Joshua Johnston -

The moodle-latest zip file has the wrong version.php in it. Someone needs to update the package since the download link in moodle points directly to it

In reply to Joshua Johnston

Re: SOLVED

by Damyon Wiese -

Hi Joshua,

Can you check this again by downloading the zip and extracting it to a new directory, opening up the version.php file and seeing what is in there? It sounds like a problem with the way you are opening the zip - I checked the versions and they are all correct. 

More info on the version.php file is here: http://docs.moodle.org/24/en/Moodle_version

More info on why the build date is different to the timestamp in the version number:

http://docs.moodle.org/dev/Moodle_versions

Hope this helps, Damyon

Average of ratings: Useful (1)
In reply to Damyon Wiese

Re: SOLVED

by Joshua Johnston -

Hi Damyon,

The download link that you are taken to from my screen shot in the first post is http://download.moodle.org/download.php/direct/stable24/moodle-latest-24.zip

If you extract this to an empty directory, the version file contains the following:

/**
* MOODLE VERSION INFORMATION
*
* This file defines the current version of the core Moodle code being used.
* This is compared against the values stored in the database to determine
* whether upgrades should be performed (see lib/db/*.php)
*
* @package core
* @copyright 1999 onwards Martin Dougiamas (http://dougiamas.com)
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/

defined('MOODLE_INTERNAL') || die();


$version = 2012120302.03; // 20121203 = branching date YYYYMMDD - do not modify!
// RR = release increments - 00 in DEV branches
// .XX = incremental changes

$release = '2.4.2+ (Build: 20130315)'; // Human-friendly version name

$branch = '24'; // this version's branch
$maturity = MATURITY_STABLE; // this version's maturity level

 

When I do directly to the downloads section of moodle.org I do not have this problem.

In reply to Damyon Wiese

Re: SOLVED

by Kraig Robson -

Hi Damyon,

 I had the exact same issue, although I used the proper procedure of moving my entire moodle folder to a backup location, unzipping the fresh moodle installation, copying over my mods/blocks/themes, and then attempting the re-install.  I did this THREE times using a freshly downloaded zip each time (twice taken from the download link in my moodle install, once directly from the moodle downloads page),  and each time the version did not upgrade.  Furthermore, I just checked the files in the raw zip, and the version.php file says 

$release  = '2.4.2+ (Build: 20130315)'; // Human-friendly version name

So I downloaded the .tgz file - worked like a charm.  Are you sure the zipped version is correct?  Or is it possible the server has the prior zipped version cached?

Thanks!  Kraig

 

In reply to Joshua Johnston

Re: Upgrade always available, even after upgrade

by Bret Miller -
Picture of Particularly helpful Moodlers

In my own personal experience, I find that when upgrading within a week of a new version's release, the -latest files are not the current version. So if they release 2.4.3 on Monday, the earliest that the moodle-latest-24.zip file will reflect that is on the following Monday. I have not checked to see if the other files in the -latest reflect the current version or not. Considering the version number is wrong, I always assumed that the files were also from the previous release. In other words, if you're quick to jump on a new release in that first week, use the "latest official update" (2.4.3) not the  "built every week with new fixes" (2.4.3+).

In reply to Joshua Johnston

Re: Upgrade always available, even after upgrade

by Aditya Kakodkar -

I wonder as to why people do not read upgrade documentation. Please check the link below:

http://docs.moodle.org/23/en/Upgrading#Install_the_new_Moodle_software

Pay attention to No:1

"Move your old Moodle software program files to another location. Do NOT copy new files over the old files."

It is natural to encounter problems if one does not follow recommended upgrade instructions.

Hope this helps,

Adi.

PS: I have upgraded to 2.4.3 yesterday, without any problems with version numbers.

 

 

 

In reply to Aditya Kakodkar

Re: Upgrade always available, even after upgrade

by Joshua Johnston -

Aditya,

Before you go spouting off about RTFM, please re-read my post. If you download the "latest" version of moodle from the link I posted above and extract it to an empty folder you will see that the version.php file is incorrect.

In reply to Joshua Johnston

Re: Upgrade always available, even after upgrade

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Neverthless, if what you say ("unzipped it over my previous version") is true, then Aditya is quite correct if, perhaps, a little insensitive.

You simply musn't do that. Due to the way that Moodle locates plugins and such this method of upgrading is not recommended and (in particular) not supported.

As an alternative you could always get your code from Git - Git_for_Administrators

In reply to Howard Miller

Re: Upgrade always available, even after upgrade

by Joshua Johnston -

I agree, you shouldn't unzip over previous files normally but in my case I did it from the command line and forced it to overwrite so it wasn't the issue.

The real issue here is the In-Moodle Download Link to the latest release points to a version that had an older version.php file bundled with it.

Bad packaging on someone's part.

In reply to Joshua Johnston

Re: Upgrade always available, even after upgrade

by Eloy Lafuente (stronk7) -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Hi,

just to bring some light to the "strange case of the mismatching versions", here it is MDLSITE-2172, hope it explains the problem clearly.

Hopefully, it will be fixed soon and next releases (May 13th) will point correctly to the just released packages and not to the previous weeklies (slightly older).

Note that the problem only happens for 3-4 days, until the next weeklies land. That day the "latest-xy" files will be, again, truly the latest ones. 

Thanks everybody for this discussion, it helped both to detect the problem and to find a solution before next releases. 

Ciao smile

Average of ratings: Useful (2)