dependabot-core icon indicating copy to clipboard operation
dependabot-core copied to clipboard

Unhandled exception: No dotnet-tools.json files found

Open evgenyvalavin opened this issue 1 year ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Package ecosystem

NuGet

Dependabot

v0.244.0

What you expected to see, versus what you actually saw

No issue. Dependabot updates a NuGet

Stack trace

running NuGet updater:
/opt/nuget/NuGetUpdater/NuGetUpdater.Cli update --repo-root /home/dependabot/dependabot-updater/tmp/ProjectName/_git/ProjectName --solution-or-project /home/dependabot/dependabot-updater/tmp/ProjectName/_git/ProjectName /src/ProjectName.csproj --dependency Polly --new-version 8.3.0 --previous-version 8.2.0 --verbose
E, [2024-02-20T06:51:31.148672 #6] ERROR -- : Block argument of NuGetConfigCredentialHelpers::patch_nuget_config_for_action causes an exception No dotnet-tools.json files found.
Running for project [/home/dependabot/dependabot-updater/tmp/ProjectName/_git/ProjectName/src/ProjectName.csproj]
  Running for SDK-style project
Unhandled exception: System.IO.FileNotFoundException: Could not find file '/home/dependabot/dependabot-updater/tmp/ProjectName/_git/ProjectName/src/ProjectName.csproj.SdkResolver.-1682887324.proj'.
File name: '/home/dependabot/dependabot-updater/tmp/arbus/Waiter/_git/Waiter/src/Mobile/iOS/Waiter.iOS/Waiter.iOS.csproj.SdkResolver.1403365690.proj'
   at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirError)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, UnixFileMode openPermissions, Int64& fileLength, UnixFileMode& filePermissions, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
   at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.StreamReader.ValidateArgsAndOpenPath(String path, Encoding encoding, Int32 bufferSize)
   at System.IO.File.ReadAllText(String path, Encoding encoding)
   at NuGetUpdater.Core.ProjectBuildFile.Open(String repoRootPath, String path) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Files/ProjectBuildFile.cs:line 13
   at NuGetUpdater.Core.MSBuildHelper.<>c__DisplayClass19_0.<LoadBuildFiles>b__1(String path) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs:line 478
   at System.Linq.Enumerable.SelectArrayIterator`2.Fill(ReadOnlySpan`1 source, Span`1 destination, Func`2 func)
   at System.Linq.Enumerable.SelectArrayIterator`2.ToArray()
   at System.Collections.Immutable.ImmutableArray.CreateRange[T](IEnumerable`1 items)
   at NuGetUpdater.Core.MSBuildHelper.LoadBuildFiles(String repoRootPath, String projectPath) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Utilities/MSBuildHelper.cs:line 477
   at NuGetUpdater.Core.SdkPackageUpdater.UpdateDependencyAsync(String repoRootPath, String projectPath, String dependencyName, String previousDependencyVersion, String newDependencyVersion, Boolean isTransitive, Logger logger) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Updater/SdkPackageUpdater.cs:line 28
   at NuGetUpdater.Core.UpdaterWorker.RunForProjectAsync(String repoRootPath, String projectPath, String dependencyName, String previousDependencyVersion, String newDependencyVersion, Boolean isTransitive) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Updater/UpdaterWorker.cs:line 120
   at NuGetUpdater.Core.UpdaterWorker.RunAsync(String repoRootPath, String workspacePath, String dependencyName, String previousDependencyVersion, String newDependencyVersion, Boolean isTransitive) in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Core/Updater/UpdaterWorker.cs:line 44
   at NuGetUpdater.Cli.Commands.UpdateCommand.<>c__DisplayClass7_0.<<GetCommand>b__0>d.MoveNext() in /opt/nuget/lib/NuGetUpdater/NuGetUpdater.Cli/Commands/UpdateCommand.cs:line 37

My solution (projects) doesn't contain a dotnet-tools.json.

evgenyvalavin avatar Feb 20 '24 07:02 evgenyvalavin