Skip to content

Conversation

brentschmaltz
Copy link
Member

This PR returns to returning ValidationResult defined in IdentityModel.

This resolves issues:

  1. When 8.x assemblies have different versions: [Bug] Version 8.13.1 breaks CoreWCF (MissingMethodException) #3291
  2. Remove dependency on Microsoft.Identity.Abstractions: Why does Microsoft.IdentityModel.Tokens 8.13.1 now depend on Microsoft.Identity.Abstractions? #3290

Remove dependency on Microsoft.Identity.Abstractions
Copy link

Summary

Summary
Generated on: 8/14/2025 - 4:53:55 PM
Coverage date: 8/14/2025 - 4:43:43 PM - 8/14/2025 - 4:53:22 PM
Parser: MultiReport (60x Cobertura)
Assemblies: 1
Classes: 7
Files: 2
Line coverage: 80.3% (620 of 772)
Covered lines: 620
Uncovered lines: 152
Coverable lines: 772
Total lines: 483
Branch coverage: 67.8% (228 of 336)
Covered branches: 228
Total branches: 336
Method coverage: Feature is only available for sponsors

Coverage

Microsoft.IdentityModel.JsonWebTokens - 80.3%
Name Line Branch
Microsoft.IdentityModel.JsonWebTokens 80.3% 67.8%
Microsoft.IdentityModel.JsonWebTokens.JwtTokenUtilities 100%
System.Text.RegularExpressions.Generated 80.3% 67.8%
System.Text.RegularExpressions.Generated 80.3% 67.8%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F12A1AEDDDFE32BA
DF4DBFF323AF1BCB48B9F9721B7CD3E05F5E034CF225E3DF8__CreateJweRegex_1
79.2% 68%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F12A1AEDDDFE32BA
DF4DBFF323AF1BCB48B9F9721B7CD3E05F5E034CF225E3DF8__CreateJwsRegex_0
81.4% 67.6%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F334844C618E00D3
CEC5D3FE0D00CF0141BBEE98635313BB2CB8D3921464CE05A__CreateJweRegex_1
79.2% 68%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F334844C618E00D3
CEC5D3FE0D00CF0141BBEE98635313BB2CB8D3921464CE05A__CreateJwsRegex_0
81.4% 67.6%

@keegan-caruso
Copy link
Contributor

For reference, 8.13.0 diff: 8.13.0...brentsch/ValidationResult

@pmaytak pmaytak requested a review from Copilot August 14, 2025 18:40
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR returns to using ValidationResult defined in IdentityModel instead of OperationResult from Microsoft.Identity.Abstractions. This resolves assembly version compatibility issues when different 8.x assemblies have varying versions and removes the dependency on Microsoft.Identity.Abstractions.

Key Changes:

  • Replace all OperationResult<TResult, TError> usages with ValidationResult<TResult, TError>
  • Remove dependency on Microsoft.Identity.Abstractions package
  • Update all validation method signatures and implementations throughout the codebase
  • Remove using statements for Microsoft.Identity.Abstractions

Reviewed Changes

Copilot reviewed 58 out of 58 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
Multiple test files Updated test method signatures and variable names from OperationResult to ValidationResult
ValidationResult.cs New implementation of ValidationResult replacing OperationResult dependency
ValidationError.cs Removed inheritance from OperationError
Multiple validator files Updated method signatures and return types to use ValidationResult
Multiple handler files Updated validation method signatures and implementations
Project files Removed Microsoft.Identity.Abstractions package reference
API files Updated public API surface to reflect ValidationResult usage

Copy link

Summary

Summary
Generated on: 8/14/2025 - 7:06:45 PM
Coverage date: 8/14/2025 - 6:55:36 PM - 8/14/2025 - 7:06:14 PM
Parser: MultiReport (60x Cobertura)
Assemblies: 1
Classes: 7
Files: 2
Line coverage: 80.3% (620 of 772)
Covered lines: 620
Uncovered lines: 152
Coverable lines: 772
Total lines: 483
Branch coverage: 67.8% (228 of 336)
Covered branches: 228
Total branches: 336
Method coverage: Feature is only available for sponsors

Coverage

Microsoft.IdentityModel.JsonWebTokens - 80.3%
Name Line Branch
Microsoft.IdentityModel.JsonWebTokens 80.3% 67.8%
Microsoft.IdentityModel.JsonWebTokens.JwtTokenUtilities 100%
System.Text.RegularExpressions.Generated 80.3% 67.8%
System.Text.RegularExpressions.Generated 80.3% 67.8%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F12A1AEDDDFE32BA
DF4DBFF323AF1BCB48B9F9721B7CD3E05F5E034CF225E3DF8__CreateJweRegex_1
79.2% 68%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F12A1AEDDDFE32BA
DF4DBFF323AF1BCB48B9F9721B7CD3E05F5E034CF225E3DF8__CreateJwsRegex_0
81.4% 67.6%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F334844C618E00D3
CEC5D3FE0D00CF0141BBEE98635313BB2CB8D3921464CE05A__CreateJweRegex_1
79.2% 68%
System.Text.RegularExpressions.Generated.<RegexGenerator_g>F334844C618E00D3
CEC5D3FE0D00CF0141BBEE98635313BB2CB8D3921464CE05A__CreateJwsRegex_0
81.4% 67.6%

@pmaytak pmaytak merged commit c8f7d87 into dev Aug 15, 2025
6 checks passed
This was referenced Aug 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants