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

[Issue] Add default empty array in constructor #38165

Closed
5 tasks
m2-assistant bot opened this issue Nov 9, 2023 · 8 comments · Fixed by #38163
Closed
5 tasks

[Issue] Add default empty array in constructor #38165

m2-assistant bot opened this issue Nov 9, 2023 · 8 comments · Fixed by #38163
Assignees
Labels
Area: Framework Component: Store Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Priority: P3 May be fixed according to the position in the backlog. Progress: done Reported on 2.4.x Indicates original Magento version for the Issue report. Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch

Comments

@m2-assistant
Copy link

m2-assistant bot commented Nov 9, 2023

This issue is automatically created based on existing pull request: #38163: Add default empty array in constructor


Description (*)

This class its constructor argument $tagGenerators is empty by default in PHP, so that via DI argument types in di.xml files the array is filled automatically. This actually means that - without any runtime configuration of this argument - the PHP class has a required argument $tagGenerators.

In my cases, this is breaking DI compile when the modules Magento_DirectoryGraphQl and Magento_StoreGraphQl are disabled (and actually a lot of people will disable this module if they are not building a headless shop). This PR is a simple but required fix.

Related Pull Requests

None

Fixed Issues (if relevant)

None

Manual testing scenarios (*)

Install Magento 2. Next, add a composer replacement of magento/module-store-graph-ql and magento/module-directory-graph-ql and run composer update to remove these dependencies. Alternatively, just disable the modules Magento_DirectoryGraphQl and Magento_StoreGraphQl. Next, run bin/magento setup:di:compile. It should fail. With this patch, it should work.

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • README.md files for modified modules are updated and included in the pull request if any README.md predefined sections require an update
  • All automated tests passed successfully (all builds are green)
@m2-assistant m2-assistant bot added the Priority: P3 May be fixed according to the position in the backlog. label Nov 9, 2023
@alpesh475
Copy link

@magento give me 2.4-develop instance - upcoming 2.4.x release

Copy link

Hi @alpesh475. Thank you for your request. I'm working on Magento instance for you.

Copy link

@engcom-Hotel engcom-Hotel self-assigned this Nov 21, 2023
Copy link
Author

m2-assistant bot commented Nov 21, 2023

Hi @engcom-Hotel. Thank you for working on this issue.
In order to make sure that issue has enough information and ready for development, please read and check the following instruction: 👇

  • 1. Verify that issue has all the required information. (Preconditions, Steps to reproduce, Expected result, Actual result).
  • 2. Verify that issue has a meaningful description and provides enough information to reproduce the issue.
  • 3. Add Area: XXXXX label to the ticket, indicating the functional areas it may be related to.
  • 4. Verify that the issue is reproducible on 2.4-develop branch
    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and stop verification process here!
  • 5. Add label Issue: Confirmed once verification is complete.
  • 6. Make sure that automatic system confirms that report has been added to the backlog.

@engcom-Hotel
Copy link
Contributor

Hello @jissereitsma,

Thanks for the report and collaboration!

We have tried to reproduce the issue in the 2.4-develop branch and the issue is reproducible for us after following the below steps:

  1. Install Magento 2.4-develop
  2. Disable the modules Magento_DirectoryGraphQl and Magento_StoreGraphQl via the below command:
    bin/magento module:disable Magento_DirectoryGraphQl Magento_StoreGraphQl
  3. Then run the bin/magento setup:upgrade command.
  4. The below error has been occurs:
    image

Hence confirming the issue.

Thanks

@engcom-Hotel engcom-Hotel added Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Component: Store Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch Reported on 2.4.x Indicates original Magento version for the Issue report. Area: Framework labels Nov 21, 2023
@github-jira-sync-bot
Copy link

✅ Jira issue https://jira.corp.adobe.com/browse/AC-10583 is successfully created for this GitHub issue.

Copy link
Author

m2-assistant bot commented Nov 21, 2023

✅ Confirmed by @engcom-Hotel. Thank you for verifying the issue.
Issue Available: @engcom-Hotel, You will be automatically unassigned. Contributors/Maintainers can claim this issue to continue. To reclaim and continue work, reassign the ticket to yourself.

@alpesh475
Copy link

give me 2.4-develop instance - upcoming 2.4.x release

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Framework Component: Store Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Priority: P3 May be fixed according to the position in the backlog. Progress: done Reported on 2.4.x Indicates original Magento version for the Issue report. Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch
Projects
Development

Successfully merging a pull request may close this issue.

4 participants