GithubHelp home page GithubHelp logo

crashmapsnapshotter's Introduction

CrashMapSnapshotter

Purpose

The purpose of this repo is to show a bug in the MKMapSnapshotter: if the snapshotter function start(completionHandler: @escaping MKMapSnapshotter.CompletionHandler) issues an error in its completionHandler, then the snapshotter cannot be used anymore unless the device is rebooted.

What is happening is, after the first error, the completion handler is not called anymore.

Content of the project

This project contains only one view controller: ViewController. This view controller contains a scroll view that displays a map snapshot. When zooming inside a snapshot, it gathers a better quality snapshot (i.e. same geographic area but snapshot image is bigger).
The first snapshot is taken at a low quality (892x713). After zooming, the snapshot is taken at a high quality (4460x3565).
In order to trigger an error every time when requesting a high quality snapshot, the high quality corresponds to a very big image.

There is a UILabel at the bottom of the screen to display the current quality and any error that happened.

How to test

  • Launch the app
    A snapshot should be displayed, debug label should tell that the low quality is currently displayed.
  • Zoom in the snapshot
    As the big quality cannot be loaded, the snapshotter will issue an error, this will be displayed in the debug label. Please note that this is not the bug as the completion handler is correctly called back with the error.
  • Kill the app and relaunch it.
    This is to display the low quality again

=> The low quality snapshot won't load. In fact, the completionHandler is not called.

๐Ÿ› In order to display the snapshot again, you must reboot the device. ๐Ÿ˜ญ

Tested on:
Xcode 10.2, 10.3 ; iOS 12.3.1 (iPhone X)
Xcode 11 beta 4 ; iOS 13.0 (iPhone Xr)

crashmapsnapshotter's People

Contributors

djavan-bertrand avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.