-
Type:
Bug
-
Resolution: Gone away
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: BSON
-
None
Summary
The javascript bson package makes builds in expo 48 (react-native 0.71.x) fail and crashes expo 49 (react native 0.72.x). It seems to be related to some node stuff.
The docs of the bson-js package provide guidance on how to use bson in react-native applications, which i applied but they do not solve the issue. The error logs let me assume that node internals are not polyfilled correctly or not at all.
Environment
expo 48 / react-native 0.71
expo 49 / react-native 0.72
EAS build with default machine settings
How to Reproduce
- Create an expo project using eas cli with expo 49 and react native 0.72.x
_- use bson package as described in react-native readme section of https://github.com/mongodb/js-bson_
Additional Background
Logs:
```
[stderr] /home/expo/workingdir/build/apps/xxx/android/app/build/generated/assets/createBundleReleaseJsAndAssets/index.android.bundle:2502:18: warning: the variable "DebuggerInternal" was not declared in function "__shouldPauseOnThrow"
2067[stderr] {{ typeof DebuggerInternal !== 'undefined' &&}}
2068[stderr] {{ ^~~~~~~~~~~~~~~~}}
2069[stderr] /home/expo/workingdir/build/apps/xxxx/android/app/build/generated/assets/createBundleReleaseJsAndAssets/index.android.bundle:11172:7: warning: the variable "setTimeout" was not declared in function "logCapturedError"
2070[stderr] {{ setTimeout(function () {}}
2071[stderr] {{ ^~~~~~~~~~}}
2072[stderr] /home/expo/workingdir/build/apps/xxxx/android/app/build/generated/assets/createBundleReleaseJsAndAssets/index.android.bundle:9132:108: warning: the variable "nativeFabricUIManager" was not declared in function "onChange"
2073[stderr] ...lInstanceHandle ? (from && nativeFabricUIManager.setIsJSResponder(from.sta...
2074[stderr] {{ ^~~~~~~~~~~~~~~~~~~~~}}
- is related to
-
NODE-5469 Investigate bson compatibility with metro bundler
-
- Closed
-