Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

MAUI Android publish fails: missing System.Activator.CreateDefaultInstance

Đang mở
#12,921 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Sôi nổi
Công nghệ
android, csharp
Lĩnh vực
build-system, ci-cd, mobile

Hướng nghiên cứu

Start by reproducing the publish failure from MauiAndroidDefault.csproj with UseMonoRuntime=true and compare it with the passing Default CoreCLR jobs. Inspect the failure around ILCompiler.ReadyToRunCodegenCompilation and the missing System.Activator.CreateDefaultInstance method; done means the configured Mono performance scenario publishes successfully without NETSDK1096.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

needs-triage
Description

MAUI Android performance CI jobs fail when publishing MauiAndroidDefault.csproj with UseMonoRuntime=true.

Error
Unhandled exception. System.InvalidOperationException:
Expected method 'CreateDefaultInstance' not found on type
'[S.P.CoreLib]System.Activator'

error NETSDK1096: Optimizing assemblies for performance failed.

The stack trace includes ILCompiler.ReadyToRunCodegenCompilation (which is weird for Mono...)

Environment
Component Version
Build host Windows 22H2, x64
Target net11.0-android, android-arm64, Release
.NET SDK 11.0.100-rtm.26473.115
Android workload 37.99.0-preview.1.30
MAUI workload 11.0.0-rc.2.26474.8
dotnet/performance commit 1f0e0f68889a0996f30e265846446549a801800e
Expected and actual behavior

Expected: The configured Mono performance scenario publishes successfully.

Actual: Crossgen throws the exception above, and publish fails with NETSDK1096. The underlying cause is not yet confirmed.

CI evidence

The corresponding Default CoreCLR jobs pass in both builds. CI links require internal Azure DevOps access.

Ngôn ngữ chính
C#
Star
2.1k
Fork
580
Merge trung bình
1 ngày 22 giờ
Pull request đã merge (30 ngày)
215

Chuẩn bị môi trường

Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. Hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của dotnet/android

Tất cả issue của dotnet/android

Issue tương tự

Thêm issue về C#

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.