-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Product layout based on attribute_set (PR #36244) #39718
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
base: 2.4-develop
Are you sure you want to change the base?
Conversation
|
Hi @in-session. 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 |
|
Static test will be fixed after test run: PHP Code Sniffer detected 1 violation(s): FILE: /var/www/html/app/code/Magento/Catalog/etc/adminhtml/system.xml -------------------------------------------------------------------------- FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE -------------------------------------------------------------------------- | WARNING | Copyright is missing or Copyright content/year is not valid -------------------------------------------------------------------------- FILE: /var/www/html/app/code/Magento/Catalog/etc/config.xml -------------------------------------------------------------------------- FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE -------------------------------------------------------------------------- | WARNING | Copyright is missing or Copyright content/year is not valid -------------------------------------------------------------------------- Failed asserting that 1 matches expected 0. 1 Semantic Version Checker because of XML changes: System changes (MINOR) | FailureDetailsLevelTarget/LocationCode/ReasonMINORdev/layout_settings/enable_id_handle/app/code/Magento/Catalog/etc/adminhtml/system.xml:0M302 A field-node was addedMINORdev/layout_settings/enable_attribute_set_handle/app/code/Magento/Catalog/etc/adminhtml/system.xml:0M302 A field-node was added | Level | Target/Location | Code/Reason | MINOR | dev/layout_settings/enable_id_handle/app/code/Magento/Catalog/etc/adminhtml/system.xml:0 | M302 A field-node was added | MINOR | dev/layout_settings/enable_attribute_set_handle/app/code/Magento/Catalog/etc/adminhtml/system.xml:0 | M302 A field-node was added -- | -- | -- | -- | -- | -- | -- | -- | -- | -- | --MINOR | dev/layout_settings/enable_id_handle/app/code/Magento/Catalog/etc/adminhtml/system.xml:0 | M302 A field-node was added |
|
@magento run all tests |
|
@magento run all tests |
|
@magento run Functional Tests B2B, Functional Tests CE, Functional Tests EE |
| * Copyright © Magento, Inc. All rights reserved. | ||
| * See COPYING.txt for license details. | ||
| * Copyright 2025 Adobe | ||
| * All Rights Reserved. |
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.
These copyrights are incorrect and were reverted previously. They are gone in 2.4.8-beta and 2.4.8-develop, but still present in 2.4.7-develop (on which this PR is branched).
Maybe @sidolov you can double check whether this propietary copyright notice does not end up in an actual release?
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.
Yes, it would be nice if there was a clear statement about which copyright to use. My last status was the changes in the PR.
2.4.8-beta2: https://github.com/magento/magento2/blob/2.4.8-beta2/app/code/Magento/Catalog/etc/di.xml#L2
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.
Correct format should be:
/**
* Copyright [first year code created] Adobe
* All rights reserved.
*/
So the year 2025 should be replaced with 2013 over here.
Same remark around the other files changed in this PR, please don't use the year 2025 unless it's a new file.
@wigman: is this what you were after? Or did I misunderstood?
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.
@hostep no, that was not wat I was after :) the copyright notice is not supposed to change to "all rights reserved", unless the decision to roll that change back has been reversed, and I need to check with Adobe core team if that can be prevented.
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.
So it changes from * Copyright © Magento, Inc. All rights reserved. to Copyright 2013 Adobe * All Rights Reserved.
All rights reserved has always been there as far as I know (example from 10 years ago). It's just that it was previously 'Magento', then 'Magento, Inc', which may no longer exist, and is now 'Adobe'.
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.
Ah, you are completely right. I misread. It thought it was a partial return of these changes, which were quite severe 😅 24ce222 thanks!
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.
No worries. You may be interested in magento/magento-coding-standard#492 then.
|
Hi @in-session, Thank you for this contribution! While going through the PR and testing activity, we have found out that the path you have set in app/code/Magento/Catalog/etc/config.xml is different than what you are fetching in view file and that’s the reason, after taking the PR changes, the functionality didn’t work. We have updated the path in DB and evaluated the PR, hence kindly do the needful. Following the SVC approval mentioned here, we received some feedback. Could you please address the following too?
|
|
@magento run all tests |
|
@in-session as mentioned here, can you please remove the product id handle from this PR in order to proceed ahead with it. |
Hi @in-session, are you working on these suggested changes or should I proceed to implement it. |
|
@engcom-Charlie Thank you for the feedback. I want to add a final clarification to ensure we are aligned on the goal of this PR. The main purpose of this contribution is to make the product ID handle configurable, allowing merchants to disable it for a significant performance improvement. With that in mind, does your request "remove the product id handle" mean:
I am ready to proceed with option 1 as it aligns with the goal, but I wanted to confirm with you first. Thank you! |
|
@magento run all tests |
Hi @in-session, thank you for the reply. The attribute_set layout handle was introduced in PR #36244. As a follow-up, this functionality should now be made configurable. This PR should focus on making the attribute_set handle configurable via system settings. We request the removal of any additional configuration related to the product_id handle, as it is no longer necessary. |
|
@engcom-Charlie Thank you for clarifying. I will update the PR to focus only on the attribute_set handle as requested. To ensure I fully understand the context for the future, I'd like to ask for a quick clarification on your comment that the product_id handle configuration is "no longer necessary"? From my perspective, the catalog_product_view_id_X handle is still a widely-used core feature, which is why I thought making it configurable would be a valuable addition. Did you mean it is "no longer necessary" within the specific scope of this PR, or is there a larger technical context or upcoming change that makes this configuration obsolete that I should be aware of? This information would be very helpful. I am proceeding with the requested code changes now. |
Hi @in-session, Thank you for your response and for considering the input. I have reviewed the changes in this PR, as well as from 36244 I have discussed the point you raised in comment with the internal team, and it has been agreed that we can proceed with option #1, keeping the product_id handle with disabled by default (ie. <enable_id_handle>0</enable_id_handle>in this PR. Kindly make according change so that, we can reach out for the approvals further. |
|
@engcom-Charlie That is fantastic news! Thank you very much to you and the internal team for taking the time to discuss this and for agreeing to include the full feature. I truly appreciate the reconsideration and I am happy to proceed. Before I commit the final change, I want to raise one critical point regarding the default value to ensure we make the best decision for the entire Magento community. Setting the default to <enable_id_handle>0</enable_id_handle> will introduce a backward compatibility breaking change. Merchants who upgrade and currently rely on catalog_product_view_id_X.xml layouts will have their customizations silently fail. This can be very frustrating and difficult for them to debug. The standard best practice to avoid this is to:
I am ready to implement whatever the team decides. If you are comfortable with this breaking change now, I will set the default to 0. I just felt it was my responsibility to ensure you were all fully aware of the potential impact on existing users. Please let me know your final decision. |
|
Hi @in-session, Thank you for highlighting the potential impact of changing the default value. That’s a very valid point. |

follow up:
#36244 (comment)
Related:
#102 (comment)
https://github.com/Vendic/module-optimize-cache-size/tree/main
#189 (comment)
Resolved issues: