contao / core-bundle

[READ-ONLY] Contao Core Bundle
GNU Lesser General Public License v3.0
123 stars 58 forks source link

Contao version/ build not updating in backend #1678

Closed verkruemelt closed 5 years ago

verkruemelt commented 5 years ago

I had run an update via composer: image core bundle was updated to 4.4.31, I assumed I can see this version number in the backend too. But unfortunatley the version in the backend still shows 4.4.20: image as of installation. The same in a test and production enviornment.

Is this a bug or an undocumented feature? :smile:

fiedsch commented 5 years ago

I can't confirm this, have never experienced this.

In addition: the composer log states, that the update was from 4.4.30 to 4.4.31! So just to be sure: did you check the correct backend?

verkruemelt commented 5 years ago

Das ist richtig. Ich habe heute das Update durchgeführt von 4.4.30 zu 4.4.31. Auf beiden Systemen. Aber im Backend wird mir einmal die Version 4.4.20 angezeigt und im zweiten System die 4.4.28.

Dies müsste jeweils die Version sein, mit der das jeweilige Contao installiert wurde - wenn ich mich richtig erinnere. Ich habe auch jeweils eine Systemwartung laufen lassen und die jeweilige Webseite per [Strg] + [F5] komplett neu laden lassen. Aber die alte Versionsnummer wird noch immer angezeigt.

Toflar commented 5 years ago

Maybe a modified be_main template?

ausi commented 5 years ago

Your screenshot of the composer output looks like there is something missing. Did you see the following lines in the output?

ocramius/package-versions:  Generating version class...
ocramius/package-versions: ...done generating version class

Please check if the file vendor/ocramius/package-versions/src/PackageVersions/Versions.php contains the correct version for contao/core-bundle.

leofeyer commented 5 years ago

Did you clear the cache?

verkruemelt commented 5 years ago

Where can I find this template

Maybe a modified be_main template?

Nope

Your screenshot of the composer output looks like there is something missing. Did you see the following lines in the output?

ocramius/package-versions:  Generating version class...
ocramius/package-versions: ...done generating version class

Please check if the file vendor/ocramius/package-versions/src/PackageVersions/Versions.php contains the correct version for contao/core-bundle.

These lines are not in the output. I can't find the folder <root>/vendor/ocramius, but <root>/vendor/contao/core-bundle/src/Resources/contao/classes/Versions.php. But there is no version neither.

Did you clear the cache?

Yep!

fritzmg commented 5 years ago

Post your current composer.json.

verkruemelt commented 5 years ago
{
    "name": "contao/managed-edition",
    "type": "project",
    "description": "Contao Open Source CMS",
    "license": "LGPL-3.0-or-later",
    "authors": [
        {
            "name": "Leo Feyer",
            "homepage": "https://github.com/leofeyer"
        }
    ],
    "require": {
        "php": "^5.6|^7.0",
        "contao/calendar-bundle": "^4.4",
        "contao/comments-bundle": "^4.4",
        "contao/faq-bundle": "^4.4",
        "contao/listing-bundle": "^4.4",
        "contao/manager-bundle": "4.4.*",
        "contao/news-bundle": "^4.4",
        "contao/newsletter-bundle": "^4.4",
        "terminal42/contao-changelanguage": "^3.1",
    "sensio/framework-extra-bundle": "^3.0.29"
    },
    "conflict": {
    },
    "config": {
        "component-dir": "assets"
    },
    "extra": {
        "branch-alias": {
            "dev-4.4": "4.4.x-dev"
        }
    },
    "scripts": {
        "post-install-cmd": [
            "Contao\\ManagerBundle\\Composer\\ScriptHandler::initializeApplication"
        ],
        "post-update-cmd": [
            "Contao\\ManagerBundle\\Composer\\ScriptHandler::initializeApplication"
        ]
    }
}

Files are identical on prod and test.

xchs commented 5 years ago

Rename composer.lock to composer.lock.bak and run a complete Composer update.

fritzmg commented 5 years ago

Also confirm which composer version you are currently using.

verkruemelt commented 5 years ago
composer --version
Using config.component-dir has been deprecated. Please use extra.contao-component-dir instead.
Composer 1.6.3 2018-01-31 16:28:17

newest version is 1.8.0... will update after complete composer Update: HTTP 500 Apache Error log:

PHP Fatal error:  Uncaught RuntimeException: Unable to create the store directory (/var/www/html/cms/var/cache/prod/http_cache).
xchs commented 5 years ago

Is the directory writable or have you reached the disk quota?

BTW: We should discuss this in the forums!

verkruemelt commented 5 years ago

Owner or files/ folders set to www-data after composer update (per script), Disk quta not reached.

ausi commented 5 years ago

Did you clear the cache?

Yep!

Can you please try if manually deleting the folders var/cache/prod and var/cache/dev resolves the problem?

aschempp commented 5 years ago

Be aware that the versions are not stored in the cache. They are stored in the vendor folder.

ocramius/package-versions:  Generating version class...
ocramius/package-versions: ...done generating version class

This is the only relevant suggestion. If this does not appear, there is an issue with your composer update. Or you did run it with --no-plugins flag or thelike. Somehow, the versions plugin is not updated. You will most likely find the wrong version in vendor/ocramius/package-versions/src/PackageVersions/Versions.php

ausi commented 5 years ago

Be aware that the versions are not stored in the cache. They are stored in the vendor folder.

In Contao 4.4 too?

leofeyer commented 5 years ago

I don't think so.

leofeyer commented 5 years ago

Can you please try if manually deleting the folders var/cache/prod and var/cache/dev resolves the problem?

@verkruemelt Did you try this and did it solve the issue?