-
Notifications
You must be signed in to change notification settings - Fork 4.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
Swift Highlighting Broken #6643
Comments
Looks like with this file you are encountering a combination of jtbandes/swift-tmlanguage#13 & jtbandes/swift-tmlanguage#7 |
Yes, it seems like. This is especially a serious problem for SwiftLint where almost all files contain string blocks in one or the other way. |
I'll try to resolve these soon but unfortunately I don't have a way of testing GitHub's highlighting aside from waiting for the next release (#6603 (comment)). |
Closing as syntax highlighting issues should be opened on the upstream repos as per the troubleshooting doc. |
Fair enough. However, I opened the issue here because I propose to revert the change until the problems are fixed. It's really annoying to work on code reviews at the moment. |
As a temporary suggestion, if you are able to use the VS Code's GitHub integration to do code reviews, you might have a better experience as VS Code is able to use the same grammar without experiencing the errors. |
+1 to reverting until problems are fixed, it's been really hard to read code for the past little bit |
Another +1 to fixing or reverting this soon. It makes diffs like this pretty hard to understand: |
Guys, really ... it has been over a month now that the highlighting is broken. I appreciate all your work and I very well know that a fix usually is not ready within a few minutes/hours/days. However, a simple revert to the previous state of the highlighter would have been perfectly sufficient to allow people to work with Swift code on GitHub again. Honestly, (re)viewing Swift code at the moment is simply impossible and has been for over a month. I kindly ask you again to roll back the grammar change! 🙏 |
This is out of my control as is not a problem with the grammar... it's a problem with the highlighting engine which coincided with the last release. Rolling back the release will make no difference. The team responsible for the highlighting engine is aware of the issue and looking into it. Feel free to open a support ticket referencing #6668 if you want to add more to the known issue for passing on to the relevant team. |
With the v7.28.0 release, the syntax highlighting for Swift code makes some files unreadable. See this file in the SwiftLint repository as an example.
Many parts get a red background color in dark mode, which makes it very hard to work with them, especially when the confusing highlighting takes action in code reviews where only a small (red) part is visible. My current solution is to review the changes locally which is uncomfortable.
If a quick fix cannot be found, I'd vote for a rollback to the previous Swift grammar.
FYI: @jtbandes
The text was updated successfully, but these errors were encountered: