question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SA1633 Context menus appear when rule is Disabled

See original GitHub issue

After disabling SA1633, StyleCop still presents the options Add StyleCop setting file to the project and Add file header to the Intellisense context menu. I’m more-so looking for a way to disable these menu items as I accidentally click them often. I do not use file headers, and I use .editorconfig to control all of my analyzer settings. However, I noticed both menus are both directly related to SA1633, so may be they should be hiding when this option is disabled.

This is the context menu items that still appear that I would like to disable. Context Menu Both of these sub-menu items specifically call out SA1633. Add Settings File Standard Header Message

Issue Analytics

  • State:closed
  • Created 2 months ago
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
bjornhellandercommented, Jul 23, 2023

Alright, now I see it too. I was disabling the rule by using “Configure or suppress issues”/“Configure SA1633 severity”/“None” in that same context menu. When doing that, the severity is set to “none” in the .editorconfig file, but if I instead double-click on the .editorconfig file and set it to Disabled, the severity is set to “silent” which in my opinion is not a good thing. Silent means that the rule is executed and the diagnostic is reported, but it is simply not shown to you. But code fixes are still offered for diagnostics with severity silent, so that is why you keep seeing it in the content menu. I would say that this is a bug either in the compiler or in Visual Studio.

If you look at the .editorconfig file some other way (notepad, open with, etc), does it say “silent” for SA1633? If so, I hope that if you change silent to none, you will stop getting the context menu item about adding a header.

You will still be able to get the context menu item for adding the settings file in some situations, but it should in that case mention another rule. The reason for this is that the code fix for adding the settings file is configured to trigger on more rules than SA1633.

0reactions
sharwellcommented, Jul 25, 2023

Resolving as external

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Disable the StyleCop add project and header info ...
When set to disabled through Visual Studio's editor, ... SA1633.severity = none . This will stop the context menus from appearing.
Read more >
Disabled ContextMenu controls never close · Issue #4439
The context menu remains even after the parent view is removed, allowing you to build up a large number of dead context menus...
Read more >
How to Enable or Disable Context Menus on Windows
To disable the File Explorer context menu, select the Enabled option. Next, click Apply and then click OK. Finally, restart your device to...
Read more >
"Enable context menus and dragging and dropping" is ...
Open Regedit.exe and go to: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer. Delete the registry value named ...
Read more >
Disable Stardock's context menu options
Stardock's Object Desktop Context Menu Options which can be disabled Using some Stardock's (Object Desktop) apps to customize the OS can be ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found