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.48k stars 110 forks source link

[v5] Application crashes on open with reanimated babel plugin #796

Open ceopaludetto opened 4 days ago

ceopaludetto commented 4 days ago

Describe the bug

I'm trying to use the new version of repack with rspack, but I'm not sure if I've setup reanimated babel plugin correctly. Right know with my current configuration the application crashes on open (on both iOS and Android).

https://github.com/user-attachments/assets/056655b4-ed13-4f87-9b7e-2d08cabe6169

I've tried to setup with babel-loader after swc-loader. I also tried to run the application in release mode, but always crash.

System Info

System:
  OS: macOS 15.1
  CPU: (10) arm64 Apple M1 Pro
  Memory: 806.19 MB / 16.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 22.9.0
    path: ~/.local/share/mise/installs/node/22.9.0/bin/node
  Yarn: Not Found
  npm:
    version: 10.8.3
    path: ~/.local/share/mise/installs/node/22.9.0/bin/npm
  Watchman: Not Found
Managers:
  CocoaPods:
    version: 1.16.2
    path: /opt/homebrew/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.1
      - iOS 18.1
      - macOS 15.1
      - tvOS 18.1
      - visionOS 2.1
      - watchOS 11.1
  Android SDK:
    API Levels:
      - "33"
      - "34"
      - "35"
    Build Tools:
      - 30.0.3
      - 33.0.1
      - 34.0.0
      - 35.0.0
    System Images:
      - android-34 | Google APIs ARM 64 v8a
      - android-35 | Google Play ARM 64 v8a
      - android-TiramisuPrivacySandbox | Google Play ARM 64 v8a
    Android NDK: Not Found
IDEs:
  Android Studio: 2024.2 AI-242.23339.11.2421.12550806
  Xcode:
    version: 16.1/16B40
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 21.0.3
    path: /Users/carlos/.local/share/mise/installs/java/corretto-21.0.3.9.1/bin/javac
  Ruby:
    version: 2.6.10
    path: /usr/bin/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react: Not Found
  react-native: Not Found
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

Re.Pack Version

5.0.0-rc.1

Reproduction

https://github.com/ceopaludetto/repack-repro-reanimated

Steps to reproduce

  1. Clone repro
  2. Install packages (I've used bun, but I think it doesn't matter)
  3. Run expo prebuild
  4. Run expo run:android --no-bundler or expo run:ios --no-bundler
  5. Start rspack with react-native start --reset-cache
  6. Open the application
ceopaludetto commented 4 days ago

Related https://github.com/callstack/repack/issues/754#issuecomment-2455134956