Skip to content

Issue after upgrading React Native from 0.73.8 to 0.79.0 #50755

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
shubhanshubb opened this issue Apr 16, 2025 · 7 comments
Closed

Issue after upgrading React Native from 0.73.8 to 0.79.0 #50755

shubhanshubb opened this issue Apr 16, 2025 · 7 comments

Comments

@shubhanshubb
Copy link

shubhanshubb commented Apr 16, 2025

Description

I recently upgraded my React Native project from version 0.73.8 to 0.79.0. (with the help of React Native Upgrade Helper)

Also for ios same

Ran ./gradlew clean – worked fine
Ran npx react-native run-android – build was successful
However, after launching the app, I get the following error:

ERROR Connection terminated with Device for app='com.arpitrw.wiingytutorapp' on device='iPhone 16' with idle='true' after not responding for 60 seconds.
INFO Connection closed to device='iPhone 16' for app='com.arpitrw.wiingytutorapp' with code='1006' and reason=''.
INFO Connection closed to DevTools for app='com.arpitrw.wiingytutorapp' on device='iPhone 16' with code='1005' and reason=''.
ERROR Failed to open debugger for com.arpitrw.wiingytutorapp (iPhone 16) (React Native Bridgeless [C++ connection]): Network error
ERROR Cause: HeadersTimeoutError: Headers Timeout Error
at Timeout.onParserTimeout [as callback] (node:internal/deps/undici/undici:5975:32)
at Timeout.onTimeout [as _onTimeout] (node:internal/deps/undici/undici:2356:17)
at listOnTimeout (node:internal/timers:581:17)
at process.processTimers (node:internal/timers:519:7) {
code: 'UND_ERR_HEADERS_TIMEOUT'
}

Stack trace includes:

Any idea what could be causing this? Could it be due to an incompatible library or a breaking change in RN 0.79?

Steps to reproduce

yarn start

cd ios
pod install

Xcode
clean build folder
Build

React Native Version

0.79.0

Affected Platforms

Runtime - iOS

Output of npx @react-native-community/cli info

System:
  OS: macOS 15.4
  CPU: (8) arm64 Apple M1
  Memory: 139.98 MB / 8.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 20.16.0
    path: ~/.nvm/versions/node/v20.16.0/bin/node
  Yarn:
    version: 3.6.4
    path: /opt/homebrew/bin/yarn
  npm:
    version: 10.8.1
    path: ~/.nvm/versions/node/v20.16.0/bin/npm
  Watchman:
    version: 2025.04.14.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.16.2
    path: /Users/shubhanshu/.rbenv/shims/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.4
      - iOS 18.4
      - macOS 15.4
      - tvOS 18.4
      - visionOS 2.4
      - watchOS 11.4
  Android SDK: Not Found
IDEs:
  Android Studio: 2024.3 AI-243.24978.46.2431.13208083
  Xcode:
    version: 16.3/16E140
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.14
    path: /opt/homebrew/opt/openjdk@17/bin/javac
  Ruby:
    version: 2.7.4
    path: /Users/shubhanshu/.rbenv/shims/ruby
npmPackages:
  "@react-native-community/cli":
    installed: 18.0.0
    wanted: 18.0.0
  react:
    installed: 19.0.0
    wanted: 19.0.0
  react-native:
    installed: 0.79.1
    wanted: ^0.79.0
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

Stacktrace or Logs

Thread 1 Queue : com.apple.main-thread (serial)
Thread 1: "*** -[__NSArrayM insertObject:atIndex:]: object cannot be nil";


 ERROR  Connection terminated with Device for app='com.arpitrw.wiingytutorapp' on device='iPhone 16' with idle='true' after not responding for 60 seconds.
 INFO  Connection closed to device='iPhone 16' for app='com.arpitrw.wiingytutorapp' with code='1006' and reason=''.
 INFO  Connection closed to DevTools for app='com.arpitrw.wiingytutorapp' on device='iPhone 16' with code='1005' and reason=''.
 ERROR  Failed to open debugger for com.arpitrw.wiingytutorapp (iPhone 16) (React Native Bridgeless [C++ connection]): Network error
 ERROR  Cause: HeadersTimeoutError: Headers Timeout Error
    at Timeout.onParserTimeout [as callback] (node:internal/deps/undici/undici:5975:32)
    at Timeout.onTimeout [as _onTimeout] (node:internal/deps/undici/undici:2356:17)
    at listOnTimeout (node:internal/timers:581:17)
    at process.processTimers (node:internal/timers:519:7) {
  code: 'UND_ERR_HEADERS_TIMEOUT'
}

Reproducer

https://github.com/shubhanshubb/ReproducerApp

Screenshots and Videos

Image for reference

Image

Video for refernce

Simulator.Screen.Recording.-.iPhone.16.-.2025-04-16.at.00.06.15.mp4
@react-native-bot
Copy link
Collaborator

Tip

