Unable to run the tool in the 2.1.0 version
See original GitHub issueI’ve been using version 2.0.1 without any problem, but with the latest one, 2.1.0 I started to get this error
Command ran
dotnet-CycloneDX -dgl ProjectName.csproj -o .
Error
Unhandled exception. System.Collections.Generic.KeyNotFoundException: The given key 'refit' was not present in the dictionary.
at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
at CycloneDX.Program.OnExecuteAsync() in /home/runner/work/cyclonedx-dotnet/cyclonedx-dotnet/CycloneDX/Program.cs:line 275
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.InvokeAsync(MethodInfo method, Object instance, Object[] arguments)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.OnExecute(ConventionContext context, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.<>c__DisplayClass0_0.<<Apply>b__0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.ExecuteAsync(String[] args, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.ExecuteAsync[TApp](CommandLineContext context, CancellationToken cancellationToken)
at CycloneDX.Program.Main(String[] args) in /home/runner/work/cyclonedx-dotnet/cyclonedx-dotnet/CycloneDX/Program.cs:line 109
at CycloneDX.Program.<Main>(String[] args)
Full log (click to expand)
dotnet-CycloneDX -dgl ProjectName.csproj -o .
Found the following local nuget package cache locations:
/tmp/SustentacaoWebApi/.nuget/packages/
» Analyzing: /home/jenkins/agent/workspace/src/ProjectName.csproj
Attempting to restore packages
Retrieving AspNetCore.HealthChecks.Rabbitmq 3.0.7
Retrieving AutoMapper 9.0.0
Retrieving AutoMapper.Extensions.Microsoft.DependencyInjection 7.0.0
Retrieving Dapper 2.0.30
Retrieving EntityFramework 6.4.0
Retrieving Microsoft.AspNetCore.Authentication.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Authentication.Core 2.2.0
Retrieving Microsoft.AspNetCore.Authentication.JwtBearer 3.0.0
Retrieving Microsoft.AspNetCore.Authorization 2.2.0
Retrieving Microsoft.AspNetCore.Authorization.Policy 2.2.0
Retrieving Microsoft.AspNetCore.HeaderPropagation 3.1.0
Retrieving Microsoft.AspNetCore.Hosting.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Hosting.Server.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Http 2.2.0
Retrieving Microsoft.AspNetCore.Http.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Http.Extensions 2.2.0
Retrieving Microsoft.AspNetCore.Http.Features 2.2.0
Retrieving Microsoft.AspNetCore.JsonPatch 3.0.0-preview3-19153-02
Retrieving Microsoft.AspNetCore.Mvc.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Mvc.Core 2.2.5
Retrieving Microsoft.AspNetCore.Mvc.NewtonsoftJson 3.0.0-preview3-19153-02
Retrieving Microsoft.AspNetCore.ResponseCaching.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.Routing 2.2.0
Retrieving Microsoft.AspNetCore.Routing.Abstractions 2.2.0
Retrieving Microsoft.AspNetCore.WebUtilities 2.2.0
Retrieving Microsoft.Avro.Core 0.1.0
Retrieving Microsoft.Bcl.AsyncInterfaces 1.1.0
Retrieving Microsoft.Bcl.HashCode 1.1.0
Retrieving Microsoft.CSharp 4.7.0
Retrieving Microsoft.Data.SqlClient 1.0.19269.1
Retrieving Microsoft.DotNet.PlatformAbstractions 2.1.0
Retrieving Microsoft.EntityFrameworkCore 3.1.2
Retrieving Microsoft.EntityFrameworkCore.Abstractions 3.1.2
Retrieving Microsoft.EntityFrameworkCore.Analyzers 3.1.2
Retrieving Microsoft.EntityFrameworkCore.Relational 3.1.2
Retrieving Microsoft.EntityFrameworkCore.SqlServer 3.1.2
Retrieving Microsoft.Extensions.ApiDescription.Server 3.0.0
Retrieving Microsoft.Extensions.Caching.Abstractions 3.1.2
Retrieving Microsoft.Extensions.Caching.Memory 3.1.2
Retrieving Microsoft.Extensions.Configuration 3.1.3
Retrieving Microsoft.Extensions.Configuration.Abstractions 3.1.3
Retrieving Microsoft.Extensions.Configuration.Binder 3.1.3
Retrieving Microsoft.Extensions.Configuration.CommandLine 3.1.3
Retrieving Microsoft.Extensions.Configuration.EnvironmentVariables 3.1.3
Retrieving Microsoft.Extensions.Configuration.FileExtensions 3.1.3
Retrieving Microsoft.Extensions.Configuration.Json 3.1.3
Retrieving Microsoft.Extensions.Configuration.UserSecrets 3.1.3
Retrieving Microsoft.Extensions.DependencyInjection 3.1.3
Retrieving Microsoft.Extensions.DependencyInjection.Abstractions 3.1.3
Retrieving Microsoft.Extensions.DependencyModel 2.1.0
Retrieving Microsoft.Extensions.Diagnostics.HealthChecks 3.0.0
Retrieving Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions 3.0.0
Retrieving Microsoft.Extensions.FileProviders.Abstractions 3.1.3
Retrieving Microsoft.Extensions.FileProviders.Physical 3.1.3
Retrieving Microsoft.Extensions.FileSystemGlobbing 3.1.3
Retrieving Microsoft.Extensions.Hosting 3.1.3
Retrieving Microsoft.Extensions.Hosting.Abstractions 3.1.3
Retrieving Microsoft.Extensions.Http 3.1.0
Retrieving Microsoft.Extensions.Logging 3.1.3
Retrieving Microsoft.Extensions.Logging.Abstractions 3.1.3
Retrieving Microsoft.Extensions.Logging.Configuration 3.1.3
Retrieving Microsoft.Extensions.Logging.Console 3.1.3
Retrieving Microsoft.Extensions.Logging.Debug 3.1.3
Retrieving Microsoft.Extensions.Logging.EventLog 3.1.3
Retrieving Microsoft.Extensions.Logging.EventSource 3.1.3
Retrieving Microsoft.Extensions.ObjectPool 2.2.0
Retrieving Microsoft.Extensions.Options 3.1.3
Retrieving Microsoft.Extensions.Options.ConfigurationExtensions 3.1.3
Retrieving Microsoft.Extensions.Primitives 3.1.3
Retrieving Microsoft.Identity.Client 3.0.8
Retrieving Microsoft.IdentityModel.JsonWebTokens 5.5.0
Retrieving Microsoft.IdentityModel.Logging 5.5.0
Retrieving Microsoft.IdentityModel.Protocols 5.5.0
Retrieving Microsoft.IdentityModel.Protocols.OpenIdConnect 5.5.0
Retrieving Microsoft.IdentityModel.Tokens 5.5.0
Retrieving Microsoft.Net.Http.Headers 2.2.0
Retrieving Microsoft.NETCore.Platforms 3.1.0
Retrieving Microsoft.NETCore.Targets 1.1.0
Retrieving Microsoft.OpenApi 1.1.1
Retrieving Microsoft.Win32.Registry 4.7.0
Retrieving Microsoft.Win32.SystemEvents 4.7.0
Retrieving Newtonsoft.Json 12.0.3
Retrieving Newtonsoft.Json.Bson 1.0.2
Retrieving NLog 4.7.2
Retrieving NLog.Extensions.Logging 1.6.2
Retrieving NLog.Web.AspNetCore 4.9.2
Retrieving Novell.Directory.Ldap.NETStandard 3.0.1
Retrieving Pipelines.Sockets.Unofficial 2.1.6
Retrieving Polly 7.2.0
Retrieving RabbitMQ.Client 5.1.2
Retrieving Refit 4.7.9
Retrieving Refit.HttpClientFactory 4.7.9
Retrieving runtime.native.System 4.3.0
Retrieving runtime.native.System.Data.SqlClient.sni 4.7.0
Retrieving runtime.win-arm64.runtime.native.System.Data.SqlClient.sni 4.4.0
Retrieving runtime.win-x64.runtime.native.System.Data.SqlClient.sni 4.4.0
Retrieving runtime.win-x86.runtime.native.System.Data.SqlClient.sni 4.4.0
Retrieving Scrutor 3.0.2
Retrieving StackExchange.Redis 2.1.30
Retrieving Swashbuckle.AspNetCore 5.0.0-rc4
Retrieving Swashbuckle.AspNetCore.Swagger 5.0.0-rc4
Retrieving Swashbuckle.AspNetCore.SwaggerGen 5.0.0-rc4
Retrieving Swashbuckle.AspNetCore.SwaggerUI 5.0.0-rc4
Retrieving System.AppContext 4.1.0
Retrieving System.Buffers 4.5.0
Retrieving System.CodeDom 4.7.0
Retrieving System.Collections 4.3.0
Retrieving System.Collections.Concurrent 4.3.0
Retrieving System.Collections.Immutable 1.7.0
Retrieving System.Collections.NonGeneric 4.3.0
Retrieving System.Collections.Specialized 4.3.0
Retrieving System.ComponentModel 4.3.0
Retrieving System.ComponentModel.Annotations 4.7.0
Retrieving System.ComponentModel.Primitives 4.3.0
Retrieving System.ComponentModel.TypeConverter 4.3.0
Retrieving System.Configuration.ConfigurationManager 4.7.0
Retrieving System.Data.SqlClient 4.8.0
Retrieving System.Diagnostics.Debug 4.3.0
Retrieving System.Diagnostics.DiagnosticSource 4.7.0
Retrieving System.Diagnostics.EventLog 4.7.0
Retrieving System.Diagnostics.PerformanceCounter 4.7.0
Retrieving System.Diagnostics.Tools 4.3.0
Retrieving System.Diagnostics.Tracing 4.3.0
Retrieving System.Drawing.Common 4.7.0
Retrieving System.Dynamic.Runtime 4.0.11
Retrieving System.Globalization 4.3.0
Retrieving System.Globalization.Extensions 4.3.0
Retrieving System.IdentityModel.Tokens.Jwt 5.5.0
Retrieving System.IO 4.3.0
Retrieving System.IO.FileSystem 4.3.0
Retrieving System.IO.FileSystem.Primitives 4.3.0
Retrieving System.IO.Pipelines 4.7.0
Retrieving System.Linq 4.3.0
Retrieving System.Linq.Expressions 4.1.0
Retrieving System.Net.NameResolution 4.3.0
Retrieving System.Net.Primitives 4.3.0
Retrieving System.ObjectModel 4.0.12
Retrieving System.Private.DataContractSerialization 4.3.0
Retrieving System.Private.ServiceModel 4.7.0
Retrieving System.Reflection 4.3.0
Retrieving System.Reflection.DispatchProxy 4.5.0
Retrieving System.Reflection.Emit 4.3.0
Retrieving System.Reflection.Emit.ILGeneration 4.3.0
Retrieving System.Reflection.Emit.Lightweight 4.6.0
Retrieving System.Reflection.Extensions 4.3.0
Retrieving System.Reflection.Primitives 4.3.0
Retrieving System.Reflection.TypeExtensions 4.3.0
Retrieving System.Resources.ResourceManager 4.3.0
Retrieving System.Runtime 4.3.0
Retrieving System.Runtime.Caching 4.5.0
Retrieving System.Runtime.CompilerServices.Unsafe 4.7.0
Retrieving System.Runtime.Extensions 4.3.0
Retrieving System.Runtime.Handles 4.3.0
Retrieving System.Runtime.InteropServices 4.3.0
Retrieving System.Runtime.InteropServices.RuntimeInformation 4.0.0
Retrieving System.Runtime.Serialization.Formatters 4.3.0
Retrieving System.Runtime.Serialization.Json 4.3.0
Retrieving System.Runtime.Serialization.Primitives 4.3.0
Retrieving System.Security.AccessControl 4.7.0
Retrieving System.Security.Cryptography.Cng 4.5.0
Retrieving System.Security.Cryptography.Pkcs 4.5.0
Retrieving System.Security.Cryptography.Primitives 4.3.0
Retrieving System.Security.Cryptography.ProtectedData 4.7.0
Retrieving System.Security.Cryptography.Xml 4.5.0
Retrieving System.Security.Permissions 4.7.0
Retrieving System.Security.Principal.Windows 4.7.0
Retrieving System.Security.SecureString 4.3.0
Retrieving System.ServiceModel.Duplex 4.7.0
Retrieving System.ServiceModel.Http 4.7.0
Retrieving System.ServiceModel.NetTcp 4.7.0
Retrieving System.ServiceModel.Primitives 4.7.0
Retrieving System.ServiceModel.Security 4.7.0
Retrieving System.Text.Encoding 4.3.0
Retrieving System.Text.Encoding.CodePages 4.5.0
Retrieving System.Text.Encoding.Extensions 4.3.0
Retrieving System.Text.Encodings.Web 4.5.0
Retrieving System.Text.RegularExpressions 4.3.0
Retrieving System.Threading 4.3.0
Retrieving System.Threading.Channels 4.7.0
Retrieving System.Threading.Tasks 4.3.0
Retrieving System.Threading.Tasks.Extensions 4.5.1
Retrieving System.Windows.Extensions 4.7.0
Retrieving System.Xml.ReaderWriter 4.3.0
Retrieving System.Xml.XDocument 4.3.0
Retrieving System.Xml.XmlDocument 4.3.0
Retrieving System.Xml.XmlSerializer 4.3.0
Unhandled exception. System.Collections.Generic.KeyNotFoundException: The given key 'refit' was not present in the dictionary.
at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
at CycloneDX.Program.OnExecuteAsync() in /home/runner/work/cyclonedx-dotnet/cyclonedx-dotnet/CycloneDX/Program.cs:line 275
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.InvokeAsync(MethodInfo method, Object instance, Object[] arguments)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.OnExecute(ConventionContext context, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.Conventions.ExecuteMethodConvention.<>c__DisplayClass0_0.<<Apply>b__0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.ExecuteAsync(String[] args, CancellationToken cancellationToken)
at McMaster.Extensions.CommandLineUtils.CommandLineApplication.ExecuteAsync[TApp](CommandLineContext context, CancellationToken cancellationToken)
at CycloneDX.Program.Main(String[] args) in /home/runner/work/cyclonedx-dotnet/cyclonedx-dotnet/CycloneDX/Program.cs:line 109
at CycloneDX.Program.<Main>(String[] args)
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
NETSDK1045: The current .NET SDK does not support ...
This error occurs when the build tools can't find the version of the .NET SDK that's needed to build a project. This is...
Read more >Version for package `Microsoft.EntityFrameworkCore.Tools ...
I'm trying to run the EntityFramework migration, as the project was created using the "code-first" method. The command to be run is. dotnet...
Read more >Unable To Run Graphical Tools (GUI) (runInstaller, DBCA ...
On Exadata database servers updated or imaged from releases 12.1.2.1.0 it's not possible to start any Oracle GUI utility depending on graphical packages....
Read more >Version 2.1.0
Version 2.1.0. This update adds fast AI denoising, cutting render times by up to 99%. Also included are improvements to the animation and ......
Read more >Docs: Troubleshooting
My pipeline crashes part way through a run at a certain step with a non 0 exit code. Sometimes part way through a...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks heaps! Not only reporting the issue, but diagnosing the cause, and creating a fix. The fix has been included in v2.1.1 which should be available soon.
I leave a comment in other issue https://github.com/CycloneDX/cyclonedx-dotnet/issues/436
it was exact the same exception that i got