Attribution sheet intermittently lists no attributions (Standard style, 11.26.0)
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
- 28/100
Hướng nghiên cứu
Start from MapboxMap.loadAttributions and Attribution.parse(__map.getAttributions()); the failing path is that getAttributions() returns nothing after the Standard style loads, so trace where style and source attributions are registered. The report gives no minimal repro, so first reproduce the intermittent empty list in a small MapView harness and compare a failing launch against a passing one. Done means the sheet always lists the style attributions plus any source attribution.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Environment
- Xcode version: 27.2 (27B52)
- iOS version: iOS 27.2 (Simulator); one physical iPhone
- Devices affected: iOS Simulator (iPhone 17) and a physical iPhone
- Maps SDK Version: MapboxMaps 11.26.0, MapboxCoreMaps 11.26.0, MapboxCommon 24.26.0
Observed behavior and steps to reproduce
Intermittently, the attribution (ⓘ) button's action sheet lists no attributions. The sheet titled "Powered by Mapbox Maps" shows only "Mapbox Telemetry", "Mapbox Privacy Policy" and "Cancel". The "© Mapbox", "© OpenStreetMap" and "Improve this map" entries are missing.
- Style: Mapbox Standard (
MapInitOptions(mapStyle: .standard(...))). The map is hosted in SwiftUI through aUIViewRepresentable. - How often: 2 of 6 app launches on the Simulator, and at least once on a device. The other launches list every attribution.
- It sticks: once a
MapView's list is empty, it stays empty for the life of that view. Reopening the sheet, waiting 5 s, or moving the camera doesn't bring it back.
We couldn't reduce it to a minimal project. What we measured in unit tests, reading the list the sheet uses (MapboxMap.loadAttributions via @testable import MapboxMaps) after the style had loaded:
| Setup | Empty lists |
|---|---|
Bare MapView, same Standard options, nothing else |
0 of 17 |
| Same map, with our setup attached before the map loads | 3 of 58 |
| Same, without the four observers listed last below | 1 of 52 |
"Our setup" subscribes, before load, to onCameraChanged, onRenderFrameFinished, onMapIdle, onStyleLoaded and onMapLoaded, and also to onSourceDataLoaded, onMapLoadingError, a second onMapIdle and a second onCameraChanged. In onMapLoaded it adds a raster-dem source (mapbox://mapbox.mapbox-terrain-dem-v1) with a hillshade layer and terrain, a vector source (mapbox://mapbox.mapbox-terrain-v2) for contour lines, GeoJSON sources with symbol and circle layers, and sometimes a raster source with its own attribution. Removing the onMapLoaded, onMapIdle or onRenderFrameFinished handler one at a time gave 0 of 12 each, which at this rate is too few runs to tell either way.
Expected behavior
The ⓘ sheet always lists the style's attributions: "© Mapbox", "© OpenStreetMap", "Improve this map", plus the attribution of any source on the map. The attribution guide names the ⓘ button as the way an iOS app shows the required attribution. When the list is empty, the app has no attribution on screen.
Notes / preliminary analysis
- The sheet's list comes from
MapboxMap.loadAttributions, which isAttribution.parse(__map.getAttributions()). In the failing cases that call returns nothing, even though the style has loaded. In the app the map itself renders normally. - Empty-or-full is decided once per map and doesn't change afterwards, which makes us suspect a race when the style's sources are first registered, not a problem in the sheet's UI.
- As a workaround we're adding our own text attribution on the map, next to the logo.
Additional links and references
- Ngôn ngữ chính
- Swift
- Star
- 601
- Fork
- 198
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc 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 mapbox/mapbox-maps-ios
-
auto-triaged bug :beetle: p1
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 18/100
mapbox/mapbox-maps-ios#2460 ·
-
auto-triaged bug :beetle: p2
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
mapbox/mapbox-maps-ios#2459 ·
-
auto-triaged bug :beetle: p1
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 38/100
mapbox/mapbox-maps-ios#2456 · 1 bình luận ·
-
auto-triaged bug :beetle: p1
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 15/100
mapbox/mapbox-maps-ios#2455 · 1 bình luận ·
-
auto-triaged bug :beetle: p1
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 12/100
mapbox/mapbox-maps-ios#2453 · 1 bình luận ·
Tất cả issue của mapbox/mapbox-maps-ios
Issue tương tự
-
area: build-and-ci S3: minor
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
manaflow-ai/cmux#65734 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Kokoro ANE legacy: Alignment still runs the graph that traps at 48 tokens (#1172 fixed v3 only)Đang mởbug text-to-speech
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
FluidInference/FluidAudio#1201 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
OneBusAway/onebusaway-ios#2025 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
good first issue help wanted
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 95/100
erkamyaman/rust-anything#930 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
contributor: external iOS needs review sdk-58 severity: low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
expo/expo#54458 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày