rnmapbox / maps

A Mapbox react native module for creating custom maps
MIT License
2.23k stars 839 forks source link

[Bug]: incompatiblity with fresco@3.3.0 #3650

Closed efstathiosntonas closed 2 hours ago

efstathiosntonas commented 2 hours ago

Mapbox Implementation

Mapbox

Mapbox Version

11.6.0

React Native Version

0.75.4

Platform

Android

@rnmapbox/maps version

10.1.31

Fresco@3.3.0 will probably land on rn@0.76 according to this PR: https://github.com/facebook/react-native/pull/46864

edit node_modules/react-native/gradle/libs.versions.toml -> set fresco = "3.3.0" -> build fails:

> Task :rnmapbox_maps:compileDebugKotlin
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapView.kt:18:27 Unresolved reference: ViewTreeLifecycleOwner
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapView.kt:119:30 Object is not abstract and does not implement abstract member public abstract val lifecycle: Lifecycle defined in com.rnmapbox.rnmbx.components.mapview.RNMBXLifeCycleOwner
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapView.kt:134:17 'getLifecycle' overrides nothing
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/mapview/RNMBXMapView.kt:138:13 Unresolved reference: ViewTreeLifecycleOwner
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/styles/RNMBXStyleImport.kt:9:37 Unresolved reference: style
e: file:///Users/stathis/IdeaProjects/APP_NAME_mobile/node_modules/@rnmapbox/maps/android/src/main/java/com/rnmapbox/rnmbx/components/styles/layers/RNMBXLayer.kt:21:37 Unresolved reference: layer

> Task :rnmapbox_maps:compileDebugKotlin FAILED

downgrading fresco@3.2.0 builds fine.

remarks:

  1. I build rn on Android from source
  2. tried to clean gradle, same results
efstathiosntonas commented 2 hours ago

Hey guys, not a big deal for now but we might face this in the future, this is just a "proactive" bug report.

github-actions[bot] commented 2 hours ago

No code example found in issue body - More info