Skip to content
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

User Story: .NET 6.0 developers can verify more APIs for their correct usage to speed up their development #43617

Closed
cathysull opened this issue Oct 19, 2020 · 6 comments
Assignees
Labels
area-Meta Cost:XL Work that requires one engineer more than 4 weeks Priority:1 Work that is critical for the release, but we could probably ship without Team:Libraries User Story A single user-facing feature. Can be grouped under an epic.
Milestone

Comments

@cathysull
Copy link
Member

cathysull commented Oct 19, 2020

In .NET 5, we shipped approximately 250 analyzers with the .NET SDK. Many of them already existed but were shipped out-of-band as NuGet packages. Now, .NET comes with an in-depth code analysis and code fixer experiences. This means developers don't have to purely rely on their choices based on reading code completion; .NET can help them pro-actively identify when their code has issues, right from the start. However, many of the code analyzers created don’t come with code fixers yet. We will look at telemetry and customer feedback to prioritize (around a TBD set of principles) which code analyzers would most benefit from code fixers along with which are most popular and consider adding fixers for those. Also, there is a sizable backlog of code analyzers that didn't get included in .NET 5, which will need to prioritized and considered. Furthermore, our goal for .NET 6 is that new features in .NET 6 should come with analyzers.

Work Items

The getting started guide should be referenced for the Definition of Done to be used for each issue.

External contributors: If you'd like to work on one of the issues marked as "up for grabs", please add a comment directly on that issue asking to get it assigned to you, and tag @carlossanlop or @buyaa-n.

Status Issue PR Title
❌ Closed #43971 N/A [Platform Compatibility Analyzer] Nested APIs shouldn't be allowed to expand the platform set
❌ Closed #33781 N/A Replace local allocations with stack allocated spans
✔️ @buyaa-n #45851 #4838 Referring to unknown platform names should result in warnings
✔️ @mahdiva #33765 #5242 Pass number of bytes to Buffer.BlockCopy
✔️ @NewellClark #33777 #4764 Use span-based string.Concat
✔️ @NewellClark #33784 #4806 Prefer string.AsSpan() over string.Substring() when parsing
✔️ @NewellClark #33789 #4726 Override Stream.ReadAsync/WriteAsync
✔️ @ryzngard #33806 #4841 Do not call Task.WhenAll with a single argument
✔️ @ryzngard #33807 #4841 Do not call Task.WaitAll with a single argument
✔️ @NewellClark #35343 #4687 Replace Dictionary<,>.Keys.Contains with ContainsKey
✔️ @stephentoub #42948 #4909 Environment.ProcessPath
✔️ @stephentoub #43257 #4909 Environment.CurrentManagedThreadId
✔️ @jeffhandley #43328 #5347 Warn on use of module initializer
✔️ @NewellClark #45552 #5116 Use String.Equals instead of String.Compare
✔️ @jkoritzinsky #46830 #5043 Expose interop manipulation of SafeHandle
✔️ @MeikTranel #47180 #4908 Use String.Contains(char) instead of String.Contains(String)
✔️ @maryamariyan #36064 #5244 Logging Analyzers
@mahdiva #45661 #5367 Call async methods when in an async method

Work Items Not Completed in .NET 6.0

Status Issue PR Title
Up for grabs #27997 Hide Thread.VolatileRead and Thread.VolatileWrite analyzer
@Mrnikbobjeff #33769 #4126 Use AsParallel() correctly
@fowl2 #33770 #4328 Do not use OfType<T>() with impossible types
@steveberdy #33794 #5383 Extract array of const to static readonly field
@psxvoid #33796 Constructor parameters should match property names
@chucker #33797 #4836 Don't guard Dictionary<K, V>.Remove(key) by ContainsKey(key)
@CollinAlpert #33798 #4851 Prefer Dictionary<K, V>.TryGetValue() over guarded indexer access
@CollinAlpert #33799 Prefer Dictionary<K, V>.TryAddValue(key) over guarded Add(key)
@Mrnikbobjeff #35695 #4130 Prefer ExactSpelling=true on [DllImport] for known APIs
@wzchua #40579 #4797 Prefer static HashData methods over ComputeHash
@cathysull cathysull added the User Story A single user-facing feature. Can be grouped under an epic. label Oct 19, 2020
@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added area-Meta untriaged New issue has not been triaged by the area owner labels Oct 19, 2020
@cathysull cathysull added the Priority:1 Work that is critical for the release, but we could probably ship without label Oct 30, 2020
@marek-safar marek-safar removed the untriaged New issue has not been triaged by the area owner label Nov 27, 2020
@marek-safar marek-safar changed the title User Story: Support more Analyzers & Code Fixers User Story: .NET Core developers can verify more APIs for their correct usage to speed up their development Nov 27, 2020
@danmoseley
Copy link
Member

cc @jeffhandley

@jeffhandley
Copy link
Member

cc @carlossanlop @buyaa-n

@danmoseley
Copy link
Member

@jeffhandley A nice list of analyzers done for 6.0. Is there more to do here for 6.0 or shall we move to 7.0?

@jeffhandley
Copy link
Member

I'd like to keep this in 6.0.0 until @mahdiva's assigned analyzers are completed, and the others in progress are captured with their final 6.0.0 status. Thereafter, I'll move this to 7.0.0 for the remainder.

@jeffhandley
Copy link
Member

Closing this user story. Only #45661 remains open for .NET 6.0; the remainder of the analyzers have been captured in #57797 for .NET 7.

@jeffhandley
Copy link
Member

Minor correction; #40579 might also land in .NET 6.0 (RC2).

@jeffhandley jeffhandley changed the title User Story: .NET Core developers can verify more APIs for their correct usage to speed up their development User Story: .NET 6.0 developers can verify more APIs for their correct usage to speed up their development Aug 22, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Oct 4, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Meta Cost:XL Work that requires one engineer more than 4 weeks Priority:1 Work that is critical for the release, but we could probably ship without Team:Libraries User Story A single user-facing feature. Can be grouped under an epic.
Projects
No open projects
Development

No branches or pull requests

8 participants