Skip to content

#210: Fixed HtmlDirectiveSniff.php from causing the Fatal Error for c… #211

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

Merged
merged 1 commit into from
Aug 5, 2021

Conversation

asheem-patro
Copy link
Contributor

@asheem-patro asheem-patro commented Aug 2, 2021

…lass not found

Fixes #210

@ihor-sviziev
Copy link
Collaborator

Hi @asheem-patro,
Could you provide some steps to reproduce?

@asheem-patro
Copy link
Contributor Author

Hi @ihor-sviziev

Install the magento-coding-standards in some different directory other than the Magento root. Then run the phpcs using /var/www/html/magento-coding-standard/vendor/bin/phpcs --standard=Magento2 app/code/

@asheem-patro
Copy link
Contributor Author

@ihor-sviziev - \Magento\Framework\Filter\Template this framework class has been used inside \Magento2\Sniffs\Html\HtmlDirectiveSniff to use some constants. Due to which we are getting the class not found error. It is having a problem in using the magento-coding-standard on the bitbucket pipelines.

Please let me know if you want some more clarifications.

@ihor-sviziev
Copy link
Collaborator

@asheem-patro,
Interesting... for some reason, it's not failing when we're running it inside the coding standard repo...
https://github.com/magento/magento-coding-standard/runs/3218975370?check_suite_focus=true
image

I think it has to fail. We should fix that at first, and later on accept your PR :)

@asheem-patro
Copy link
Contributor Author

@ihor-sviziev - I am also wondering the same thing. It still fails for me without this fix. Complete error with Stack trace is in below screenshot.

image

Copy link
Collaborator

@ihor-sviziev ihor-sviziev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved ✔

Changes looks good.

@ihor-sviziev
Copy link
Collaborator

ihor-sviziev commented Aug 2, 2021

Note: I just checked - this sniff was added in #209 and wasn't covered with any tests. That's why the tests are not failing.

This PR fixes #210

@sivaschenko
Copy link
Member

@magento import pr to magento-commerce/magento-coding-standard

@magento-engcom-team
Copy link
Contributor

@sivaschenko the pull request successfully imported.

@magento-devops-reposync-svc magento-devops-reposync-svc merged commit fd643e8 into magento:develop Aug 5, 2021
magento-devops-reposync-svc pushed a commit that referenced this pull request May 10, 2023
B2B-2606: Graphql Parser called at least 3 times per request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants