Conversation
… revision call instead of HEAD work items
|
This currently has an issue with branched documents across different projects due to I am currently working on a solution to address this and ensure accurate results. |
…all projects to support branched documents with cross-project work item references
|
Summary Fixes #5 - Before: 156 items returned Root Cause Step 3 of the algorithm used Changes
Notes
|
schaveyt
left a comment
There was a problem hiding this comment.
Changes to functionality look good. Changes to the coding style look no bueno.
Add the following to the .csproj
<!--
Workaround for IDE0005: removed unused directives, we must enable XML
documentation and ignore the warning it generates (CS1591)
-->
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<NoWarn>IL2026;IL2104;CS1591</NoWarn>
<AnalysisLevel>10.0</AnalysisLevel>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>- Add .editorconfig with CRLF line endings, 4-space C# indent, and csharp_prefer_braces=always:warning to require curly braces on all control flow statements - Enable EnforceCodeStyleInBuild and TreatWarningsAsErrors in Polarion.csproj so style violations fail the build - Suppress IL2026/IL2104 trim warnings that were previously unsilenced - Pin AnalysisLevel to 10.0 for deterministic analyzer behavior
- Add missing final newlines to 12 files (mostly Connection/, Entities/,
and several Client/ partials)
- Remove trailing whitespace from blank lines across 24 files
- Fix lambda brace placement (match => { → match =>\n{)
- Add missing space in argument list (PolarionClient_ExportModuleToMarkdownGroupedByHeadingAsync.cs)
- Normalize target-typed new expressions (new (...) → new(...))
Enforce csharp_prefer_braces = always via dotnet_diagnostic.IDE0011.severity in .editorconfig so violations now fail the build. Fixed all 17 violations across 4 files: PolarionClient_GetWorkItemsByModuleRevisionAsync.cs, PolarionClient_SearchWorkitemAsync.cs, PolarionClient_SearchWorkitemInBaselineAsync.cs, and OutlineNumberComparer.cs. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
36d6567 to
d7b8862
Compare
FormattingAdded requested coding style changes to project with a .editorconfig and enforce code style in build. Ran Benchmark Results:
|
| Scenario | develop |
This Branch | Speedup |
|---|---|---|---|
| Doc A / Project 1 | 282.3s | 65.8s | 4.3x faster |
| Doc A / Project 2 | 225.7s | 63.4s | 3.6x faster |
| Doc B / Project 1 | 63.7s | 10.3s | 6.2x faster |
| Doc B / Project 2 | 114.5s | 29.3s | 3.9x faster |
| Total | 686.2s | 168.8s | 4.1x faster |
Work Item Completeness
| Scenario | develop |
This Branch | Delta |
|---|---|---|---|
| Doc A / Project 1 | ERROR (0) | 2,720 | Fixed - was throwing exception |
| Doc A / Project 2 | 563 | 2,684 | +377% |
| Doc B / Project 1 | 158 | 160 | +1% (stable) |
| Doc B / Project 2 | 296 | 1,396 | +372% |
Key Findings
-
Critical bug fixed: On
develop, one scenario fails entirely with a URI resolution error when a document references work items from another project. This branch resolves it completely. -
Missing work items recovered:
developwas only searching within the current project scope, returning a fraction of work items for branched documents with cross-project references. The cross-project baseline search recovers 4-5x more items in affected scenarios. -
Significant performance improvement: Every scenario is 3.6x to 6.2x faster. The new baseline-at-revision search strategy is both more correct and more efficient.
-
No regressions: Documents without cross-project references show near-identical counts (158 vs 160), confirming backward compatibility.
FrogmanL
left a comment
There was a problem hiding this comment.
Reviewed with Eric. Reviewed test results and methodology. No issues found. Approve.
Talked to @schaveyt. No additional review is required.
Fix potentially missing work items when getting items by module revision due to work items being moved or deleted after the specific revision. Updated to query at baseline revision for work items instead of using call that queries work items at the HEAD revision.