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

Reorg: Unhandled NotImplementedException with mono 5.2.0 and unity 2017 #160

Open
kohanis opened this issue Jan 9, 2024 · 4 comments
Open
Labels

Comments

@kohanis
Copy link

kohanis commented Jan 9, 2024

Description

Unhandled NotImplementedException from AppContext.GetData in MonoMod.Switches.TryGetSwitchEnabled of MonoMod.Utils with mono 5.2.0 and unity 2017 mono

@nike4613
Copy link
Contributor

Do those builds of Mono target .NET Framework 4.6+?

@kohanis
Copy link
Author

kohanis commented Jan 10, 2024

That's the neat part - mono 5.2.0 targets 4.7) But AppContext.GetData is just

public static object GetData(string name)
{
	throw new NotImplementedException();
}

Unity 2017 mono is targeting 4.6 because it's technically mono 5.0.1, but it has commits between 5.0.1 and 5.2.0 as far as I can tell

@nike4613
Copy link
Contributor

Is it only GetData? Is TryGetSwitch present and implemented?

@kohanis
Copy link
Author

kohanis commented Jan 10, 2024

Yes. Also, as alternative AppDomain.CurrentDomain.GetData could be used if AppContext.GetData is not present, on frameworks it's literally reroute, idk why mono left NotImplementedException

nike4613 added a commit that referenced this issue Jan 10, 2024
… when it always throws (such as in old Mono)

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

No branches or pull requests

2 participants