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

[BUG] System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. #4078

Closed
3 of 4 tasks
Minosaff opened this issue Dec 24, 2024 · 1 comment

Comments

@Minosaff
Copy link

Minosaff commented Dec 24, 2024

Acknowledgement of preliminary instructions

  • I have read the preliminary instructions, and I am certain that my problem has not already been addressed.
  • I have thoroughly looked through the available Wiki articles and could not find a solution to my problem.
  • I am using the latest version of Bloxstrap.
  • I did not answer truthfully to all the above checkboxes.

Bloxstrap Version

v2.8.1

What problem did you encounter?

#[BUG] System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
2024-12-24

Bloxstrap Log

2024-12-24T03:45:10Z [App::OnStartup] Starting Bloxstrap v2.8.1
2024-12-24T03:45:10Z [App::OnStartup] Compiled Wednesday, 30 October 2024 at 6:35:23 AM from commit 2be2f4d0d275e60eabf2f63ecbbe4e38b2aa0773 (tag/v2.8.1)
2024-12-24T03:45:10Z [App::OnStartup] Loaded from %UserProfile%\AppData\Local\Bloxstrap\Bloxstrap.exe
2024-12-24T03:45:10Z [App::OnStartup] Temp path is %UserProfile%\AppData\Local\Temp\Bloxstrap
2024-12-24T03:45:10Z [App::OnStartup] WindowsStartMenu path is %UserProfile%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs
2024-12-24T03:45:11Z [LaunchSettings] Identifier 'uninstall' is active
2024-12-24T03:45:11Z [Logger::Initialize] Initializing at %UserProfile%\AppData\Local\Temp\Bloxstrap\Logs\Bloxstrap_20241224T034511Z.log
2024-12-24T03:45:11Z [Logger::Initialize] Finished initializing!
2024-12-24T03:45:11Z [JsonManager<Settings>::Load] Loading from %UserProfile%\AppData\Local\Bloxstrap\Settings.json...
2024-12-24T03:45:11Z [JsonManager<Settings>::Load] Failed to load!
2024-12-24T03:45:11Z [JsonManager<Settings>::Load] (0x80070002) System.IO.FileNotFoundException: Could not find file '%UserProfile%\AppData\Local\Bloxstrap\Settings.json'.
File name: '%UserProfile%\AppData\Local\Bloxstrap\Settings.json'
   at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
   at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
   at System.IO.Strategies.FileStreamHelpers.ChooseStrategyCore(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
   at System.IO.Strategies.FileStreamHelpers.ChooseStrategy(FileStream fileStream, String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, Int64 preallocationSize)
   at System.IO.StreamReader.ValidateArgsAndOpenPath(String path, Encoding encoding, Int32 bufferSize)
   at System.IO.File.InternalReadAllText(String path, Encoding encoding)
   at System.IO.File.ReadAllText(String path)
   at Bloxstrap.JsonManager`1.Load(Boolean alertFailure)
2024-12-24T03:45:11Z [Frontend::ShowMessageBox] Your Settings could not be loaded. They have been reset to the default configuration.

Could not find file '%UserProfile%\AppData\Local\Bloxstrap\Settings.json'.
2024-12-24T03:45:12Z [JsonManager<Settings>::Save] Saving to %UserProfile%\AppData\Local\Bloxstrap\Settings.json...
2024-12-24T03:45:12Z [App::GlobalExceptionHandler] An exception occurred
2024-12-24T03:45:12Z [App::FinalizeExceptionHandling] (0x80131604) System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
 ---> System.TypeInitializationException: The type initializer for 'System.Text.Encodings.Web.DefaultJavaScriptEncoder' threw an exception.
 ---> System.BadImageFormatException: Could not load file or assembly 'System.Numerics.Vectors, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Format of the executable (.exe) or library (.dll) is invalid.
File name: 'System.Numerics.Vectors, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
   at System.Text.Encodings.Web.AllowedBmpCodePointsBitmap.ForbidUndefinedCharacters()
   at System.Text.Encodings.Web.OptimizedInboxTextEncoder..ctor(ScalarEscaperBase scalarEscaper, AllowedBmpCodePointsBitmap& allowedCodePointsBmp, Boolean forbidHtmlSensitiveCharacters, ReadOnlySpan`1 extraCharactersToEscape)
   at System.Text.Encodings.Web.DefaultJavaScriptEncoder..ctor(TextEncoderSettings settings, Boolean allowMinimalJsonEscaping)
   at System.Text.Encodings.Web.DefaultJavaScriptEncoder..cctor()
   --- End of inner exception stack trace ---
   at System.Text.Encodings.Web.JavaScriptEncoder.get_Default()
   at System.Text.Json.JsonEncodedText.EncodeHelper(ReadOnlySpan`1 utf8Value, JavaScriptEncoder encoder)
   at System.Text.Json.JsonEncodedText.TranscodeAndEncode(ReadOnlySpan`1 value, JavaScriptEncoder encoder)
   at System.Text.Json.Serialization.Converters.EnumConverter`1..ctor(EnumConverterOptions converterOptions, JsonNamingPolicy namingPolicy, JsonSerializerOptions serializerOptions)
   at System.Text.Json.Serialization.Converters.EnumConverter`1..ctor(EnumConverterOptions converterOptions, JsonSerializerOptions serializerOptions)
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
   at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture)
   at System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
   at System.Activator.CreateInstance(Type type, Object[] args)
   at System.Text.Json.Serialization.Converters.EnumConverterFactory.Create(Type enumType, EnumConverterOptions converterOptions, JsonSerializerOptions serializerOptions)
   at System.Text.Json.Serialization.Converters.EnumConverterFactory.CreateConverter(Type type, JsonSerializerOptions options)
   at System.Text.Json.Serialization.JsonConverterFactory.GetConverterInternal(Type typeToConvert, JsonSerializerOptions options)
   at System.Text.Json.JsonSerializerOptions.GetConverterInternal(Type typeToConvert)
   at System.Text.Json.JsonSerializerOptions.DetermineConverter(Type parentClassType, Type runtimePropertyType, MemberInfo memberInfo)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo.GetConverter(Type type, Type parentClassType, MemberInfo memberInfo, Type& runtimeType, JsonSerializerOptions options)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo.AddProperty(MemberInfo memberInfo, Type memberType, Type parentClassType, Boolean isVirtual, Nullable`1 parentTypeNumberHandling, JsonSerializerOptions options)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo.CacheMember(Type declaringType, Type memberType, MemberInfo memberInfo, Boolean isVirtual, Nullable`1 typeNumberHandling, Boolean& propertyOrderSpecified, Dictionary`2& ignoredMembers)
   at System.Text.Json.Serialization.Metadata.JsonTypeInfo..ctor(Type type, JsonConverter converter, Type runtimeType, JsonSerializerOptions options)
   at System.Text.Json.JsonSerializerOptions.<InitializeForReflectionSerializer>g__CreateJsonTypeInfo|112_0(Type type, JsonSerializerOptions options)
   at System.Text.Json.JsonSerializerOptions.GetClassFromContextOrCreate(Type type)
   at System.Text.Json.JsonSerializerOptions.GetOrAddClass(Type type)
   at System.Text.Json.JsonSerializer.GetTypeInfo(JsonSerializerOptions options, Type runtimeType)
   at System.Text.Json.JsonSerializer.Serialize[TValue](TValue value, JsonSerializerOptions options)
   at Bloxstrap.JsonManager`1.Save()
   at Bloxstrap.JsonManager`1.Load(Boolean alertFailure)
   at Bloxstrap.App.OnStartup(StartupEventArgs e)
   at System.Windows.Application.<.ctor>b__1_0(Object unused)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
2024-12-24T03:45:12Z [HttpClientLoggingHandler::ProcessRequest] POST https://bloxstraplabs.com/metrics/post-exception
2024-12-24T03:45:13Z [HttpClientLoggingHandler::ProcessResponse] 429 Too Many Requests https://bloxstraplabs.com/metrics/post-exception
@bluepilledgreat
Copy link
Member

reinstall .net 6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants