Closed alechko closed 3 years ago
as a workaround I've removed flipper for now from the Podfile
Thanks @alechko -- I'll see if we can replicate this issue.
@alechko The generated package.json file in your existing project does not appear to be up to date with the latest ignite version 6.10.3 shown in your log of npx ignite-cli doctor
I matched your node version of 15.9.0 and removed any global installations of ignite-cli from my system, then tried to reproduce your issue. I was able to ignite a new app and run the iOS emulator without issues. Also, I started up Flipper 0.88.0 and verified that it was logging my session with the new app.
Here are my ignite-cli doctor
logs, my terminal session logs when igniting a new app, the scripts portion of the generated package.json in the new app, and the Flipper session:
System
platform darwin
arch x64
cpu 6 cores Intel(R) Core(TM) i5-9600K CPU @ 3.70GHz
directory foo /Users/derekgreenberg/git/foo
JavaScript (and globally-installed packages)
node 15.9.0 /Users/derekgreenberg/.nvm/versions/node/v15.9.0/bin/node
npm 7.5.3 /Users/derekgreenberg/.nvm/versions/node/v15.9.0/bin/npm
npm 7.5.3
yarn 1.22.5 /Users/derekgreenberg/.yarn/bin/yarn
pod-install 0.1.21
Ignite
ignite-cli 6.11.0 /Users/derekgreenberg/.npm/_npx/e31027f3785124a8/node_modules/.bin/ignite
ignite src build /Users/derekgreenberg/.npm/_npx/e31027f3785124a8/node_modules/ignite-cli/build
Android
java 1.8.0_232 /usr/bin/java
android home - /Users/derekgreenberg/Library/Android/sdk
iOS
xcode 12.5
cocoapods 1.10.1 /usr/local/bin/pod
Here is my session of igniting a new app:
~/git> npx ignite-cli new foo
Need to install the following packages:
ignite-cli
Ok to proceed? (y) y
· · · · · · · · · · · · · · · · · · 🔥 Ignite 🔥 · · · · · · · · · · · · · · · · · ·
█ Creating foo using Ignite 6.10.3
█ Powered by Infinite Red - https://infinite.red
█ Using react-native-cli
────────────────────────────────────────────────
🔥 Igniting app
🖨 3D-printing a new React Native app
☕️ Baking CocoaPods
🗄 Backing everything up in source control
Ignite CLI ignited foo in 26.14s
~/git/foo> cat package.json
{
"name": "foo",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "react-native start",
"test:e2e": "detox test -c ios.sim.debug",
"build:e2e": "detox build -c ios.sim.debug",
"ci:test:e2e": "detox test -c ios.sim.release -l verbose --cleanup",
"ci:build:e2e": "detox build -c ios.sim.release",
"compile": "tsc --noEmit -p . --pretty",
"format": "npm-run-all format:*",
"format:js": "prettier --write \"**/*.js\"",
"format:json": "prettier --write \"**/*.json\"",
"format:md": "prettier --write \"**/*.md\"",
"format:ts": "prettier --write \"**/*.ts{,x}\"",
"lint": "eslint index.js app storybook test --fix --ext .js,.ts,.tsx && yarn format",
"patch": "patch-package",
"storybook": "start-storybook -p 9001 -c ./storybook",
"test": "jest",
"adb": "adb reverse tcp:9090 tcp:9090 && adb reverse tcp:3000 tcp:3000 && adb reverse tcp:9001 tcp:9001 && adb reverse tcp:8081 tcp:8081",
"postinstall": "node ./bin/postInstall",
"build-ios": "react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios",
"build-android": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res",
"clean": "react-native-clean-project",
"clean-all": "npx react-native clean-project-auto"
},
~/git/foo> npx react-native run-ios
info Found Xcode workspace "foo.xcworkspace"
info Launching iPhone 12 (iOS 14.5)
info Building (using "xcodebuild -workspace foo.xcworkspace -configuration Debug -scheme foo -destination id=175E0639-34E8-4482-A253-BCC969ED1E28")
success Successfully built the app
info Installing "/Users/derekgreenberg/Library/Developer/Xcode/DerivedData/foo-fezwzfgpoewmemdsmxhgfaridmxo/Build/Products/Debug-iphonesimulator/foo.app"
info Launching "org.reactjs.native.example.foo"
success Successfully launched the app on the simulator
10:04:31.679
36527
foo
Invalidating <RCTCxxBridge: 0x7f8fc1508c00> (parent: <RCTBridge: 0x6000021956c0>, executor: (null))
10:04:32.105
36527
foo
Require cycle: app/navigators/index.ts -> app/navigators/main-navigator.tsx -> app/screens/index.ts -> app/screens/demo/demo-list-screen.tsx -> app/models/index.ts -> app/models/root-store/setup-root-store.ts -> app/models/environment.ts -> app/services/reactotron/index.ts -> app/services/reactotron/reactotron.ts -> app/navigators/index.ts
Require cycles are allowed, but can result in uninitializ
10:04:32.120
36527
foo
Running application foo ({
initialProps = {
};
rootTag = 11;
})
10:04:32.124
36527
foo
Running "foo" with {"rootTag":11,"initialProps":{}}
Let me know if any of the above is helpful and if there is anything else I can investigate to help you solve the issue with your app. Here is one solution you can try on an existing ignited app:
You may need to ensure your app is running react-native version 0.64.1 rather than 0.64.0 and you MAY have to replace this line in Podfile:
use_flipper!({ 'Flipper' => '0.75.1' })
With this line:
use_flipper!('Flipper' => '0.75.1', 'Flipper-Folly' => '2.5.3', 'Flipper-RSocket' => '1.3.1')
@derekgreenberg thanks, using use_flipper!('Flipper' => '0.75.1', 'Flipper-Folly' => '2.5.3', 'Flipper-RSocket' => '1.3.1')
in the Podfile worked!
as for the package.json and ignite, this is actually a two week old project, generated with npx ignite-cli generate
in the same manner you've suggested, in Apr 28, two weeks ago, I haven't updated anything since generating the project, so that's very weird to me that it stopped working all of a sudden.
I know for a fact that the only thing I've updated since generating the project is XCode to 12.5, so that might be somehow related.
Anyway, using the suggested setting for the Flipper builds successfully now, thanks again!
Existing ignite project fails to build with a Flipper error:
package.json:
current Flipper version (installed with brew): 0.88.0
Steps to reproduce
yarn ios
ignite doctor
results: