Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix assembly version diff test for missing file #44156

Merged
merged 1 commit into from
Oct 14, 2024
Merged

Conversation

mthalman
Copy link
Member

Fixes dotnet/source-build#4668

The source build assembly version diff test doesn't handle cases where the source built SDK contains files that do not exist in the Microsoft-built SDK. Some recent changes came in where this file diff was baselined (#43964). Two of the example files in this case are ./sdk/x.y.z/Microsoft.Bcl.AsyncInterfaces.dll and ./sdk/x.y.z/Microsoft.Bcl.Cryptography.dll.

The logic in the test will see that these files exist in the source built SDK and then try to find the matching file in the Microsoft SDK. When it can't find it, it causes an error. The Assert that is causing the error should be replaced with just a message that the file was not found. The rest of the logic gracefully handles it when no matching file exists.

@mthalman mthalman requested review from a team as code owners October 14, 2024 14:07
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-Infrastructure untriaged Request triage from a team member labels Oct 14, 2024
@mthalman mthalman merged commit e273411 into dotnet:main Oct 14, 2024
31 of 36 checks passed
@mthalman mthalman deleted the sb4668 branch October 14, 2024 15:57
@mthalman
Copy link
Member Author

/backport to release/9.0

Copy link
Contributor

Started backporting to release/9.0: https://github.com/dotnet/sdk/actions/runs/11441220450

Copy link
Contributor

@mthalman an error occurred while backporting to release/9.0, please check the run log for details!

Error: The specified backport target branch release/9.0 wasn't found in the repo.

@mthalman
Copy link
Member Author

/backport to release/8.0

Copy link
Contributor

Started backporting to release/8.0: https://github.com/dotnet/sdk/actions/runs/11441230615

@mthalman
Copy link
Member Author

/backport to release/9.0.1xx

@mthalman
Copy link
Member Author

/backport to release/8.0.1xx

Copy link
Contributor

Started backporting to release/9.0.1xx: https://github.com/dotnet/sdk/actions/runs/11441234346

Copy link
Contributor

@mthalman an error occurred while backporting to release/8.0, please check the run log for details!

Error: The specified backport target branch release/8.0 wasn't found in the repo.

Copy link
Contributor

Started backporting to release/8.0.1xx: https://github.com/dotnet/sdk/actions/runs/11441236828

Copy link
Contributor

@mthalman backporting to release/8.0.1xx failed, the patch most likely resulted in conflicts:

$ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patch

Applying: Fix assembly version diff test for missing file
Using index info to reconstruct a base tree...
A	src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/SdkContentTests.cs
Falling back to patching base and 3-way merge...
CONFLICT (modify/delete): src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/SdkContentTests.cs deleted in HEAD and modified in Fix assembly version diff test for missing file. Version Fix assembly version diff test for missing file of src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/SdkContentTests.cs left in tree.
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"
Patch failed at 0001 Fix assembly version diff test for missing file
Error: The process '/usr/bin/git' failed with exit code 128

Please backport manually!

Copy link
Contributor

@mthalman an error occurred while backporting to release/8.0.1xx, please check the run log for details!

Error: git am failed, most likely due to a merge conflict.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Infrastructure untriaged Request triage from a team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[main] SdkContentTests.CompareMsftToSbAssemblyVersions failed
2 participants