Skip to content

codegeneration may fail on no spaces between end of php tags and semicolon when minify is enabled on the backend #14077

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

Closed
woshka opened this issue Mar 13, 2018 · 4 comments
Labels
Issue: Cannot Reproduce Cannot reproduce the issue on the latest `2.4-develop` branch Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Progress: needs update

Comments

@woshka
Copy link

woshka commented Mar 13, 2018

There is a problem whwn minfy is enabled in the backend
if there are some spaces in php inline tags forexample

in example above if the ?> is near the end of statement semicolon ; then it will result in an error on di:compile code generation and we have to edit the php codes and change it like this

so that the code generation will work when the minify is turned on in the backend
This would happened on some purchased modules which they have such coding structure and we have to manually edit the code and things go fine but such an issue by code generation is not correct while it is folloing the php coding standard and all the IDEs wont get error when there is not a such space

Preconditions

  1. magento 2.1.3
  2. Cpanel
  3. Centos 6.9

Steps to reproduce

  1. install clean magento
  2. create a module with no space between semicolon and end of the tag
  3. use di:compile for code generation

Expected result

  1. the preprocessed file should be generated

Actual result

  1. code generation will result in an error
@magento-engcom-team magento-engcom-team added Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed labels Mar 13, 2018
@magento-engcom-team
Copy link
Contributor

@woshka, thank you for your report.
We were not able to reproduce this issue by following the steps you provided. Please provide more detailed steps to reproduce or try to reproduce this issue on a clean installation or latest release.

@magento-engcom-team magento-engcom-team added Progress: needs update Issue: Cannot Reproduce Cannot reproduce the issue on the latest `2.4-develop` branch labels Mar 13, 2018
@hostep
Copy link
Contributor

hostep commented Mar 13, 2018

@woshka: this sounds a little bit like this problem: #5316

But I'm very confused about your statement that enabling/disabling minification has influence on the code being generated by the setup:di:compile command, I don't think those two things are related?

Maybe you can give a concrete example? I think you were trying to add an example, but we can't see it. Maybe this guide can help you in formatting your example code?

It's also highly recommended you update Magento to the latest version in the 2.1.x range (2.1.12 is the latest at the moment of writing) because you are missing important security fixes: https://magento.com/security

@magento-engcom-team
Copy link
Contributor

@woshka we are closing this issue due to inactivity. If you'd like to update it, please reopen the issue.

@magento-engcom-team
Copy link
Contributor

@woshka, we are closing this issue due to inactivity. If you'd like to update it, please reopen the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue: Cannot Reproduce Cannot reproduce the issue on the latest `2.4-develop` branch Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Progress: needs update
Projects
None yet
Development

No branches or pull requests

3 participants