-
Notifications
You must be signed in to change notification settings - Fork 9.4k
[Performance] Fix array merge in loop #30153
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
[Performance] Fix array merge in loop #30153
Conversation
Hi @ihor-sviziev. Thank you for your contribution
❗ Automated tests can be triggered manually with an appropriate comment:
You can find more information about the builds here ℹ️ Please run only needed test builds instead of all when developing. Please run all test builds before sending your PR for review. For more details, please, review the Magento Contributor Guide documentation. 🕙 You can find the schedule on the Magento Community Calendar page. 📞 The triage of Pull Requests happens in the queue order. If you want to speed up the delivery of your contribution, please join the Community Contributions Triage session to discuss the appropriate ticket. 🎥 You can find the recording of the previous Community Contributions Triage on the Magento Youtube Channel ✏️ Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel |
@magento run Integration Tests |
3 similar comments
@magento run Integration Tests |
@magento run Integration Tests |
@magento run Integration Tests |
Would like to identify what actually breaks the integration tests, for now tried to revert some parts, will see where it start fails |
ecf6229
to
2381ab4
Compare
@magento run Integration Tests |
@magento run Static Tests |
@magento run all tests |
$blacklist = []; | ||
foreach (glob($pattern) as $list) { | ||
//phpcs:ignore Magento2.Performance.ForeachArrayMerge | ||
$blacklist = array_merge($blacklist, file($list, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES)); | ||
$blacklist[] = file($list, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); | ||
} | ||
return $blacklist; | ||
return array_merge([], ...$blacklist); |
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.
Could you replace *****list
with less controversial word? Eg. IgnoredList
?
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.
That’s not purpose of current PR. We have a lot such places in code, they need to be reviewed all and fixed at once
Hi @lbajsarowicz, thank you for the review.
|
@magento create issue |
QA not applicable |
@magento give me new instance with env php 7.3 database 5.7 |
Hi @gabrieldagama. Thank you for your request. I'm working on Magento instance for you. |
Hi @gabrieldagama, here is your Magento Instance: https://c178e3cc1a06edcebf1a10b470ad896d.instances.magento-community.engineering |
@magento give me new instance with edition b2b with env php 7.3 database 5.7 |
Hi @gabrieldagama. Thank you for your request. I'm working on Magento instance for you. |
Hi @gabrieldagama, here is your Magento Instance: https://c178e3cc1a06edcebf1a10b470ad896d.instances.magento-community.engineering |
Hi @ihor-sviziev, thank you for your contribution! |
Description (*)
Continuing #30002 - fix array merge in loop in different places.
Also this is follow up on my old PR #22248, so it should a bit improve static content deploy.
Related Pull Requests
Fixed Issues (if relevant)
Manual testing scenarios (*)
Questions or comments
Contribution checklist (*)
Resolved issues: