Skip to content

Error while installing Magento from scratch if Locale Resolver is injected in cli command #21752

Closed
@Bartlomiejsz

Description

@Bartlomiejsz

Summary (*)

Tested on 2.3, but exactly same code exists in this file on 2.2-develop branch.
Method getDefaultLocale of Magento\Framework\Locale\Resolver checks configuration in core_config_data. The reason of it is that if this class or some other that have it injected in some parent (for example Magento\Sales\Model\Order\Address\Validator) is injected in constructor in Cli Command in some custom module, installation of Magento fails.

Examples (*)

  1. Add custom module with Cli Command in which Magento\Sales\Model\Order\Address\Validator is injected
  2. Try to install Magento from scratch using Cli.
  3. See following error: Base table or view not found: 1146 Table 'database.store_website' doesn't exist, query was: SELECT store_website.* FROM store_website"

Proposed solution

This is fixed under #21693

Metadata

Metadata

Assignees

Labels

Component: SalesFixed in 2.3.xThe issue has been fixed in 2.3 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseReproduced on 2.3.xThe issue has been reproduced on latest 2.3 release

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions