You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
importReactfrom"react";import{Button,StyleSheet,TouchableOpacity,View,Text}from"react-native";importMapboxfrom"@rnmapbox/maps";import{HeatmapLayer,ShapeSource,CircleLayer}from"@rnmapbox/maps";Mapbox.setAccessToken("");constApp=()=>{return(<Mapbox.MapViewstyleURL="mapbox://styles/gavinruihanyu/cll3vsy9s006w01r8aptc3y9b"projection="globe"rotateEnabled={true}scaleBarEnabled={false}logoEnabled={false}>{/*Add the GeoJSON source and heatmap layer*/}<ShapeSourceid="earthquakes"url="https://docs.mapbox.com/mapbox-gl-js/assets/earthquakes.geojson">{console.log("Setting up HeatmapLayer")/* THIS IS THE CULPRIT*/}<HeatmapLayerid="hello"sourceID="earthquakes"/>{/* <CircleLayer id="earthquakeCircle" sourceID="earthquakes" style={{ circleRadius: 4, circleColor: "blue", circleOpacity: 0.6, }} /> */}</ShapeSource></Mapbox.MapView>);}exportdefaultApp;
Observed behavior and steps to reproduce
The Behavior:
When launching an app bundled with either Metro or EAS Expo, the rendering of HeatmapLayer appears to cause the application to crash. This is happening on Android without double checking IOS.
Upon launch of the app, we initially render the globe:
However the application crashes immediately with no error logs or logs of any kind.
There does not seem to be a deletion of the running instance of the app considering that the app can still be accessed via:
Reproduction:
The application was both tested via bundling EAS Expo and React Native Cli Metro.
The error was only able to be reproduced in Android.
Virtualization was used for both cases. -> need to check if it crashes on an Android device
My team discovered that upon calling <HeatmapLayer id="earthquakesHeat" sourceID="earthquakes" /> we obtain the "crash". However, calling <HeatmapLayer sourceID="earthquakes" /> (without the ID param) we obtain a globe without the heatmap render. However it does not crash when there is no ID param.
Exact reproduction method:
Create either an Expo EAS or a react-native Metro Project.
Use any android emulator using virtualization (any chipset, all failed thus far)
Run the following code mentioned above
Expected behavior
No response
Notes / preliminary analysis
No response
Additional links and references
No response
The text was updated successfully, but these errors were encountered:
gavinruihanyu
changed the title
[Bug]: React Native Heatmaps Crashes When 🆔 field is supplied
[Bug]: React Native Heatmaps Causes Crash When 🆔 field is supplied
May 6, 2024
gavinruihanyu
changed the title
[Bug]: React Native Heatmaps Causes Crash When 🆔 field is supplied
[Bug]: React Native Heatmaps Not Working and Causes Crash
May 6, 2024
Mapbox Implementation
Mapbox
Mapbox Version
default
React Native Version
0.74
Platform
Android
@rnmapbox/maps
version10.0.0-beta.11
Standalone component to reproduce
Observed behavior and steps to reproduce
The Behavior:
When launching an app bundled with either Metro or EAS Expo, the rendering of
HeatmapLayer
appears to cause the application to crash. This is happening on Android without double checking IOS.Upon launch of the app, we initially render the globe:
![image](https://private-user-images.githubusercontent.com/63630527/328131736-88ae4b75-acc5-4758-9379-a5c67dc7bb2c.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTk5ODM3MDYsIm5iZiI6MTcxOTk4MzQwNiwicGF0aCI6Ii82MzYzMDUyNy8zMjgxMzE3MzYtODhhZTRiNzUtYWNjNS00NzU4LTkzNzktYTVjNjdkYzdiYjJjLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzAzVDA1MTAwNlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTBkNmU2ZGFhZTEzYmY2YjFkNDI2NDRhMDZjYzRmZGVhNDRiMmFjNGZiODVlYzY0ZWU1MGEwODhjM2VkNWU0MGQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.V3LVATWBhLuxVt7SJGF7toTksbvbj3_EYEk5jITAeFQ)
![image](https://private-user-images.githubusercontent.com/63630527/328131479-3f6e1f83-a76c-4002-bbf6-29ca9d7c8cb9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTk5ODM3MDYsIm5iZiI6MTcxOTk4MzQwNiwicGF0aCI6Ii82MzYzMDUyNy8zMjgxMzE0NzktM2Y2ZTFmODMtYTc2Yy00MDAyLWJiZjYtMjljYTlkN2M4Y2I5LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzAzVDA1MTAwNlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWQ5YzdlMTI3YzM3MzI2M2I1MTVlZGMwNzUxMzc2YmVlOGExY2Y1OTU2ZTBhYmU4YWJhM2Y5NDQwMmEwNjliOGQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.viT4BI-0v8HGXUHt6aVgz6pA-zf4IRdDtbr1aC_R1pM)
![image](https://private-user-images.githubusercontent.com/63630527/328132157-108b69db-d910-4d8b-8c36-3a6e64edd018.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTk5ODM3MDYsIm5iZiI6MTcxOTk4MzQwNiwicGF0aCI6Ii82MzYzMDUyNy8zMjgxMzIxNTctMTA4YjY5ZGItZDkxMC00ZDhiLThjMzYtM2E2ZTY0ZWRkMDE4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzAzVDA1MTAwNlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWVlMTExODM1YmRkNmQyMWY3MjQzYzZiNDU4OGI3YzgxMDlhNTc2NDk3Y2UxMmNjMGMxMjczZWEwYzM5MjQzM2ImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Ic6W8x5w3lv5Xn7RRIla7iuZm-FVzAygSgd0PwvxmJU)
However the application crashes immediately with no error logs or logs of any kind.
There does not seem to be a deletion of the running instance of the app considering that the app can still be accessed via:
Reproduction:
The application was both tested via bundling EAS Expo and React Native Cli Metro.
The error was only able to be reproduced in Android.
Virtualization was used for both cases. -> need to check if it crashes on an Android device
My team discovered that upon calling
<HeatmapLayer id="earthquakesHeat" sourceID="earthquakes" />
we obtain the "crash". However, calling<HeatmapLayer sourceID="earthquakes" />
(without the ID param) we obtain a globe without the heatmap render. However it does not crash when there is no ID param.Exact reproduction method:
Expected behavior
No response
Notes / preliminary analysis
No response
Additional links and references
No response
The text was updated successfully, but these errors were encountered: