atom / github

:octocat: Git and GitHub integration for Atom
https://github.atom.io
MIT License
1.12k stars 394 forks source link

## Environment #2788

Open Deloww opened 2 years ago

Deloww commented 2 years ago

Environment

Observed behavior and steps to reproduce

When using a mapView and using mapView.camera.fly(to:, duration:, completion:), mapViews camera will sometimes not fly to desired bounds. -Create a MapView -Generate custom Bounds (in my case a Function returns the most south, West, North & East coordinates of all steps of a route to make sure to fit the whole route on the screen (function very well tested, works for sure)) and use them to... -Create a camera object using mapView.mapboxMap.camera(for:, padding: , bearing: , pitch: ) -Use mapView.camera.fly(to:, duration:, completion:) to fly to the camera we've just created

This will work most of the time, but will sometimes just not work without any error. It just does not move the screen at all. I have tested a lot but can't seem to find a pattern as to whether it works or not. It fails most of the time when being zoomed in to the max, but also fails sometimes when doing the exact same thing I did the time before when it worked... I am printing the bounds I calculated and I am plotting them on a map to check if they are correct - that's never the issue.

When drawing a route, for example, the route is currently sometimes mostly off-screen, which is bad.

Expected behavior

The MapView should fly to fit the bounds we have set, at any cost, or at least give back an error that we can work with. Right now, I cannot find what causes this because of missing feedback.

Notes / preliminary analysis

Additional links and references

Originally posted by @JanTG1 in https://github.com/mapbox/mapbox-maps-ios/issues/1598