mapbox / mapbox/mapbox-maps-ios

SymbolSortKey functions differently for point annotation and symbolLayer

Open
#845 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-triaged bug :beetle:
Dominant language
Swift
Stars
601
Forks
196
PR merge metrics
No merged PRs in 30d

Description

Environment

  • Xcode version: 13
  • iOS version: all
  • Devices affected: simulator
  • Maps SDK Version: 10.1.0

Observed behavior and steps to reproduce

It appears that symbolSortKey doesn't work the same for point annotations and symbol layers. Despite symbolSortKey having the same description in our docs, when you set it for point annotations, the annotation with the lower sort key is drawn first so it ends up closest to the map, while for symbol layers, the annotation with the lower sort key is drawn last and is closest to the user.

Expected behavior

symbolSortKey behavior is consistent for both point annotations and symbolLayers

Notes / preliminary analysis

Additional links and references

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported ordering difference between point annotations and symbol layers with Maps SDK 10.1.0 on Xcode 13 and iOS. Compare how symbolSortKey is handled in both paths, then verify that lower and higher sort keys produce consistent draw order for point annotations and symbol layers.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.