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

Ignore InternalsVisibleTo attribute section sample does not show the rule ID #44197

Closed
siewers opened this issue Jan 9, 2025 · 3 comments · Fixed by #44240
Closed

Ignore InternalsVisibleTo attribute section sample does not show the rule ID #44197

siewers opened this issue Jan 9, 2025 · 3 comments · Fixed by #44240
Labels
dotnet-fundamentals/svc help wanted Good for community contributors to help [up-for-grabs] in-pr This issue will be closed (fixed) by an active pull request.

Comments

@siewers
Copy link

siewers commented Jan 9, 2025

Type of issue

Typo

Description

The section "Ignore InternalsVisibleTo attribute" section shows an example with a missing rule ID:

dotnet_code_quality.CAXXXX.ignore_internalsvisibleto = true

But it should be:

dotnet_code_quality.CA1852.ignore_internalsvisibleto = true

Page URL

https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1852

Content source URL

https://github.com/dotnet/docs/blob/main/docs/fundamentals/code-analysis/quality-rules/ca1852.md

Document Version Independent Id

8096f4f0-36fe-92d7-c4e8-b761f2197010

Article author

@gewarren

Metadata

  • ID: 94bd55fe-ca92-f1c4-c1ac-6f1cffeac722
  • Service: dotnet-fundamentals

Related Issues

@dotnet-policy-service dotnet-policy-service bot added the ⌚ Not Triaged Not triaged label Jan 9, 2025
@gewarren gewarren added help wanted Good for community contributors to help [up-for-grabs] and removed ⌚ Not Triaged Not triaged labels Jan 10, 2025
@BartoszKlonowski
Copy link
Contributor

BartoszKlonowski commented Jan 11, 2025

@gewarren I don't think this is incorrect. This section is included in two rules: CA1852 and CA1812. So having CAXXXX makes this section "generic" for both.
If we would to "fix" this issue, we would show
dotnet_code_quality.CA1852.ignore_internalsvisibleto = true
in the page of CA1812, which would lead to another issue opened.

@siewers
Copy link
Author

siewers commented Jan 11, 2025

How am I supposed to know the documentation section is generic? It makes no sense to me that this section shows XXX when it's displayed on a specific rule. I honestly thought I was supposed to use XXX as the rule ID to begin with until I realized it didn't work and I had to specify the rule ID, although the docs didn't specify it.

If this really is so valuable to keep generic, then at least write so and mention that XXX should be replaced with the actual rule ID the article is for.

@BartoszKlonowski
Copy link
Contributor

Sure, @siewers! I totally get your point 👍
Let me launch a PR for that and we will see what is the feedback.

@dotnet-policy-service dotnet-policy-service bot added the in-pr This issue will be closed (fixed) by an active pull request. label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dotnet-fundamentals/svc help wanted Good for community contributors to help [up-for-grabs] in-pr This issue will be closed (fixed) by an active pull request.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants