maps icon indicating copy to clipboard operation
maps copied to clipboard

[Bug]: Mapbox styles are not loaded, causing a black screen on iOS 18.4 and Xcode 16.3

Open ustuncem opened this issue 9 months ago • 6 comments

Mapbox Implementation

Mapbox

Mapbox Version

11.8.0

React Native Version

0.76.9

Platform

iOS

@rnmapbox/maps version

10.1.37

Standalone component to reproduce

import React from 'react';
import {
  MapView,
  ShapeSource,
  LineLayer,
  Camera,
} from '@rnmapbox/maps';

const aLine = {
  type: 'LineString',
  coordinates: [
    [-74.00597, 40.71427],
    [-74.00697, 40.71527],
  ],
};

class BugReportExample extends React.Component {
  render() {
    return (
      <MapView style={{flex: 1}}>
        <Camera centerCoordinate={[-74.00597, 40.71427]} zoomLevel={14} />
        <ShapeSource id="idStreetLayer" shape={aLine}>
          <LineLayer id="idStreetLayer" />
        </ShapeSource>
      </MapView>
    );
  }
}

Observed behavior and steps to reproduce

Observed behavior: Black screen because app can't load the style. Gives a "MapLoad error Failed to load style: The network connection was lost." error. Happens on iOS version 18.4, Xcode 16.3.

Steps to reproduce:

  1. Update the package react-native to version 0.76.9 and install the dependencies.
  2. Run the example app on the repo.
  3. Visit any of the example maps. All of them are black. (Controls and the mapbox logo loads though.

Expected behavior

For the map style to load.

Notes / preliminary analysis

I tried with 3 different accounts(two of them were fresh registers. I followed the exact steps written in the guidelines and README of the example app. When I navigate to any of the maps after running it successfully, styles are both black. Probably it's unable to fetch them from the server. Happens on iOS version 18.4 and Xcode version 16.3. New release of Apple.

Image

Additional links and references

No response

ustuncem avatar Apr 04 '25 13:04 ustuncem

I think the issue is caused by the iOS 18.4 simulator, not just Mapbox, I'm also having issue with firebase messaging not working it can't find Apns,

I tested my app using xcode 16.3 on a physical device with ios 16.7 and it works properly.

HamoBoker avatar Apr 04 '25 16:04 HamoBoker

@HamoBoker thanks for the response, I suspected an emulator issue too, its giving a network connection error. Works fine on iOS 18.3 and below.

ustuncem avatar Apr 04 '25 18:04 ustuncem

Image I can confirm this issue as well. It was working fine on iOS 18.2 simulator.

WaseekSenju avatar Apr 08 '25 06:04 WaseekSenju

It should be related to this Issue

HamoBoker avatar Apr 08 '25 10:04 HamoBoker

Any updates or progress on this? I am having the same issue with TestFlight and on-device builds as well.

mrbagels avatar Apr 24 '25 13:04 mrbagels

FYI: We've addressed the issue in the latest stable release 11.12.0 of MapboxMaps SDK. https://github.com/mapbox/mapbox-maps-ios/releases/tag/v11.12.0

— Roman from Mapbox Maps SDK

OdNairy avatar May 08 '25 13:05 OdNairy

Upstream issue

mfazekas avatar Sep 07 '25 10:09 mfazekas