Skip to content

No longer seeing InvalidOperationExceptions with certain Assembly.ReflectionOnlyLoad usage #7091

Closed

Description

@pjcollins

Android application type

Classic Xamarin.Android (MonoAndroid12.0, etc.)

Affected platform version

VS 17.3

Description

Commit e1af958 seems to have somehow affected Assembly.ReflectionOnlyLoad related API usage. We're seeing four new BCL test failures that are related:
https://devdiv.visualstudio.com/DevDiv/_build/results?buildId=6270744&view=ms.vss-test-web.build-test-results-tab

For some reason, this API usage is no longer throwing -- we don't seem hit some of these expected code paths:

https://github.com/mono/mono/blob/5d2e3bc3b3c8184d35b2f7801e88d96470d367c4/mcs/class/corlib/System.Reflection/Assembly.cs#L556
https://github.com/mono/mono/blob/5d2e3bc3b3c8184d35b2f7801e88d96470d367c4/mono/metadata/icall.c#L2089

Steps to Reproduce

Use some Assembly.ReflectionOnlyLoad related reflection, example:

These no longer throw an InvalidOperationExceptions as expected.

Did you find any workaround?

No response

Relevant log output

No response

Activity

  1. ghost locked as resolved and limited conversation to collaborators on Jul 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Area: App RuntimeIssues in `libmonodroid.so`.needs-triageIssues that need to be assigned.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions