expo-dev-launcher plugin inject code to AppDelegate everytime when run prebuild
See original GitHub issueSummary
I created an expo v44 project and installed expo-dev-client
,
when I runned expo prebuild -p ios
multiple times, I found that this code was inject repeatly:
I found the issue may caused by expo-dev-launcher, the extra
$&
made appDelegate.includes(DEV_LAUNCHER_APP_DELEGATE_ON_DEEP_LINK)
always return false
?
Managed or bare workflow? If you have made manual changes inside of the ios/
or android/
directories in your project, the answer is bare!
managed
What platform(s) does this occur on?
iOS
Package versions
expo-dev-client: “~0.8.4”
Environment
expo-env-info 1.0.2 environment info: System: OS: macOS 12.2.1 Shell: 5.8 - /bin/zsh Binaries: Node: 14.19.0 - ~/.nvm/versions/node/v14.19.0/bin/node npm: 6.14.16 - ~/.nvm/versions/node/v14.19.0/bin/npm Watchman: 2021.06.07.00 - /opt/homebrew/bin/watchman Managers: CocoaPods: 1.10.2 - /opt/homebrew/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.2, iOS 15.2, macOS 12.1, tvOS 15.2, watchOS 8.3 Android SDK: API Levels: 29, 30, 31 Build Tools: 29.0.2, 31.0.0 System Images: android-30 | Google Play Intel x86 Atom_64, android-31 | Google Play ARM 64 v8a IDEs: Android Studio: Arctic Fox 2020.3.1 Patch 4 Arctic Fox 2020.3.1 Patch 4 Xcode: 13.2.1/13C100 - /usr/bin/xcodebuild npmPackages: expo: ~44.0.0 => 44.0.6 react: 17.0.1 => 17.0.1 react-dom: 17.0.1 => 17.0.1 react-native: 0.64.3 => 0.64.3 react-native-web: 0.17.1 => 0.17.1 npmGlobalPackages: eas-cli: 0.47.0 expo-cli: 5.3.0 Expo Workflow: managed
Reproducible demo
expo init
npm i expo-dev-client
expo prebuild -p ios
# run this command multiple times
view your AppDelegate.m
file, you will find this code exists multiple times, it should only exist once
#if defined(EX_DEV_LAUNCHER_ENABLED)
if ([EXDevLauncherController.sharedInstance onDeepLink:url options:options]) {
return true;
}
Stacktrace (if a crash is involved)
No response
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (5 by maintainers)
thanks for submitting this issue! looks like I was able to reproduce this as you’ve described, so we’ll have a fix for this in the next release – I don’t think this should impact your app other than being an annoying bit of extra boilerplate
This issue was closed because it has been inactive for 7 days since being marked as stale. Please open a new issue if you believe you are encountering a related problem.