Hello there,
I've recently been using the Code Issues page to "cleanup" our code from various issues, and I'm facing a rather frustrating bug. When clicking on the individual items, it is not always correctly navigating me to the correct line number. I'm not quite sure what the cause of this is, but this only seems to happen once I start adding code to the file in question and continue downwards.
In addition to this, it would be good if the issues were ordered in line number order.
Hi Mark,
Thank you for reaching out to us. I've tried to replicate the problem on my side and can confirm that navigating by clicking on an issue in the issues list will lead to an incorrect position if the containing files were modified. I would like to note that there are two modes in which the CodeRush Code Analysis engine may work - running CodeRush Diagnostics and loading from Visual Studio CodeAnalysis engine. You can switch modes using the CR button on Code Issues window header as shown on the image below. Consider proceeding to this link to read more about Static Code Analysis in CodeRush.

Run CodeRush Diagnostics mode will analyze a solution using only the built-in CodeRush diagnostics and in this mode, the described issue appears. In this mode, it will require CodeRush to subscribe to a file modification event and provide recalculations once such an event fires (note please, that it might be time-consuming).
In the second mode, CodeRush will use the built-in Visual Studio diagnostics with only CodeRush diagnostics registered in Visual Studio (you may choose which diagnostics to include on the Options | Editor | The language | CodeAnalysis | Code Issues Catalog page). In that mode, with Display issues from the Visual Studio Error List in the Code Issues tool window (you may find it at the Options | Editor | The language | Code Analysis | General page) option enable, position tracking is enabled so the issue isn't reproducible. Check out the screencast I've recorded to illustrate the issues position tracking mechanism in this mode.
From your post, it's unclear if you're using the first Code Analysis mode? Please confirm this.
I look forward to hearing from you.
Mark, to process your recent post more efficiently, I created a separate ticket on your behalf (T668862: No way to sort issues by line number order). It has been placed in our processing queue and will be answered shortly.
Igor, many thanks for your follow up in regards to my reported issue. I can confirm that we are using the First Analysis Mode due to the Solution Size. In previous evaluations we made of CodeRush we discovered the "Static Analysis" to be too resource intensive during normal usage of Visual Studio.
I also fully appreciate that CodeRush would require modifications to subscribe to file modification events and provide recalculation(s) once such an event occurs. However, the changes I have been making on whole, are adding code to the end of the affected line. I would of thought, with the fact that the list contains both a line number and character number, that in this instance it would still navigate as expected?
And thank you for raising a separate ticket in regards to the ordering of the reported "Code Issues".
Hi Mark,
You're always welcome.
Thank you for the confirmation. Answering your question, as you may know, CodeRush is built on top of the .NET Compiler Platform ("Roslyn") integrated in Visual Studio, which includes a mechanism for tracking nodes - it allows a developer to annotate a concrete syntax node in the syntax tree to further find it (e.g., in cases when you need to modify the tree and then find a node corresponding to a node from an old tree). Simply speaking, the final algorithm will work through the described mechanism - CodeRush will detect if there are previously found issues in a currently active file and if so, it will use Roslyn to annotate nodes which represent statements that require a developer's attention and will subscribe to the Visual Studio file modification event. Once such an event fires, CodeRush will traverse through the syntax tree of a currently active file, find previously annotated nodes, and renew their positions in the Code Issues window's grid. The node position consists of two values as you mentioned - the line number and the character number, so the answer is yes, navigation will work as expected. Note please that the final algorithm and implementation will be much more complex.
Also, I want to point out that after having a discussion with the team, we decided to consider implementing such a functionality in the nearest planning.
Stay tuned for further updates.