callstack / repack

A Webpack-based toolkit to build your React Native application with full support of Webpack ecosystem.
https://re-pack.dev
MIT License
1.47k stars 106 forks source link

File not found in compilation assets causes memory leak #686

Closed krzysztofzaluski closed 1 month ago

krzysztofzaluski commented 2 months ago

Hey, in our project we are using RePack in version 4.1.1 (but I also tried latest 4.2.0) and if in our async services some error is thrown then we got a lot of Compiling webpack logs pointing to folder in which error appeared and then the server goes into an infinite loop until it throws an out of memory error as if there is some kind of memory leak, checking the computer activity monitor - the repack server swells to several gigabytes.

Here is an example output:

✖ [Console] TypeError: Cannot read property 'someParam' of undefined, js engine: hermes 
ℹ [DevServer] POST 200 /symbolicate request completed { responseTime: 412.853334069252 } 
ℹ [DevServer] POST 200 /symbolicate request completed { responseTime: 8.87387502193451 } 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 3% setup (watch run) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 23% building (2/8 entries 361/500 dependencies 14/164 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 23% building (2/8 entries 1390/1700 dependencies 68/484 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 23% building (2/8 entries 2128/2300 dependencies 185/807 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 2971/3100 dependencies 249/1235 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 5270/5300 dependencies 453/1800 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 6414/6444 dependencies 600/1943 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 6600/6863 dependencies 735/1972 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 7778/7800 dependencies 880/2230 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 7877/8000 dependencies 898/2232 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 9771/9900 dependencies 925/2605 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 11131/11200 dependencies 1213/2744 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 12304/12400 dependencies 1364/3141 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 14436/14700 dependencies 1604/3481 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 15230/15400 dependencies 1681/3587 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 30% building (3/8 entries 17423/17500 dependencies 1842/3736 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 36% building (3/8 entries 19631/19700 dependencies 2369/3941 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 39% building (3/8 entries 21100/21292 dependencies 2649/4086 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 39% building (3/8 entries 21884/21922 dependencies 2700/4244 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 41% building (3/8 entries 23614/23700 dependencies 2851/4669 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 46% building (3/8 entries 25700/26063 dependencies 3292/4913 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 49% building (3/8 entries 27141/27200 dependencies 3640/5034 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 52% building (3/8 entries 28127/28300 dependencies 3925/5093 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 56% building (3/8 entries 29999/30100 dependencies 4450/5297 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 57% building (3/8 entries 30692/30900 dependencies 4609/5349 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 60% building (5/8 entries 31753/32100 dependencies 5089/5579 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 60% building (5/8 entries 33700/33798 dependencies 5515/6011 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 64% building (52/53 entries 34977/34978 dependencies 6309/6310 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 65% building (53/53 entries 34978/34978 dependencies 6310/6310 modules) 
⇢ [LoggerPlugin] Compiling webpack:///src/services: 98% emitting (after emit) 
✖ [DevServer] File NotificationsService.js for webpack:///src/services not found in compilation assets {
  reqId: 'req-7',
  err: {
    type: 'Error',
    message: 'File NotificationsService.js for webpack:///src/services not found in compilation assets',
    stack: 'Error: File NotificationsService.js for webpack:///src/services not found in compilation assets\n' +
      '    at /Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:156:20\n' +
      '    at /Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:70:52\n' +
      '    at Array.forEach (<anonymous>)\n' +
      '    at callPendingResolvers (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:70:32)\n' +
      '    at Worker.<anonymous> (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:91:9)\n' +
      '    at Worker.emit (node:events:513:28)\n' +
      '    at MessagePort.<anonymous> (node:internal/worker:233:53)\n' +
      '    at [nodejs.internal.kHybridDispatch] (node:internal/event_target:731:20)\n' +
      '    at exports.emitMessage (node:internal/per_context/messageport:23:28)'
  }
} 
ℹ [DevServer] File NotificationsService.js for webpack:///src/services not found in compilation assets {
  reqId: 'req-7',
  res: { statusCode: 404 },
  err: {
    type: 'NotFoundError',
    message: 'File NotificationsService.js for webpack:///src/services not found in compilation assets',
    stack: 'NotFoundError: File NotificationsService.js for webpack:///src/services not found in compilation assets\n' +
      '    at Object.notFound (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/lib/httpErrors.js:37:12)\n' +
      '    at _Reply.notFound (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/index.js:50:42)\n' +
      '    at Object.handler (file:///Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack-dev-server/dist/plugins/compiler/compilerPlugin.js:66:22)',
    status: 404,
    statusCode: 404,
    expose: true
  }
} 
ℹ [DevServer] GET 404 /webpack:///src/services/NotificationsService.js request completed { responseTime: 64044.01366698742 } 
✖ [DevServer] Cannot detect platform { reqId: 'req-8' } 
ℹ [DevServer] Cannot detect platform {
  reqId: 'req-8',
  res: { statusCode: 400 },
  err: {
    type: 'BadRequestError',
    message: 'Cannot detect platform',
    stack: 'BadRequestError: Cannot detect platform\n' +
      '    at Object.badRequest (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/lib/httpErrors.js:21:12)\n' +
      '    at _Reply.badRequest (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/index.js:50:42)\n' +
      '    at Object.handler (file:///Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack-dev-server/dist/plugins/compiler/compilerPlugin.js:34:22)\n' +
      '    at preHandlerCallback (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/handleRequest.js:138:37)\n' +
      '    at validationCompleted (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/handleRequest.js:122:5)\n' +
      '    at preValidationCallback (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/handleRequest.js:99:5)\n' +
      '    at handler (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/handleRequest.js:76:7)\n' +
      '    at handleRequest (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/handleRequest.js:24:5)\n' +
      '    at runPreParsing (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/route.js:613:5)\n' +
      '    at next (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/fastify/lib/hooks.js:233:9)',
    status: 400,
    statusCode: 400,
    expose: true
  }
} 
ℹ [DevServer] GET 400 /NotificationsService.js request completed { responseTime: 2.736707925796509 } 
✖ [LoggerPlugin] Failed to build bundle due to errors 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Alert/Alert.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Alert' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Alert/Alert.js": Module not found: Error: Can't resolve './RCTAlertManager' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Alert' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/Animated.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/NativeAnimatedHelper.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/components/AnimatedImage.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/components/AnimatedScrollView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/nodes/AnimatedColor.js": Module not found: Error: Can't resolve '../../StyleSheet/PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/nodes' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/nodes/AnimatedStyle.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/nodes' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/shouldUseTurboAnimatedModule.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/AppState/AppState.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/AppState' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/AccessibilityInfo' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js": Module not found: Error: Can't resolve './legacySendAccessibilityEvent' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/AccessibilityInfo' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ActivityIndicator/ActivityIndicator.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ActivityIndicator' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Button.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Keyboard/Keyboard.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Keyboard' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Keyboard/KeyboardAvoidingView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Keyboard' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Pressable/useAndroidRippleForView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Pressable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/RefreshControl/RefreshControl.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/RefreshControl' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/SafeAreaView/SafeAreaView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/SafeAreaView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollViewNativeComponent.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollViewStickyHeader.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/processDecelerationRate.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/StatusBar/StatusBar.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/StatusBar' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Switch/Switch.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Switch' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/InputAccessoryView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/TextInput.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/TextInputState.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/Touchable.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableHighlight.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableNativeFeedback.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableOpacity.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/View/ViewNativeComponent.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/View' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/Devtools/loadBundleFromServer.js": Module not found: Error: Can't resolve '../../Network/RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core/Devtools' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/ReactNativeVersionCheck.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/setUpDeveloperTools.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/setUpReactDevTools.js": Module not found: Error: Can't resolve '../DevToolsSettings/DevToolsSettingsManager' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/EventEmitter/NativeEventEmitter.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/EventEmitter' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Image/AssetSourceResolver.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Image' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Image/ImageBackground.js": Module not found: Error: Can't resolve './Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Image' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Inspector/Inspector.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Inspector' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LayoutAnimation/LayoutAnimation.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LayoutAnimation' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Linking/Linking.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Linking' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Lists/FlatList.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Lists' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Lists/SectionList.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Lists' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/LogBox.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorCodeFrame.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorHeader.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorHeader.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorReactFrames.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorStackFrame.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxNotification.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Modal/Modal.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Modal' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NativeComponent/PlatformBaseViewConfig.js": Module not found: Error: Can't resolve './BaseViewConfig' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NativeComponent' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NativeComponent/ViewConfigIgnore.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NativeComponent' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Network/XMLHttpRequest.js": Module not found: Error: Can't resolve './RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Network' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NewAppScreen/components/DebugInstructions.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NewAppScreen/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NewAppScreen/components/ReloadInstructions.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NewAppScreen/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/PermissionsAndroid/PermissionsAndroid.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/PermissionsAndroid' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Pressability/HoverState.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Pressability' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Pressability/Pressability.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Pressability' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/PushNotificationIOS/PushNotificationIOS.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/PushNotificationIOS' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/BridgelessUIManager.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/PaperUIManager.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/renderApplication.js": Module not found: Error: Can't resolve '../Utilities/BackHandler' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactPrivate/ReactNativePrivateInterface.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactPrivate' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactPrivate/ReactNativePrivateInterface.js": Module not found: Error: Can't resolve '../Components/AccessibilityInfo/legacySendAccessibilityEvent' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactPrivate' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Share/Share.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Share' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/normalizeColor.js": Module not found: Error: Can't resolve './PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/processColor.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/processColor.js": Module not found: Error: Can't resolve './PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Text/Text.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Text' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Utilities/Appearance.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Utilities' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Utilities/DevSettings.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Utilities' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Vibration/Vibration.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Vibration' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/WebSocket/WebSocket.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/WebSocket' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/WebSocket/WebSocketInterceptor.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/WebSocket' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Utilities/BackHandler' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Network/RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/StyleSheet/PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/src/private/specs/modules/NativeExceptionsManager.js": Module not found: Error: Can't resolve '../../../../Libraries/Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/src/private/specs/modules' 
⇢ [LoggerPlugin] Compiling services: 23% building (2/8 entries 121/300 dependencies 5/97 modules) 
⇢ [LoggerPlugin] Compiling services: 23% building (2/8 entries 764/900 dependencies 34/296 modules) 
⇢ [LoggerPlugin] Compiling services: 23% building (2/8 entries 1262/1300 dependencies 60/443 modules) 
⇢ [LoggerPlugin] Compiling services: 23% building (2/8 entries 2165/2339 dependencies 142/800 modules) 
⇢ [LoggerPlugin] Compiling services: 23% building (2/8 entries 2600/2670 dependencies 150/1160 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 2914/3200 dependencies 265/1229 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 4670/4749 dependencies 386/1554 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 5931/6000 dependencies 544/1857 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 6789/6900 dependencies 758/2019 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 7122/7300 dependencies 789/2097 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 7177/7400 dependencies 791/2097 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 7600/7681 dependencies 833/2193 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 8785/9100 dependencies 840/2408 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 9755/9800 dependencies 902/2616 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 11035/11400 dependencies 1210/2747 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 12033/12200 dependencies 1312/3124 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 12841/13000 dependencies 1439/3237 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 13824/14000 dependencies 1506/3348 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 14963/15000 dependencies 1570/3531 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 16577/16700 dependencies 1664/3673 modules) 
⇢ [LoggerPlugin] Compiling services: 30% building (3/8 entries 17650/17800 dependencies 1815/3759 modules) 
⇢ [LoggerPlugin] Compiling services: 34% building (3/8 entries 18924/19119 dependencies 2200/3900 modules) 
⇢ [LoggerPlugin] Compiling services: 37% building (3/8 entries 20475/20500 dependencies 2456/4073 modules) 
⇢ [LoggerPlugin] Compiling services: 38% building (3/8 entries 21200/21290 dependencies 2578/4176 modules) 
⇢ [LoggerPlugin] Compiling services: 39% building (3/8 entries 21839/21900 dependencies 2646/4510 modules) 
⇢ [LoggerPlugin] Compiling services: 41% building (3/8 entries 23519/23700 dependencies 2829/4669 modules) 
⇢ [LoggerPlugin] Compiling services: 44% building (3/8 entries 25071/25300 dependencies 3098/4874 modules) 
⇢ [LoggerPlugin] Compiling services: 47% building (3/8 entries 26319/26400 dependencies 3417/4935 modules) 
⇢ [LoggerPlugin] Compiling services: 51% building (3/8 entries 27447/27600 dependencies 3790/5039 modules) 
⇢ [LoggerPlugin] Compiling services: 53% building (3/8 entries 28757/28800 dependencies 4066/5178 modules) 
⇢ [LoggerPlugin] Compiling services: 55% building (3/8 entries 29881/30000 dependencies 4339/5289 modules) 
⇢ [LoggerPlugin] Compiling services: 56% building (3/8 entries 30700/30895 dependencies 4590/5381 modules) 
⇢ [LoggerPlugin] Compiling services: 59% building (4/8 entries 31740/32291 dependencies 5050/5560 modules) 
⇢ [LoggerPlugin] Compiling services: 57% building (5/8 entries 32314/32600 dependencies 5118/5873 modules) 
⇢ [LoggerPlugin] Compiling services: 64% building (52/53 entries 34977/34978 dependencies 6309/6310 modules) 
⇢ [LoggerPlugin] Compiling services: 65% building (53/53 entries 34978/34978 dependencies 6310/6310 modules) 
✖ [DevServer] File NotificationsService.js for services not found in compilation assets {
  reqId: 'req-9',
  err: {
    type: 'Error',
    message: 'File NotificationsService.js for services not found in compilation assets',
    stack: 'Error: File NotificationsService.js for services not found in compilation assets\n' +
      '    at /Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:156:20\n' +
      '    at /Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:70:52\n' +
      '    at Array.forEach (<anonymous>)\n' +
      '    at callPendingResolvers (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:70:32)\n' +
      '    at Worker.<anonymous> (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack/dist/webpack/Compiler.js:91:9)\n' +
      '    at Worker.emit (node:events:513:28)\n' +
      '    at MessagePort.<anonymous> (node:internal/worker:233:53)\n' +
      '    at [nodejs.internal.kHybridDispatch] (node:internal/event_target:731:20)\n' +
      '    at exports.emitMessage (node:internal/per_context/messageport:23:28)'
  }
} 
ℹ [DevServer] File NotificationsService.js for services not found in compilation assets {
  reqId: 'req-9',
  res: { statusCode: 404 },
  err: {
    type: 'NotFoundError',
    message: 'File NotificationsService.js for services not found in compilation assets',
    stack: 'NotFoundError: File NotificationsService.js for services not found in compilation assets\n' +
      '    at Object.notFound (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/lib/httpErrors.js:37:12)\n' +
      '    at _Reply.notFound (/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@fastify/sensible/index.js:50:42)\n' +
      '    at Object.handler (file:///Users/krzysztofzaluski/Documents/react-native/Project/node_modules/@callstack/repack-dev-server/dist/plugins/compiler/compilerPlugin.js:66:22)',
    status: 404,
    statusCode: 404,
    expose: true
  }
} 
ℹ [DevServer] GET 404 /services/NotificationsService.js request completed { responseTime: 80040.01554203033 } 
⇢ [LoggerPlugin] Compiling services: 98% emitting (after emit) 
✖ [LoggerPlugin] Failed to build bundle due to errors 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Alert/Alert.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Alert' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Alert/Alert.js": Module not found: Error: Can't resolve './RCTAlertManager' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Alert' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/Animated.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/NativeAnimatedHelper.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/components/AnimatedImage.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/components/AnimatedScrollView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/nodes/AnimatedColor.js": Module not found: Error: Can't resolve '../../StyleSheet/PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/nodes' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/nodes/AnimatedStyle.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated/nodes' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Animated/shouldUseTurboAnimatedModule.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Animated' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/AppState/AppState.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/AppState' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/AccessibilityInfo' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/AccessibilityInfo/AccessibilityInfo.js": Module not found: Error: Can't resolve './legacySendAccessibilityEvent' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/AccessibilityInfo' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ActivityIndicator/ActivityIndicator.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ActivityIndicator' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Button.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Keyboard/Keyboard.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Keyboard' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Keyboard/KeyboardAvoidingView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Keyboard' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Pressable/useAndroidRippleForView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Pressable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/RefreshControl/RefreshControl.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/RefreshControl' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/SafeAreaView/SafeAreaView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/SafeAreaView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollViewNativeComponent.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/ScrollViewStickyHeader.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/ScrollView/processDecelerationRate.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/ScrollView' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/StatusBar/StatusBar.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/StatusBar' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Switch/Switch.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Switch' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/InputAccessoryView.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/TextInput.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/TextInput/TextInputState.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/TextInput' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/Touchable.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableHighlight.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableNativeFeedback.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/Touchable/TouchableOpacity.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/Touchable' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Components/View/ViewNativeComponent.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Components/View' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/Devtools/loadBundleFromServer.js": Module not found: Error: Can't resolve '../../Network/RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core/Devtools' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/ReactNativeVersionCheck.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/setUpDeveloperTools.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Core/setUpReactDevTools.js": Module not found: Error: Can't resolve '../DevToolsSettings/DevToolsSettingsManager' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Core' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/EventEmitter/NativeEventEmitter.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/EventEmitter' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Image/AssetSourceResolver.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Image' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Image/ImageBackground.js": Module not found: Error: Can't resolve './Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Image' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Inspector/Inspector.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Inspector' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LayoutAnimation/LayoutAnimation.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LayoutAnimation' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Linking/Linking.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Linking' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Lists/FlatList.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Lists' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Lists/SectionList.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Lists' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/LogBox.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorCodeFrame.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorHeader.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorHeader.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorReactFrames.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxInspectorStackFrame.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/LogBox/UI/LogBoxNotification.js": Module not found: Error: Can't resolve '../../Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/LogBox/UI' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Modal/Modal.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Modal' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NativeComponent/PlatformBaseViewConfig.js": Module not found: Error: Can't resolve './BaseViewConfig' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NativeComponent' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NativeComponent/ViewConfigIgnore.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NativeComponent' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Network/XMLHttpRequest.js": Module not found: Error: Can't resolve './RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Network' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NewAppScreen/components/DebugInstructions.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NewAppScreen/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/NewAppScreen/components/ReloadInstructions.js": Module not found: Error: Can't resolve '../../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/NewAppScreen/components' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/PermissionsAndroid/PermissionsAndroid.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/PermissionsAndroid' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Pressability/HoverState.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Pressability' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Pressability/Pressability.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Pressability' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/PushNotificationIOS/PushNotificationIOS.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/PushNotificationIOS' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/BridgelessUIManager.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/PaperUIManager.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactNative/renderApplication.js": Module not found: Error: Can't resolve '../Utilities/BackHandler' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactNative' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactPrivate/ReactNativePrivateInterface.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactPrivate' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/ReactPrivate/ReactNativePrivateInterface.js": Module not found: Error: Can't resolve '../Components/AccessibilityInfo/legacySendAccessibilityEvent' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/ReactPrivate' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Share/Share.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Share' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/normalizeColor.js": Module not found: Error: Can't resolve './PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/processColor.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/StyleSheet/processColor.js": Module not found: Error: Can't resolve './PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/StyleSheet' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Text/Text.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Text' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Utilities/Appearance.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Utilities' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Utilities/DevSettings.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Utilities' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/Vibration/Vibration.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/Vibration' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/WebSocket/WebSocket.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/WebSocket' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/Libraries/WebSocket/WebSocketInterceptor.js": Module not found: Error: Can't resolve '../Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/Libraries/WebSocket' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Image/Image' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Utilities/BackHandler' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Network/RCTNetworking' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/index.js": Module not found: Error: Can't resolve './Libraries/StyleSheet/PlatformColorValueTypes' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native' 
✖ [LoggerPlugin] Error in "./node_modules/react-native/src/private/specs/modules/NativeExceptionsManager.js": Module not found: Error: Can't resolve '../../../../Libraries/Utilities/Platform' in '/Users/krzysztofzaluski/Documents/react-native/Project/node_modules/react-native/src/private/specs/modules' 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 134/186 dependencies 5/103 modules) 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 755/900 dependencies 34/290 modules) 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 1954/2000 dependencies 95/782 modules) 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 2065/2300 dependencies 119/809 modules) 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 2639/2700 dependencies 163/1170 modules) 
⇢ [LoggerPlugin] Compiling src/services: 23% building (2/8 entries 3137/3400 dependencies 270/1303 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 4991/5042 dependencies 473/1552 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 6510/6700 dependencies 733/1940 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 6864/7000 dependencies 769/2033 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 7155/7300 dependencies 810/2062 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 7846/7900 dependencies 877/2253 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 9100/9742 dependencies 896/2489 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 10358/10500 dependencies 943/2693 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 11075/11700 dependencies 1206/2758 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 12875/12900 dependencies 1412/3230 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 14140/14300 dependencies 1573/3460 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 14765/14900 dependencies 1608/3569 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 15654/16200 dependencies 1696/3618 modules) 
⇢ [LoggerPlugin] Compiling src/services: 30% building (3/8 entries 17789/17900 dependencies 1862/3782 modules) 
⇢ [LoggerPlugin] Compiling src/services: 34% building (3/8 entries 19251/19300 dependencies 2222/3924 modules) 
⇢ [LoggerPlugin] Compiling src/services: 37% building (3/8 entries 20508/20600 dependencies 2489/4087 modules) 
⇢ [LoggerPlugin] Compiling src/services: 38% building (3/8 entries 21100/21393 dependencies 2622/4117 modules) 
⇢ [LoggerPlugin] Compiling src/services: 40% building (3/8 entries 22802/23000 dependencies 2746/4617 modules) 
⇢ [LoggerPlugin] Compiling src/services: 41% building (3/8 entries 23818/24200 dependencies 2891/4687 modules) 
⇢ [LoggerPlugin] Compiling src/services: 44% building (3/8 entries 25336/25600 dependencies 3149/4869 modules) 
⇢ [LoggerPlugin] Compiling src/services: 46% building (3/8 entries 26135/26300 dependencies 3307/4927 modules) 
⇢ [LoggerPlugin] Compiling src/services: 51% building (3/8 entries 27751/27900 dependencies 3830/5061 modules) 
⇢ [LoggerPlugin] Compiling src/services: 53% building (3/8 entries 28769/29100 dependencies 4051/5178 modules) 
⇢ [LoggerPlugin] Compiling src/services: 55% building (3/8 entries 29939/30100 dependencies 4386/5289 modules) 

...

I had to cut the logs because of character limitations but anyway after that it starts again to compile [LoggerPlugin] Compiling webpack:///src/services... and over and over the same logs appear.

Here in that example I just for testing purposes try to access non-existing parameter from some object in our NotificationService, but it's just example, any other error can cause that like unhandled promise rejection or using non-existing parameter in method.

Do you have any ideas how to handle it and why it's thrown?

jbroma commented 2 months ago

@krzysztofzaluski any chance for a repro?

The only thing I can see from the description and logs is that somehow filename gets passed to the ProgressPlugin as platform - it's hard for me to find the root cause of that without a repro. Not to mention the time it would cause using this method. If you care about fixing this please create a minimal reproduction repository so we can address this issue, thanks!

krzysztofzaluski commented 2 months ago

@jbroma I will try to prepare a repro repository and let you know

krzysztofzaluski commented 1 month ago

hey @jbroma we tried that canary version with fix: https://www.npmjs.com/package/@callstack/repack/v/4.4.0-canary-20240909082848 but now we have an issue that every small change in app turns to whole app restart here is a repository where you can see it: https://github.com/krzysztofzaluski/ReactNativeRepackProject repo contains two branches:

could you take a look?

jbroma commented 1 month ago

@krzysztofzaluski FYI this feature should be available with the next alpha release of Re.Pack 5.0 this week