Picker has been removed from React Native. It can now be installed and imported from '@react-native-picker/picker after upgrading from react-native 0.65.1 to react-native 0.68.1

See original GitHub issue

New Version

0.68.1

Old Version

0.65.1

Build Target(s)

iOS 14 os 16

Output of react-native info

System: OS: macOS 12.6 CPU: (12) x64 Intel® Core™ i7-9750H CPU @ 2.60GHz Memory: 1.14 GB / 16.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 14.5.0 - /usr/local/bin/node Yarn: 1.22.4 - /usr/local/bin/yarn npm: 6.14.5 - /usr/local/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.3 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.4, iOS 16.0, macOS 12.3, tvOS 16.0, watchOS 9.0 Android SDK: API Levels: 23, 25, 26, 27, 28, 29, 30, 31 Build Tools: 28.0.3, 29.0.2, 29.0.3, 30.0.0, 30.0.2 System Images: android-26 | Google Play Intel x86 Atom, android-28 | Google APIs Intel x86 Atom, android-28 | Google Play Intel x86 Atom, android-29 | Google Play Intel x86 Atom Android NDK: Not Found IDEs: Android Studio: 2020.3 AI-203.7717.56.2031.7678000 Xcode: 14.0.1/14A400 - /usr/bin/xcodebuild Languages: Java: 13.0.2 - /usr/bin/javac npmPackages: @react-native-community/cli: ^7.0.4 => 7.0.4 react: 17.0.2 => 17.0.2 react-native: 0.68.1 => 0.68.1 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found

Issue and Reproduction Steps

Hey guys, I just updated my application from RN 0.65.1 to RN 0.68.1. Currently, when I’m running iOS the application is installed correctly and launched successfully e.g ( success Successfully launched the app on the simulator ) .

Once the Metro is loaded I do see this error :

ERROR Invariant Violation: Picker has been removed from React Native. It can now be installed and imported from ‘@react-native-picker/picker’ instead of ‘react-native’. See https://github.com/react-native-picker/picker

ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.

  This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.

ERROR Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.

  This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.

What bothers me is the first one e.g react-native-picker.

I do not use Picker in my code anywhere. I do not import it or export it.

Doest anyone faced that before?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
Aggroidcommented, Oct 18, 2022

Hey guys, i resolved it by updating “react-native-globals”: “^0.60.3”, to 0.64.0. Globals is using Picker. You can close this and I hope my answer to help someone with the same issue.

0reactions
cortinicocommented, Oct 17, 2022

Hey cortinico unfortunately I cannot. The application is with a private source for a very big company.

Then I sadly can’t help you further. You’ll have to create a minimal reproducer that attempts to recreate this scenario.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Picker has been removed from React Native. It can now be ...
A frequent cause of the error is that the application entry file path is incorrect. This can also happen when the JS bundle...
Read more >
@react-native-picker/picker - npm
React Native Picker for iOS, Android, macOS, and Windows. ... Start using @react-native-picker/picker in your project by running `npm i ...
Read more >
AppState - React Native
AppState can tell you if the app is in the foreground or background, and notify you when the state changes.
Read more >
Picker - Expo Documentation
This library was formerly known as @react-native-community/picker . If you have that library in your SDK 40+ project, you can uninstall it and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found