-
Notifications
You must be signed in to change notification settings - Fork 1k
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
feature-intern-ResolveDependencyConflictsNew to main #10343
feature-intern-ResolveDependencyConflictsNew to main #10343
Conversation
f689e8f
to
437c713
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is amazing to see!
I know your last day is tomorrow, so no pressure to resolve any of these comments, I just wanted to provide some feedback!
Thanks for all of your hard work this summer!
@@ -14,7 +14,7 @@ concurrency: | |||
|
|||
env: | |||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |||
SMOKE_TEST_BRANCH: main | |||
SMOKE_TEST_BRANCH: feature-DependencySolver |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
q: was this change meant to be checked in?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We added a smoke test, this was just to make sure it was green in CI. The commit that added this will be removed prior to merging.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We just revert back this change because we are getting error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Cli.Test/EntryPointTests.Update.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core.Test/Update/UpdateWorkerTests.Sdk.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core.Test/Update/UpdateWorkerTests.Sdk.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core.Test/Utilities/MSBuildHelperTests.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Updater/SdkPackageUpdater.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Updater/SdkPackageUpdater.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Updater/SdkPackageUpdater.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/DependencyConflictResolver.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/DependencyConflictResolver.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Updater/SdkPackageUpdater.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/DependencyConflictResolver.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/DependencyConflictResolver.cs
Outdated
Show resolved
Hide resolved
nuget/helpers/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs
Outdated
Show resolved
Hide resolved
0a45eb8
to
cfee286
Compare
@@ -493,6 +497,786 @@ public async Task DependencyConflictsCanBeResolved() | |||
} | |||
} | |||
|
|||
#region |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: It's generally good to name regions so that people know what's inside if they're collapsed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do these in follow up PR
int dependencyIndex = Array.FindIndex(updatedTopLevelDependencies, d => string.Equals(d.Name, dependencyName, StringComparison.OrdinalIgnoreCase)); | ||
if (dependencyIndex != -1) | ||
{ | ||
var originalDependency = updatedTopLevelDependencies[dependencyIndex]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to preserve this modified dependency somewhere?
} | ||
|
||
// Method alterted from VersionFinder.cs to find the metadata of a given package | ||
private async Task<IPackageSearchMetadata?> FindPackageMetadataAsync(PackageIdentity packageIdentity, CancellationToken cancellationToken) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: Generally private methods go under public methods so it's easier to find the "entry-points".
f411b68
to
144fc23
Compare
My code is currently behind an environment variable not yet set. Will work with @brettfo to put this behind the experiment flag.
Looking for feedback on implementation, unit tests, variable names, etc.
DependencyConflictResolver.cs is the main code.
MSBuildHelper.cs and MSBuildHelperTests.cs were used for tests
UpdateWorkerTests.Sdk.cs was lightly used with testing with Brett
Added temporary commit to make smoke tests pass.
Smoke Test PR:
dependabot/smoke-tests#219
This is the PR that adds the experiment:
https://github.com/github/dependabot-api/pull/5511