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

MissingMethodException on non-generic ASF #27

Closed
Citrinate opened this issue Mar 9, 2024 · 2 comments
Closed

MissingMethodException on non-generic ASF #27

Citrinate opened this issue Mar 9, 2024 · 2 comments

Comments

@Citrinate
Copy link
Owner

After a few seconds, plugin crashes ASF on latest version (6.0.0.3) when using a non-generic version of ASF

2024-03-09 11:41:47|ArchiSteamFarm-592|FATAL|ASF|OnUnhandledException() System.MissingMethodException: Attempted to access a missing method.
   at FreePackages.WebRequest.GetAppDetails(Bot bot, UInt32 appID)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine&)
   at FreePackages.WebRequest.GetAppDetails(Bot bot, UInt32 appID)
   at FreePackages.PackageQueue.ClaimFreeApp(UInt32 appID)
   at FreePackages.PackageQueue.ClaimPackage(Package package)
   at FreePackages.PackageQueue.ProcessQueue()
   at FreePackages.PackageQueue.<.ctor>b__8_0(Object e)
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_1(Object state)
   at System.Threading.QueueUserWorkItemCallbackDefaultContext.Execute()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
   at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
   at System.Threading.Thread.StartCallback()

Originally posted by @SpoogLord in #25 (comment)

@JustArchi
Copy link

Might be because you're trying to deserialize into JsonObject. You can try deserializing into JsonElement instead if you need dynamic access, or to a class if possible.

@JustArchi
Copy link

Looking at the above a bit more, you should be able to safely deserialize into Dictionary<uint, AppDetails> instead of dynamically.

Citrinate added a commit that referenced this issue Mar 10, 2024
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