-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
events.xml cant have no childrens, others can [Magento 2.2.4] #15931
Comments
Hello @NopeNopeNope, thank you for your report. Looks like the only thing which should be changed is set minOccurs from "1" to "0":
If you'd like, you can create pull request to fix this issue. |
@engcom-backlog-nickolas are you sure you need to fix this by setting The I think your suggestion will make the code less strict and therefore not a step in the good direction. Please advice to not add an empty |
Whatever way they choose, it should be unified. Right now there can be empty XMLs, but no empty events.xml. |
@arnoudhgz if you downvote something, one should have the courage to explain why its a bad idea. Please elaborate if possible. |
@NopeNopeNope I don't think everything should work the same, a Don't add empty files if you need them. My opinion is that it should not be unified with 'whatever way they choose'. The can improve other xsds, but they should never downgrade the xsd for the events by making it less strict just to have in a unified way. |
I ran into this problem myself sometimes, when putting some xml code in comments in the I agree that having empty files in a module makes no sense, but for quickly debugging something it would still be nice if this would be allowed. |
Also in that case, quickly testing something should not be more important than having strict code, which in the end is more error proof. |
…#15931 - change declaration of minOccurs #mm18pl
Hi @lisovyievhenii. Thank you for working on this issue.
|
I don't see how allowing empty |
Hi @NopeNopeNope. Thank you for your report. The fix will be available with the upcoming 2.3.1 release. |
Hi @NopeNopeNope. Thank you for your report. The fix will be available with the upcoming 2.2.8 release. |
I am facing this issue anyone knows: Invalid Document |
Preconditions
Steps to reproduce
Example for
di.xml
:php bin/magento setup:upgrade && php bin/magento cache:flush && php bin/magento cache:clean
Expected result
Actual result
This is not logically as it should render fine, process the file even with no config in it, as it process other files.
The text was updated successfully, but these errors were encountered: