flutter-mapbox-gl / maps

A Mapbox GL flutter package for creating custom maps
Other
1.04k stars 503 forks source link

Crashes on iOS Simulator #1171

Closed danehale0612 closed 1 year ago

danehale0612 commented 2 years ago

The app will load but before the map will load it will crash on iOS simulator. Works on Android though. And physical devices. But I really want to simulate location on iOS.

Translated Report (Full Report Below)

Incident Identifier: 09A9BDD6-E00C-42F4-B10F-DE8CB88BEFDD CrashReporter Key: 64C6238F-3B2E-B8A4-7F86-F853893FDC71 Hardware Model: MacBookPro12,1 Process: Runner [46143] Path: /Users/USER/Library/Developer/CoreSimulator/Devices/79C8466E-AEF5-4D3E-B933-EC8216169498/data/Containers/Bundle/Application/3D204128-9601-4D5F-A93D-99057DED56E6/Runner.app/Runner Version: 1.0.5 (7) Code Type: X86-64 (Native) Role: Foreground Parent Process: launchd_sim [63360] Responsible Process: SimulatorTrampoline [1994]

Date/Time: 2022-09-07 14:55:16.9490 -0500 Launch Time: 2022-09-07 14:55:11.1641 -0500 OS Version: macOS 12.5.1 (21G83) Release Type: User Report Version: 104

Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Subtype: KERN_INVALID_ADDRESS at 0x00007f7dd3571ec0 Exception Codes: 0x0000000000000001, 0x00007f7dd3571ec0 VM Region Info: 0x7f7dd3571ec0 is not in any region. Bytes after previous region: 4277345985 Bytes before following region: 523491311936 REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL MALLOC_LARGE 7f7cd4620000-7f7cd4640000 [ 128K] rw-/rwx SM=PRV
---> GAP OF 0x7ae176a000 BYTES Stack Guard 7ff7b5daa000-7ff7b95aa000 [ 56.0M] ---/rwx SM=NUL
Exception Note: EXC_CORPSE_NOTIFY Termination Reason: SIGNAL 11 Segmentation fault: 11 Terminating Process: exc handler [46143]

Triggered by Thread: 0

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libGLProgrammability.dylib 0x7fff40475756 glvmRasterOpDepthStencilTest + 438 1 libGLProgrammability.dylib 0x7fff404c4195 glvmInterpretFPTransformFour + 2405 2 GLRendererFloat 0x7fff5bf56f8e gldLLVMFPTransform + 734 3 GLRendererFloat 0x7fff5bf6b0c4 gldLLVMVecPolyRender + 23124 4 GLRendererFloat 0x7fff5bf53540 gldRenderFillPolygonPtr + 90 5 GLEngine 0x7fff40424d21 gleLLVMVecPrimMultiRender + 4593 6 GLEngine 0x7fff403646f7 gleFlushAtomicFunc + 15 7 GLEngine 0x7fff403b110d glDrawElements_IMM_ES2Exec + 925 8 Mapbox 0x1083c39fa mbgl::gl::Context::draw(mbgl::gfx::DrawMode const&, unsigned long, unsigned long) + 138 9 Mapbox 0x10842a827 mbgl::gl::Program::draw(mbgl::gfx::Context&, mbgl::gfx::RenderPass&, mbgl::gfx::DrawMode const&, mbgl::gfx::DepthMode const&, mbgl::gfx::StencilMode const&, mbgl::gfx::ColorMode const&, mbgl::gfx::CullFaceMode const&, mbgl::gfx::UniformValues<mbgl::TypeList<mbgl::uniforms::matrix, mbgl::uniforms::ratio, mbgl::uniforms::units_to_pixels, mbgl::uniforms::device_pixel_ratio, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::uniforms::blur, mbgl::uniforms::color, mbgl::uniforms::floorwidth, mbgl::uniforms::gapwidth, mbgl::uniforms::offset, mbgl::uniforms::opacity, mbgl::uniforms::pattern_to, mbgl::uniforms::pattern_from, mbgl::uniforms::pixel_ratio_to, mbgl::uniforms::pixel_ratio_from, mbgl::uniforms::width> > const&, mbgl::gfx::DrawScope&, mbgl::gfx::AttributeBindings<mbgl::TypeList<mbgl::attributes::pos_normal, mbgl::attributes::data<unsigned char, 4ul>, mbgl::attributes::linesofar, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute > > const&, mbgl::gfx::TextureBindings<mbgl::TypeList<> > const&, mbgl::gfx::IndexBuffer const&, unsigned long, unsigned long) + 743 10 Mapbox 0x1084a0d06 void mbgl::Program<mbgl::LineProgram, (mbgl::gfx::PrimitiveType)2, mbgl::TypeList<mbgl::attributes::pos_normal, mbgl::attributes::data<unsigned char, 4ul>, mbgl::attributes::linesofar>, mbgl::TypeList<mbgl::uniforms::matrix, mbgl::uniforms::ratio, mbgl::uniforms::units_to_pixels, mbgl::uniforms::device_pixel_ratio>, mbgl::TypeList<>, mbgl::style::LinePaintProperties, mbgl::TypeList<> >::draw(mbgl::gfx::Context&, mbgl::gfx::RenderPass&, mbgl::gfx::Triangles const&, mbgl::gfx::DepthMode const&, mbgl::gfx::StencilMode const&, mbgl::gfx::ColorMode const&, mbgl::gfx::CullFaceMode const&, mbgl::gfx::IndexBuffer const&, std::1::vector<mbgl::Segment, std::1::allocator > const&, mbgl::gfx::UniformValues<mbgl::TypeList<mbgl::uniforms::matrix, mbgl::uniforms::ratio, mbgl::uniforms::units_to_pixels, mbgl::uniforms::device_pixel_ratio, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::InterpolationUniform, mbgl::uniforms::blur, mbgl::uniforms::color, mbgl::uniforms::floorwidth, mbgl::uniforms::gapwidth, mbgl::uniforms::offset, mbgl::uniforms::opacity, mbgl::uniforms::pattern_to, mbgl::uniforms::pattern_from, mbgl::uniforms::pixel_ratio_to, mbgl::uniforms::pixel_ratio_from, mbgl::uniforms::width> > const&, mbgl::gfx::AttributeBindings<mbgl::TypeList<mbgl::attributes::pos_normal, mbgl::attributes::data<unsigned char, 4ul>, mbgl::attributes::linesofar, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute, mbgl::ZoomInterpolatedAttribute > > const&, mbgl::gfx::TextureBindings<mbgl::TypeList<> > const&, std::1::basic_string<char, std::__1::char_traits, std::1::allocator > const&) + 230 11 Mapbox 0x10849b8b3 mbgl::RenderLineLayer::render(mbgl::PaintParameters&) + 4243 12 Mapbox 0x1084d89aa mbgl::Renderer::Impl::render(mbgl::RenderTree const&) + 2634 13 Mapbox 0x1084d6cc3 mbgl::Renderer::render(std::1::shared_ptr const&) + 51 14 Mapbox 0x1087a5d2c MGLRenderFrontend::render() + 68 (MGLRendererFrontend.h:57) [inlined] 15 Mapbox 0x1087a5d2c -[MGLMapView renderSync] + 813 (MGLMapView.mm:1161) 16 Mapbox 0x10875a61b MGLMapViewImpl::render() + 28 (MGLMapView+Impl.mm:18) [inlined] 17 Mapbox 0x10875a61b -[MGLMapViewImplDelegate glkView:drawInRect:] + 39 (MGLMapView+OpenGL.mm:30) 18 GLKit 0x7fff4f1e13f4 -[GLKView _display:] + 267 19 QuartzCore 0x7fff28a927a7 CA::Layer::layout_and_display_if_needed(CA::Transaction) + 479 20 QuartzCore 0x7fff289b48ed CA::Context::commit_transaction(CA::Transaction, double, double*) + 623 21 QuartzCore 0x7fff289ebf6e CA::Transaction::commit() + 774 22 QuartzCore 0x7fff289ed1ec CA::Transaction::flush_as_runloop_observer(bool) + 60 23 CoreFoundation 0x7fff203712f1 CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION + 23 24 CoreFoundation 0x7fff2036bab5 CFRunLoopDoObservers + 570 25 CoreFoundation 0x7fff2036c04d __CFRunLoopRun + 1100 26 CoreFoundation 0x7fff2036b704 CFRunLoopRunSpecific + 562 27 GraphicsServices 0x7fff2cba9c8e GSEventRunModal + 139 28 UIKitCore 0x7fff2509e65a -[UIApplication _run] + 928 29 UIKitCore 0x7fff250a32b5 UIApplicationMain + 101 30 Runner 0x10615b07f main + 63 (AppDelegate.swift:6) 31 dyld_sim 0x107947f21 start_sim + 10 32 dyld 0x11429b52e start + 462

felix-ht commented 2 years ago

this is a long standing issue - do not expect this to get fixed any time soon

devolonter commented 2 years ago

Downgrading the simulator to iOS 15.2 solves the issue https://lightrun.com/answers/rnmapbox-maps-example-app-crashes-on-ios-154-emulator-only. On device it works well

aardrop commented 1 year ago

I am having this same issue on my project, but it's not accruing when running the example project, both on the same emulator. Any ideas why that might be?

aardrop commented 1 year ago

Don't know if this helps, but the example works on my iOS 16 simulator on the UI test cases but breaks on the Lines view

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.