Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error Message Is Confusing When Code Base Is Behind Database Module Version #9008

Closed
mpchadwick opened this issue Mar 24, 2017 · 7 comments
Closed
Labels
Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Progress: needs update

Comments

@mpchadwick
Copy link
Contributor

Please upgrade your database: Run "bin/magento setup:upgrade" from the Magento root directory.
The following modules are outdated: Foo_Bar schema: current version - 1.0.4, required version - 1.0.0

Preconditions

This can happen when...

  • You download a database dump from a staging environment that has had code deployed to it which upgrades schema version (e.g. "develop" brand(
  • In your local environment, you are on the "master" branch, which is behind the database.

In this case running bin/magento setup:upgrade does not resolve the issue, and upgrading the database is not really correct (you actually need to downgrade).

@Ctucker9233
Copy link

@mpchadwick Agreed. +1

@korostii
Copy link
Contributor

While I generally agree the message given in this case is severely misleading, I'd like to make the following remark.

you actually need to downgrade

Wasn't sure whether to laugh or cry tears at this moment. DB downgrade is a potentially destructive oeration (imagine destroying a column having important information in it) and I don't see how is it a good idea to promote something like that in the messages (read: "instructions") given to the user.

IMHO what you most likely need in such a situation is upgrade the module itself (with composer or from repo branch or wherever it's source code is) to the version required by the DB, thus a relevant message should look similar to the following:
Please upgrade your modules: Run "composer install" from the Magento root directory. The following modules are outdated: Foo_Bar current version - 1.0.0, required version - 1.0.4

@veloraven
Copy link
Contributor

@mpchadwick thank you for your feedback.
Please, format this issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result.
Please, also identify which version of Magento you are running.

@veloraven
Copy link
Contributor

According to contributor guide, tickets without response for two weeks should be closed.
If this issue still reproducible please feel free to create the new one: format new issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result and specify Magento version.

@korostii
Copy link
Contributor

korostii commented Jul 3, 2017

BTW This is also a duplicate of #9981.

@magento-team
Copy link
Contributor

Internal ticket to track issue progress: MAGETWO-80225

@magento-team magento-team added 2.2.x Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development labels Sep 29, 2017
@magento-engcom-team magento-engcom-team added the Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed label Sep 29, 2017
@okorshenko
Copy link
Contributor

Hi @mpchadwick. Thank you for your report.
The issue has been fixed in magento-engcom/magento2ce#1353 by @magento-engcom-team in 2.3-develop branch
Related commit(s):

The fix will be available with the upcoming 2.3.0 release.

@okorshenko okorshenko added the Fixed in 2.3.x The issue has been fixed in 2.3 release line label Feb 7, 2018
@magento-engcom-team magento-engcom-team added the Fixed in 2.2.x The issue has been fixed in 2.2 release line label Feb 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line Issue: Format is not valid Gate 1 Failed. Automatic verification of issue format is failed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Progress: needs update
Projects
None yet
Development

No branches or pull requests

7 participants