-
Notifications
You must be signed in to change notification settings - Fork 8
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
feature branch: lint Twig files with twigstan/twigstan #95
base: main
Are you sure you want to change the base?
Conversation
Before : 18/10/2024 : 17 errors found :
|
77b7a47
to
b9ea9dd
Compare
After :
|
8fc4d16
to
7e7edc1
Compare
1c1c766
to
3e27c17
Compare
After looking at this, I spotted a few bugs/problems in TwigStan that I solved. I created a PR with updates: |
dfcce5d
to
73af736
Compare
@@ -45,7 +45,7 @@ | |||
|
|||
<tr> | |||
<th>Birthay</th> | |||
<td>{{ dto.birthday|date('Y-m-d') }}</td> | |||
<td>{{ dto.birthday ? dto.birthday|date('Y-m-d') : 'NA' }}</td> |
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.
Bug found ! 🐛
Hello @ruudk, I have rebased the branch and updated TwigStan and I have many new errors, it is expected? |
Did you also update twig/twig? |
And phpstan/phpstan |
Yes, it is Phpstan 2 (2.0.2) now! I have reverted Phpstan to 1.0.2 for now. You can drop me a message here, but you think the PHPStab 2.0 can be done. |
|
I found the problem. Twig 3.15 was released in the weekend without me knowing it. I made sure this won't happen again by doing:
From now on, TwigStan will support specific / fixed versions of Twig. Please update Btw, PHPStan 2 is not yet supported, it will be soon: so it would be best if you could use 1.12 for now. |
This branch adds twigstan/twigstan to lint Twig files with types check.