Skip to content

Enable Analyzers disabled as a part of globalconfig merge from runtime #7887

Open

Description

@elachlan

Is your feature request related to a problem? Please describe

List of diagnostics that need to be investigated, fixed, and enabled.

Line  297: dotnet_diagnostic.CA1821.severity = none # TODO: warning
Line  466: dotnet_diagnostic.CA2208.severity = none # TODO: warning
Line  533: dotnet_diagnostic.CA2245.severity = none # TODO: warning
Line  851: dotnet_diagnostic.IL3000.severity = none # TODO: warning
Line 1137: dotnet_diagnostic.SA1302.severity = none # TODO: warning
Line 1179: dotnet_diagnostic.SA1400.severity = none # TODO: warning
Line 1191: dotnet_diagnostic.SA1404.severity = none # TODO: warning
Line 1608: dotnet_diagnostic.IDE0059.severity = none # TODO: warning

Describe the solution you'd like and alternatives you've considered

N/A

Will this feature affect UI controls?

N/A

Activity

  1. added
    api-suggestion
    untriaged
    on Oct 5, 2022
  2. elachlan commented on Oct 5, 2022

    @elachlan
    ContributorAuthor

    I started investigating CA1416(https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1416). Winforms would have to swap out its OsVersion static class with OperatingSystem.IsWindowsVersionAtLeast().

    @JeremyKuhne Coincidently this would remove the need for us to convert the NtDll PInvoke.

    Edit: runtime does cache the OSVersion.

  3. changed the title [-]Enable Analyzer disabled as a part of globalconfig merge from runtime[/-] [+]Enable Analyzers disabled as a part of globalconfig merge from runtime[/+] on Oct 5, 2022
  4. removed
    untriaged
    on Oct 5, 2022
  5. added
    enhancement
    untriaged
    and removed
    api-suggestion
    untriaged
    on Oct 5, 2022
  6. added this to the .NET 8.0 milestone on Oct 5, 2022
  7. elachlan commented on Oct 19, 2022

    @elachlan
    ContributorAuthor

    @RussKie CA2007 has single violation:

    Task.Run(Async Function() As Task
    Await _splashScreenCompletionSource.Task
    _formLoadWaiter.Set()
    End Function)

    I am unsure if ConfigureAwait(false) is correct. I am pretty sure it is, since it should be resolved inside the Task.Run().

  8. elachlan commented on Jan 24, 2023

    @elachlan
    ContributorAuthor

    @dreddy-work IDE0059 is complimented by CA1804. Can I enable CA1804 (Remove unused locals)?

  9. elachlan commented on Jan 24, 2023

    @elachlan
    ContributorAuthor

    Turns out CA1804 is replaced by IDE0059? But IDE0059 is replacing values with underscores.

  10. dreddy-work commented on Apr 4, 2023

    @dreddy-work
  11. elachlan commented on Apr 4, 2023

    @elachlan
    Author
  12. modified the milestones: .NET 8.0, .NET 9.0 on Aug 16, 2023
  13. JeremyKuhne commented on Jul 24, 2024

    @JeremyKuhne
    Member

    @elachlan I think we're good here now, aren't we?

  14. added
    waiting-author-feedback
    on Jul 24, 2024
  15. modified the milestones: .NET 9.0, Future on Jul 24, 2024
  16. elachlan commented on Jul 24, 2024

    @elachlan
    ContributorAuthor

    The ones that need to be addressed are marked as TODO in CodeAnalysis.src.globalconfig and CodeAnalysis.test.globalconfig

    	\winforms\eng\CodeAnalysis.src.globalconfig (8 hits)
    	Line  297: dotnet_diagnostic.CA1821.severity = none # TODO: warning
    	Line  466: dotnet_diagnostic.CA2208.severity = none # TODO: warning
    	Line  533: dotnet_diagnostic.CA2245.severity = none # TODO: warning
    	Line  851: dotnet_diagnostic.IL3000.severity = none # TODO: warning
    	Line 1097: # SA1206: Keyword ordering - TODO Re-enable as warning after https://github.com/DotNetAnalyzers/StyleCopAnalyzers/issues/3527
    	Line 1137: dotnet_diagnostic.SA1302.severity = none # TODO: warning
    	Line 1191: dotnet_diagnostic.SA1404.severity = none # TODO: warning
    	Line 1608: dotnet_diagnostic.IDE0059.severity = none # TODO: warning
    
      \winforms\eng\CodeAnalysis.test.globalconfig (7 hits)
    	Line   7: dotnet_diagnostic.CA1052.severity = none # TODO: warning
    	Line  14: dotnet_diagnostic.CA1416.severity = none # TODO: warning
    	Line  26: dotnet_diagnostic.CA1810.severity = none # TODO: warning
    	Line  35: dotnet_diagnostic.CA1822.severity = none # TODO: warning
    	Line  48: dotnet_diagnostic.CA2007.severity = none # TODO: warning
    	Line  51: dotnet_diagnostic.CA2014.severity = none # TODO: warning
    	Line 327: dotnet_diagnostic.xUnit1004.severity = silent # TODO: warning
    
  17. added
    untriaged
    and removed
    waiting-author-feedback
    on Jul 24, 2024
  18. removed
    untriaged
    on Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancement

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions