-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
Escape disabled modules in code compilation - setup:di:compile #39723
base: 2.4-develop
Are you sure you want to change the base?
Conversation
Hi @lucafuser. Thank you for your contribution!
Allowed build names are:
You can find more information about the builds here For more details, review the Code Contributions documentation. |
@magento run all tests |
setup/src/Magento/Setup/Test/Unit/Console/Command/DiCompileCommandTest.php
Outdated
Show resolved
Hide resolved
@magento run all tests |
if (!$moduleStatuses || !is_array($moduleStatuses)) { | ||
$output->writeln('<error>Deployment config not available.</error>'); | ||
return Cli::RETURN_FAILURE; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As you pointed in https://github.com/magento/magento2/pull/39723/files#r1990180085, this was already checked in
$errors = $this->checkEnvironment(); |
I guess we can simply remove these lines
if (!$moduleStatuses || !is_array($moduleStatuses)) { | |
$output->writeln('<error>Deployment config not available.</error>'); | |
return Cli::RETURN_FAILURE; | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
@magento run all tests |
Description (*)
As disabled module is being compiled, so in this PR I've escaped disabled modules before code compilation.
Related Pull Requests
Fixed Issues (if relevant)
Manual testing scenarios (*)
app/etc/config.php
set "0" to a module OR runphp bin/magento module:disable Vendor_Module
php bin/magento setup:di:compile
Questions or comments
Contribution checklist (*)