-
Notifications
You must be signed in to change notification settings - Fork 75
Enable more rules for SelfCheck #756
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
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5f98eaf to
f59467b
Compare
0c0d1fa to
6fb2501
Compare
knocte
reviewed
Aug 6, 2025
Collaborator
|
@webwarrior-ws let's rebase this one when you can and 2 more things:
|
Fixing the warning for MaxLinesInLambdaFunction rule. Co-authored-by: webwarrior-ws <reg@webwarrior.ws>
Fixing the warning for MaxLinesInValue rule.
Fixing the warning for MaxLinesInFunction rule: ``` ========== Linting C:\Users\PC\source\repos\FSharpLint\src\FSharpLint.Core\Application\Configuration.fs ========== Function was 121 lines long, suggested to be less than 100 lines long. Error on line 611 starting at column 4 let flattenConfig (config:Configuration) = ```
Fixing the warning for MaxLinesInMember rule.
knocte
reviewed
Aug 13, 2025
src/FSharpLint.Core/Rules/Conventions/UsedUnderscorePrefixedElements.fs
Outdated
Show resolved
Hide resolved
knocte
reviewed
Aug 13, 2025
src/FSharpLint.Core/Rules/Formatting/PatternMatchFormatting/PatternMatchClauseIndentation.fs
Outdated
Show resolved
Hide resolved
knocte
reviewed
Aug 13, 2025
...FSharpLint.Core/Rules/Formatting/PatternMatchFormatting/PatternMatchExpressionIndentation.fs
Outdated
Show resolved
Hide resolved
knocte
reviewed
Aug 13, 2025
src/FSharpLint.Core/Rules/Formatting/TupleFormatting/TupleCommaSpacing.fs
Show resolved
Hide resolved
knocte
reviewed
Aug 13, 2025
src/FSharpLint.Core/Rules/Formatting/TupleFormatting/TupleParentheses.fs
Outdated
Show resolved
Hide resolved
knocte
reviewed
Aug 13, 2025
knocte
reviewed
Aug 13, 2025
knocte
reviewed
Aug 13, 2025
Collaborator
Let's rather squash this commit above with the one that disabled the rule in the first place |
Fixing the warning for MaxLinesInFile rule: ``` ========== Linting C:\Users\PC\source\repos\FSharpLint\src\FSharpLint.Core\Framework\HintParser.fs ========== File suggested to be less than 1001 lines long. Error on line 1001 starting at column 0 ^ See https://fsprojects.github.io/FSharpLint/how-tos/rules/FL0062.html -------------------------------------------------------------------------------- ```
ad471a1 to
21e5416
Compare
Contributor
Author
Done. |
knocte
reviewed
Aug 13, 2025
4a0b242 to
3e67900
Compare
This rule was introduced in v0.24.2 and was meant to be enabled by default, as explained in the documentation and in a blog-post of mine[1]. However we didn't realised about this mistake until now, but it's a good time to do it now given that this PR is making FSharpLint's own codebase respect even more of its own rules. [1] https://knocte.blogspot.com/2024/03/safety-shouldnt-be-opt-in.html
By converting the functions to tail-recursive using continuation-passing style. And silence them for functions that are very hard to convert to tail-recursive.
This refactoring activates all rules by default and only deactivates the specified ones.
Instead of Newtonsoft.Json, given that FSharpLint has moved away already from Newtonsoft.
To address PR review.
3e67900 to
a605197
Compare
To address PR review. Also include previous commit in .git-blame-ignore-revs since it's only renames.
3894866 to
c5388d4
Compare
fecade0 to
7fdbff0
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Supersedes #668