microsoft / microsoft/component-detection

verification tests broken after charset-normalizer 3.4.4 published

Open
#1,473 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
553
Forks
135
Avg merge
20h 58m
Merged PRs (30d)
6

Description

The verification tests are broken again. It looks like it may be due to dependencies not being locked on purpose and then charset-normalizer being released 18 hours ago:

https://pypi.org/project/charset-normalizer/3.4.4/

@pauld-msft, this looks similar to
- https://github.com/microsoft/component-detection/pull/1381

```
Run dotnet test
Determining projects to restore...
Restored /home/runner/work/component-detection/component-detection/test/Microsoft.ComponentDetection.VerificationTests/Microsoft.ComponentDetection.VerificationTests.csproj (in 681 ms).
1 of 2 projects are up-to-date for restore.
MinVer: No commit found with a valid SemVer 2.0 version prefixed with 'v'. Using default version 0.0.0-preview.0.
MinVer: Using { Commit: ad17420, Tag: '', Version: 0.0.0-preview.0, Height: 0 }.
MinVer: Calculated version 0.0.0-preview.0.
Microsoft.ComponentDetection.Contracts -> /home/runner/work/component-detection/component-detection/src/Microsoft.ComponentDetection.Contracts/bin/Debug/netstandard2.0/Microsoft.ComponentDetection.Contracts.dll
MinVer: No commit found with a valid SemVer 2.0 version prefixed with 'v'. Using default version 0.0.0-preview.0.
MinVer: Using { Commit: ad17420, Tag: '', Version: 0.0.0-preview.0, Height: 0 }.
MinVer: Calculated version 0.0.0-preview.0.
Microsoft.ComponentDetection.VerificationTests -> /home/runner/work/component-detection/component-detection/test/Microsoft.ComponentDetection.VerificationTests/bin/net8.0/Microsoft.ComponentDetection.VerificationTests.dll
Test run for /home/runner/work/component-detection/component-detection/test/Microsoft.ComponentDetection.VerificationTests/bin/net8.0/Microsoft.ComponentDetection.VerificationTests.dll (.NETCoreApp,Version=v8.0)
VSTest version 17.11.1 (x64)

Starting test execution, please wait...
A total of 1 test files matched the specified pattern.
Failed CheckManifestFiles_ExcludingExperimentalDetectors [570 ms]
Error Message:
Expected foundComponent to be True because The component for PipReport-charset-normalizer 3.4.3 - pip was not present in the new manifest file. Verify this is expected behavior before proceeding, but found False.
Expected foundComponent to be True because The component for PipReport-charset-normalizer 3.4.4 - pip was not present in the old manifest file. Verify this is expected behavior before proceeding, but found False.
Expected rightDependencies {"charset-normalizer 3.4.4 - pip", "idna 3.11 - pip", "urllib3 2.5.0 - pip", "certifi 2025.10.5 - pip"} to contain "charset-normalizer 3.4.3 - pip" because Component dependency charset-normalizer 3.4.3 - pip for component [requests 2.32.5 - pip, System.Collections.Generic.HashSet`1[System.String]] was not in the new dependency graph..
Expected leftDependencies[0] to be "charset-normalizer 3.4.4 - pip" because new has the following components that were not found in old, please verify this is expected behavior. ["charset-normalizer 3.4.4 - pip"], but "charset-normalizer 3.4.3 - pip" differs near "3 -" (index 23).
Expected rightGraph.Graph.TryGetValue(leftComponent.Key, out var rightDependencies) to be True because Component [charset-normalizer 3.4.3 - pip, ] was in the old dependency graph, but is not in the new one., but found False.
Expected rightDependencies {"charset-normalizer 3.4.3 - pip", "idna 3.11 - pip", "urllib3 2.5.0 - pip", "certifi 2025.10.5 - pip"} to contain "charset-normalizer 3.4.4 - pip" because Component dependency charset-normalizer 3.4.4 - pip for component [requests 2.32.5 - pip, System.Collections.Generic.HashSet`1[System.String]] was not in the old dependency graph..
Expected leftDependencies[0] to be "charset-normalizer 3.4.3 - pip" because old has the following components that were not found in new, please verify this is expected behavior. ["charset-normalizer 3.4.3 - pip"], but "charset-normalizer 3.4.4 - pip" differs near "4 -" (index 23).
Expected rightGraph.Graph.TryGetValue(leftComponent.Key, out var rightDependencies) to be True because Component [charset-normalizer 3.4.4 - pip, ] was in the new dependency graph, but is not in the old one., but found False.

With configuration:
- Use declared types and members
- Compare enums by value
- Compare tuples by their properties
- Compare anonymous types by their properties
- Compare records by their members
- Include non-browsable members
- Include all non-private properties
- Include all non-private fields
- Match member by name (or throw)
- Be strict about the order of items in byte arrays
- Without automatic conversion.

Stack Trace:
at FluentAssertions.Execution.LateBoundTestFramework.Throw(String message)
at FluentAssertions.Execution.TestFrameworkProvider.Throw(String message)
at FluentAssertions.Execution.CollectingAssertionStrategy.ThrowIfAny(IDictionary`2 context)
at FluentAssertions.Execution.AssertionScope.Dispose()
at Microsoft.ComponentDetection.VerificationTests.ComponentDetectionIntegrationTests.CheckManifestFiles_ExcludingExperimentalDetectors() in /home/runner/work/component-detection/component-detection/test/Microsoft.ComponentDetection.VerificationTests/ComponentDetectionIntegrationTests.cs:line 70
at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
at System.Reflection.MethodBaseInvoker.InvokeWithNoArgs(Object obj, BindingFlags invokeAttr)

Failed! - Failed: 1, Passed: 5, Skipped: 0, Total: 6, Duration: 2 s - Microsoft.ComponentDetection.VerificationTests.dll (net8.0)
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run dotnet test and start at test/Microsoft.ComponentDetection.VerificationTests/ComponentDetectionIntegrationTests.cs:70, where CheckManifestFiles_ExcludingExperimentalDetectors fails. Compare the dependency transition shown in the failure with the approach in pull request 1381; done means the verification tests pass with the generated manifests and dependency graphs consistent.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, python
Domain
testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.