Newer version available: You are on a supported minor version, but it looks like there's a newer patch available - 0.79.1. Please upgrade to the highest patch for your minor or latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If it does not repro, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the most recent releases.

@react-native-bot
Copy link
Collaborator

Tip

Newer version available: You are on a supported minor version, but it looks like there's a newer patch available - undefined. Please upgrade to the highest patch for your minor or latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If it does not repro, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the most recent releases.

@shubhanshubb
Copy link
Author

shubhanshubb commented Apr 16, 2025

@react-native-bot Still facing same error after upgarded to react native 0.79.1

If I am correct I think it might coming from - BVLinearGradient (from ../node_modules/react-native-linear-gradient)

@shubhanshubb
Copy link
Author

0x170bc8818 115 Control stream closed but connection is alive
Error setting property 'colors' of BVLinearGradient with tag #3080: JSON value '' of type NSNull cannot be converted to a UIColor. Did you forget to call processColor() on the JS side?
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSArrayM insertObject:atIndex:]: object cannot be nil'
*** First throw call stack:
(
0 CoreFoundation 0x00000001804c88c0 __exceptionPreprocess + 172
1 libobjc.A.dylib 0x00000001800937cc objc_exception_throw + 72
2 CoreFoundation 0x00000001803a75cc -[__NSArrayM insertObject:atIndex:] + 1232
3 Wiingy.debug.dylib 0x00000001082c9964 -[BVLinearGradient setColors:] + 400
4 Wiingy.debug.dylib 0x0000000108e548f0 __49-[RCTComponentData createPropBlock:isShadowView:]_block_invoke.40 + 388
5 Wiingy.debug.dylib 0x0000000108e54ee8 __49-[RCTComponentData createPropBlock:isShadowView:]_block_invoke_2.41 + 636
6 Wiingy.debug.dylib 0x0000000108e556b8 __49-[RCTComponentData propBlockForKey:isShadowView:]_block_invoke_2 + 52
7 Wiingy.debug.dylib 0x0000000108ec36f4 RCTPerformBlockWithLogFunction + 432
8 Wiingy.debug.dylib 0x0000000108ec38a0 RCTPerformBlockWithLogPrefix + 236
9 Wiingy.debug.dylib 0x0000000108e55548 __49-[RCTComponentData propBlockForKey:isShadowView:]_block_invoke + 460
10 Wiingy.debug.dylib 0x0000000108e55a60 __50-[RCTComponentData setProps:forView:isShadowView:]_block_invoke + 144
11 CoreFoundation 0x0000000180410d3c NSDICTIONARY_IS_CALLING_OUT_TO_A_BLOCK + 16
12 CoreFoundation 0x0000000180535e68 -[__NSDictionaryM enumerateKeysAndObjectsWithOptions:usingBlock:] + 260
13 Wiingy.debug.dylib 0x0000000108e55930 -[RCTComponentData setProps:forView:isShadowView:] + 252
14 Wiingy.debug.dylib 0x0000000108e5571c -[RCTComponentData setProps:forView:] + 88
15 Wiingy.debug.dylib 0x0000000109198448 -[RCTLegacyViewManagerInteropCoordinator setProps:forView:] + 84
16 Wiingy.debug.dylib 0x00000001088db6b4 -[RCTLegacyViewManagerInteropCoordinatorAdapter setProps:] + 176
17 Wiingy.debug.dylib 0x00000001088d9930 -[RCTLegacyViewManagerInteropComponentView _setPropsWithUpdateMask:] + 96
18 Wiingy.debug.dylib 0x00000001088d971c __60-[RCTLegacyViewManagerInteropComponentView finalizeUpdates:]_block_invoke + 92
19 Wiingy.debug.dylib 0x00000001088d8e2c -[RCTLegacyViewManagerInteropComponentView finalizeUpdates:] + 556
20 Wiingy.debug.dylib 0x00000001088fa678 _ZL27RCTPerformMountInstructionsRKNSt3__16vectorIN8facebook5react18ShadowViewMutationENS_9allocatorIS3_EEEEP24RCTComponentViewRegistryR41RCTMountingTransactionObserverCoordinatori + 1212
21 Wiingy.debug.dylib 0x00000001088fa1b0 _ZZ41-[RCTMountingManager performTransaction:]ENK3$_1clERKN8facebook5react19MountingTransactionERKNS1_16SurfaceTelemetryE + 80
22 Wiingy.debug.dylib 0x00000001088fa154 _ZNSt3__18__invokeB8de190102IRZ41-[RCTMountingManager performTransaction:]E3$_1JRKN8facebook5react19MountingTransactionERKNS4_16SurfaceTelemetryEEEEDTclclsr3stdE7declvalIT_EEspclsr3stdE7declvalIT 23 Wiingy.debug.dylib 0x00000001088fa0fc _ZNSt3__128__invoke_void_return_wrapperIvLb1EE6__callB8de190102IJRZ41-[RCTMountingManager performTransaction:]E3$1RKN8facebook5react19MountingTransactionERKNS6_16SurfaceTelemetryEEEEvDpOT + 40
24 Wiingy.debug.dylib 0x00000001088fa0c8 _ZNSt3__110__function12__alloc_funcIZ41-[RCTMountingManager performTransaction:]E3$1NS_9allocatorIS2_EEFvRKN8facebook5react19MountingTransactionERKNS6_16SurfaceTelemetryEEEclB8de190102ES9_SC + 25 Wiingy.debug.dylib 0x00000001088f8f50 _ZNSt3__110__function6__funcIZ41-[RCTMountingManager performTransaction:]E3$1NS_9allocatorIS2_EEFvRKN8facebook5react19MountingTransactionERKNS6_16SurfaceTelemetryEEEclES9_SC + 44
26 Wiingy.debug.dylib 0x00000001091effb4 ZNKSt3__110__function12__value_funcIFvRKN8facebook5react19MountingTransactionERKNS3_16SurfaceTelemetryEEEclB8de190102ES6_S9 + 76
27 Wiingy.debug.dylib 0x00000001091ef234 ZNKSt3__18functionIFvRKN8facebook5react19MountingTransactionERKNS2_16SurfaceTelemetryEEEclES5_S8 + 40
28 Wiingy.debug.dylib 0x00000001091ef068 ZNK8facebook5react19TelemetryController15pullTransactionERKNSt3__18functionIFvRKNS0_19MountingTransactionERKNS0_16SurfaceTelemetryEEEESD_SD + 300
29 Wiingy.debug.dylib 0x00000001088f2c30 -[RCTMountingManager performTransaction:] + 588
30 Wiingy.debug.dylib 0x00000001088f2900 -[RCTMountingManager initiateTransaction:] + 496
31 Wiingy.debug.dylib 0x00000001088f2270 __42-[RCTMountingManager scheduleTransaction:]_block_invoke + 348
32 Wiingy.debug.dylib 0x0000000108f3e6ec __RCTExecuteOnMainQueue_block_invoke + 40
33 libdispatch.dylib 0x000000010283fec8 _dispatch_call_block_and_release + 24
34 libdispatch.dylib 0x0000000102859798 _dispatch_client_callout + 12
35 libdispatch.dylib 0x000000010284f408 _dispatch_main_queue_drain + 1220
36 libdispatch.dylib 0x000000010284ef34 _dispatch_main_queue_callback_4CF + 40
37 CoreFoundation 0x0000000180427fec CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE + 12
38 CoreFoundation 0x00000001804229f8 __CFRunLoopRun + 1920
39 CoreFoundation 0x0000000180421e3c CFRunLoopRunSpecific + 536
40 GraphicsServices 0x0000000190f62d00 GSEventRunModal + 164
41 UIKitCore 0x0000000185bcec98 -[UIApplication _run] + 796
42 UIKitCore 0x0000000185bd3064 UIApplicationMain + 124
43 UIKitCore 0x0000000184f9ad6c block_destroy_helper.14 + 9560
44 Wiingy.debug.dylib 0x00000001082a989c $sSo21UIApplicationDelegateP5UIKitE4mainyyFZ + 128
45 Wiingy.debug.dylib 0x00000001082a980c $s6Wiingy11AppDelegateC5$mainyyFZ + 44
46 Wiingy.debug.dylib 0x00000001082aa0d0 __debug_main_executable_dylib_entry_point + 28
47 dyld 0x000000010292d3d8 start_sim + 20
48 ??? 0x0000000102ab2b4c 0x0 + 4339739468
)
libc++abi: terminating due to uncaught exception of type NSException

@shubhanshubb
Copy link
Author

Error setting property 'colors' of BVLinearGradient with tag #4002: JSON value '' of type NSNull cannot be converted to a UIColor. Did you forget to call processColor() on the JS side?

@cipolleschi
Copy link
Contributor

Hi @shubhanshubb, I think that the issue is self explanatory. BVLinearGradient is receiving a color that can't be parsed and it is converted to null. And null can't be converted to UIColor.

Jumping from 0.73 to 0.79 is a big jump, and we touched colors multiple times in 6 versions. The most likely thing is that we changed an API for Colors that you were using and it's not working anymore.

I suggest to:

  1. go through the breaking changes of those 6 version to see which one can cause the problem
  2. audit your gradients, hopefully they are not a lot, and start simplifying them until you find the parameter that breaks everything. At this point, you should be able to fix it right away.

In 6 versions, there might be a lot of other changes. The biggest is that, starting from 0.76, the New Architecture is enabled by default. So you might have some libraries that are not compatible with it. AFAIK, LinearGradient should be compatible with the New Architecture, btw.

@shubhanshubb
Copy link
Author

@cipolleschi I have find the error this all happend because of @thevsstech/react-native-skeleton .
Thanks for this suggestion.
We can close this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants