Mapbox-java incompatible with gson 2.13.0 and up - call to internal GSON classes that were renamed
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Java
- Star
- 438
- Fork
- 117
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
Attempted upgrading GSON (for internal app use and third-party integration requiring a newer version), but encountered issues with mapbox-java. R8 began reporting missing classes due to the following reference:
The root cause is the renaming of internal classes in GSON version 2.13.0:
The internal classes $Gson$Types and $Gson$Preconditions have been renamed to remove the $ characters. Since these are internal classes (as signaled not only by the package name but by the $ characters), client code should not be affected. If your code was depending on these classes then we suggest making a copy of the class (subject to the license) rather than depending on the new names.
r8 error:
ERROR: Missing classes detected while running R8. Please add the missing classes or apply additional keep rules that are generated in REDACTED/missing_rules.txt.
ERROR: R8: Missing class com.google.gson.internal.$Gson$Types (referenced from: com.google.gson.TypeAdapter com.mapbox.api.geocoding.v5.SingleElementSafeListTypeAdapter$1.create(com.google.gson.Gson, com.google.gson.reflect.TypeToken))
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.
Hướng nghiên cứu
Bắt đầu với import được tham chiếu trong services-geocoding/src/main/java/com/mapbox/api/geocoding/v5/SingleElementSafeListTypeAdapter.java và so sánh cách sử dụng GSON của nó với ghi chú phát hành GSON 2.13.0. Tái hiện lỗi thiếu lớp của R8 với GSON 2.13.0 hoặc mới hơn, sau đó xác minh rằng dịch vụ geocoding được build mà không có lỗi đó.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- java
- Lĩnh vực
- mobile-dev
- Loại issue
- Lỗi
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức phù hợp với người mới
- 48/100