Migrate to new AGP DSL and remove android.newDsl=false opt-out
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
- 55/100
- Loại issue
- Tái cấu trúc
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- android, kotlin
- Lĩnh vực
- build-system, mobile
Hướng nghiên cứu
Bắt đầu với tệp root build.gradle.kts quanh các dòng 174-180 và kiểm tra cấu hình module thư viện bằng BaseExtension. Sau đó, xem lại sentry-samples/sentry-samples-android/build.gradle.kts để tìm import nội bộ VariantImpl, xóa android.newDsl=false khỏi gradle.properties và xác nhận rằng build thành công với AGP DSL mới.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Follow-up to the AGP 8.13.1 → 9.2.1 bump (getsentry/sentry-java#5777). To land AGP 9 without a large refactor, the bump added a temporary opt-out in gradle.properties:
# AGP 9+ migration opt-outs until we remove kotlin-android plugin and adopt built-in Kotlin.
android.newDsl=false
Why this matters: android.newDsl=false opts out of AGP 9's new DSL. If Google removes this flag in a future AGP release, we will be unable to upgrade until the migration is done.
Current state:
- The root
build.gradle.kts(around lines 174-180) still configures library modules via the legacycom.android.build.gradle.BaseExtensioninsideplugins.withId("com.android.library") { ... }. This is what depends on the old DSL. - Runtime modules already use the new
androidComponentsVariant API (beforeVariants/onVariants); the oldlibraryVariants/applicationVariants/BaseVariantAPI is not used anywhere. Good starting position. - Fragility to address:
sentry-samples/sentry-samples-android/build.gradle.ktsimports the internalcom.android.build.api.variant.impl.VariantImpl(a non-stable.impl.class), a likely future break point.
Scope:
- Replace the
BaseExtension-based configuration in the root build with the new DSL. - Remove the internal
VariantImplusage in the Android sample. - Remove
android.newDsl=falsefromgradle.propertiesand confirm the build passes.
Done when: android.newDsl=false is removed and the build works on the new AGP DSL.
Should be picked up after the AGP bump PRs merge.
- Ngôn ngữ chính
- Kotlin
- Star
- 1.4k
- Fork
- 478
- Merge trung bình
- 2 ngày 20 giờ
- Pull request đã merge (30 ngày)
- 70
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của getsentry/sentry-java
-
Platform: Java
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 76/100
getsentry/sentry-java#6161 · 1 bình luận ·
-
Improvement Java Platform: Android Platform: Java
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
getsentry/sentry-java#6145 · 1 bình luận · 1 người được giao ·
-
Bug Java Platform: Android Platform: Java
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
getsentry/sentry-java#6138 · 1 bình luận ·
-
Feature Java Platform: Java Spans
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
getsentry/sentry-java#5984 · 1 bình luận ·
-
Android Task Traces
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
getsentry/sentry-java#5376 · 1 bình luận ·
Tất cả issue của getsentry/sentry-java
Issue tương tự
-
Flaky: a relaunched catch-up replay can still report catching up right after its marker is written Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
johanhaleby/occurrent#1134 ·
-
autoteam community team/use
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
-
android: AlbumArtistDetailViewModel keeps groupKeys of albums that disappeared in expandedAlbums Đang mởtask
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 90/100
aaif-goose/goose#12496 ·
-
Schema rejections are neither logged nor attributed, so the offending object cannot be identified Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
zotero/zotero-android#350 ·