Skip to content

[Mono.Android] Deprecate removed constructors - #12311

Open
jonathanpeppers wants to merge 1 commit into
dotnet:mainfrom
jonathanpeppers:jonathanpeppers-obsolete-removed-android-apis
Open

[Mono.Android] Deprecate removed constructors#12311
jonathanpeppers wants to merge 1 commit into
dotnet:mainfrom
jonathanpeppers:jonathanpeppers-obsolete-removed-android-apis

Conversation

@jonathanpeppers

Copy link
Copy Markdown
Member

Mark the 11 bound constructors that Android removed before the current minimum supported API level as obsolete.

The current API profile was rescanned through API level 24; no additional public or protected constructors require this treatment.

Closes #5172

Copilot AI review requested due to automatic review settings August 7, 2026 17:31

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Marks a set of bound Java constructors (that no longer exist on supported Android API levels) as deprecated via src/Mono.Android/metadata, so consumers get compile-time guidance instead of NoSuchMethodError at runtime.

Changes:

  • Added metadata <attr ... name="deprecated">...</attr> entries to obsolete removed parameterless constructors across several Android namespaces.
  • Documented the rationale in the metadata file near the existing “Google API breakage” section.

Comment thread src/Mono.Android/metadata Outdated
Comment thread src/Mono.Android/metadata Outdated
@jonathanpeppers
jonathanpeppers force-pushed the jonathanpeppers-obsolete-removed-android-apis branch 2 times, most recently from 7fdffd8 to 5433f56 Compare August 7, 2026 17:51
Mark 15 public constructors removed before the minimum supported Android API level as obsolete through binding metadata, including WebKit constructors whose containing types were removed and therefore lack removed-since annotations.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: bded62c4-4507-4f48-a38a-c4162b9d28a0
@jonathanpeppers
jonathanpeppers force-pushed the jonathanpeppers-obsolete-removed-android-apis branch from 5433f56 to 69502b2 Compare August 7, 2026 17:51
@jonathanpeppers jonathanpeppers added the ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable). label Aug 7, 2026
@jonathanpeppers
jonathanpeppers enabled auto-merge (squash) August 7, 2026 21:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Mono.Android] Bound constructors no longer exist in Android

2 participants