-
-
Notifications
You must be signed in to change notification settings - Fork 195
Fix misaligned indentation in comments #734
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
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #734 +/- ##
=======================================
Coverage 77.94% 77.95%
=======================================
Files 22 22
Lines 7998 8001 +3
=======================================
+ Hits 6234 6237 +3
Misses 1349 1349
Partials 415 415 🚀 New features to boost your workflow:
|
Not a reviewer on this repo but I reported experiencing this bug. Upon testing my project with this branch I'm happy to report it works fine now. PR LGTM |
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.
Thank you !!!!! LGTM 👍
Sorry I didn't fully test this early, but I just realized that this isn't a complete fix for the issue. While this addresses the initial error seen as a parsing error, if/when the files affected by this are saved their comments will not respect original indentation. Specifically this does not account for and fails if this test is added:
I have created #747 as a follow up. |
# commentH | ||
`, | ||
expected: ` | ||
# commentA |
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.
Ohh, I also overlooked that this test specifically makes it so that it's expected for this to modify comment indentation.
I'm not sure that this makes sense for the default behaviour. Since if comments are supposed to be parsed and respected the same as other fields, then changing indentation should be seen as breaking. However if someone wanted to "beautify" a file I could see this behaviour as beneficial via opt-in setting.
Fixes #713 🙏