diff --git a/docs/getting-started/troubleshooting/android.mdx b/docs/getting-started/troubleshooting/android.mdx index ac398a932..ad15af9f4 100644 --- a/docs/getting-started/troubleshooting/android.mdx +++ b/docs/getting-started/troubleshooting/android.mdx @@ -2,11 +2,30 @@ id: android title: Troubleshooting Android Issues sidebar_label: Android Issues -custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/android.mdx +custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/getting-started/troubleshooting/android.mdx --- +import InternalAndroid from './fb/_android.mdx'; + Flipper is a work in progress and issues may occur. This page contains known issues associated with the Android platform and provides steps you can take to try to resolve them. + + + + +## In-app diagnostics +The Flipper SDK includes an in-app connection diagnostics screen to help you diagnose problems. + +Replace `` below with the package name of your app, for example, such as `com.facebook.flipper.sample`. + +On a terminal, run the following: + +```bash +adb shell am start -n /com.facebook.flipper.android.diagnostics.FlipperDiagnosticActivity +``` + +This will only work if you added `FlipperDiagnosticActivity` to your `AndroidManifest.xml`. See [getting started](./getting-started/android-native.mdx#diagnostics) for help. + ## Exception from call site #4 bootstrap method Build error after including the Flipper dependency: @@ -61,3 +80,5 @@ implementation("com.facebook.react:react-native:+") { exclude group:'com.facebook.fbjni' } ``` + + diff --git a/docs/getting-started/troubleshooting/general-issues.mdx b/docs/getting-started/troubleshooting/general-issues.mdx deleted file mode 100644 index 4cd4e3dd6..000000000 --- a/docs/getting-started/troubleshooting/general-issues.mdx +++ /dev/null @@ -1,146 +0,0 @@ ---- -id: general-issues -title: General Issues -sidebar_label: General Issues -custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/general-issues.mdx ---- - -:::note -There is a public build of Flipper and an internal one. The internal app provides more plugins and earlier access to features, so you should use it. - -The latest version of Flipper also has an interactive, self-navigating troubleshooting guide button. Please check that out to help you troubleshoot issues specific to your case. -::: - -## Internal Meta releases - -The internal build of Flipper has some extra features that the open source one doesn't. To get the latest version, please install Flipper from the Managed Software Centre rather than the Flipper website. - -## Up to date mobile app and Flipper version - -Occasionally there are breaking protocol changes, so if you're having trouble, make sure the app you're building is rebased relatively recently onto stable and that the flipper version is also up to date. - -## In-app diagnostics - -### Android - -Run the following: - -```bash -adb shell am start -n /com.facebook.flipper.android.diagnostics.FlipperDiagnosticActivity -``` - -For example, for an FB4A debug build, run: -`adb shell am start -n com.facebook.wakizashi/com.facebook.flipper.android.diagnostics.FlipperDiagnosticActivity`. - -Or open Flipper Diagnostics from the internal settings, which is available in some apps. - -### iOS - -Diagnostics have been added to the Internal Settings of the biggest apps. - -Navigate to `Internal settings > Troubleshooting Flipper (Sonar)` - -## iOS App in physical device not connecting to Flipper? idb permission issues? - -This may be because the app you're trying to connect to is signed by an enterprise certificate. If you've downloaded the builds from Mobile Home or the Mobile Builds Plugin, then the app is signed by enterprise certificates. If the app is built locally, then it's signed by developer certificates and idb can access the app's sandbox. - -Flipper does not support all the apps signed by enterprise certificates. Have a look at the following matrix to see, if your app is supported. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Built LocallyMobile Home/Boilerroom builds/builds signed by enterprise certificates
FB Supported only by WWW cert exchange mode
IGSupported only by WWW cert exchange mode
Messenger Not Supported
Workplace Not Supported
Workchat Not Supported
Other iOS AppsSupported if Flipper SDK is integrated Not Supported
- -In the above table: - -* If your app is supported and the cell contains 'Supported only by WWW certificate exchange', then you will have to do the following: - - * Ensure both Flipper and your mobile app are connected to Lighthouse. - * In your mobile app, go to Internal Setting -> "Flipper Certificate Exchange", enable the toggle. - * Your app will get connected now. - -* If your app falls in the red zone, then you can enable the WWW certificate exchange for your app by following [this guide](/docs/fb/www-certificate-exchange). - -## Physical SELinux-based device (think Portal) cannot connect - -A definitive sign of the issue is if you see `avc: denied ...` in the device logs. - -Try running the following: - -```bash -adb root -adb shell setenforce 0 -``` - -## Only Logs, Layout and Network plugins showing - -You're probably using the public build of Flipper. Instead, download the internal one from [Flipper Support](https://fb.facebook.com/groups/230455004101832/permalink/470961366717860/). - -## iOS Simulator not shown in device list - -Ensure that `ps aux | grep CoreSimulator` and `xcode-select -p` have the same Xcode version. If not, update the xcode version by sudo `xcode-select --switch ` - -If it still doesn't function, then post the details in the [Flipper Support](https://fb.facebook.com/groups/230455004101832/) Workplace group. - -## Launcher can't download - -Flipper downloads need to happen either while on Lighthouse or a VPN connection. To check the status of your connection, visit [bunny i vlaninfo](https://www.internalfb.com/intern/vlaninfo). - -## Prefetch unsupported - -You may see a message on your terminal about prefetch being unsupported. This means you downloaded Flipper manually and moved it into your `/Applications/` folder. Installing Flipper this way is unsupported. Not -only may it be missing important plugins for your work at Meta but will also never receive updates and is likely to stop working at some point in the future as the apps receive updates. - -Please manually remove `/Applications/Flipper.app` and reinstall Flipper from the [Managed Software Center](https://www.internalfb.com/intern/wiki/Client_Platform_Engineering/Users/Managed_Software_Center_(MSC)/). - -## Android app remains in status 'Currently connecting...' status forever - -Verify that the application has the right permissions to read the certificates that are used to connect to Flipper (see this Flipper Support [thread](https://fb.workplace.com/groups/flippersupport/permalink/1062569534223704/)). - -Try running `adb root && adb shell setenforce 0` as a workaround. - -## React Native plugins do not show up for my on-demand running mobile app - -1. Make sure that the 'JavaScript bundler' is running in the 'React Native' section of the Mobile Development plugin. -2. Take the following steps to ensure that the tunnel for port 8081 is connected in the 'Port Tunnels' section as it might incorrectly report that it's connected (see the following [bug](https://www.internalfb.com/intern/bugs/user/100003692117643/)): - - * Press connect. - * Perform DUO authentication. - * Verify that the terminal reports that the tunnel was created successfully. If it reports 'cannot listen to port 8081', make sure to kill any local processes on that port and try again: `kill -9 $(lsof -t -i tcp:8081)`. diff --git a/docs/getting-started/troubleshooting/mac-desktop-app.mdx b/docs/getting-started/troubleshooting/general.mdx similarity index 52% rename from docs/getting-started/troubleshooting/mac-desktop-app.mdx rename to docs/getting-started/troubleshooting/general.mdx index 3d166b826..8ffde71db 100644 --- a/docs/getting-started/troubleshooting/mac-desktop-app.mdx +++ b/docs/getting-started/troubleshooting/general.mdx @@ -1,18 +1,22 @@ --- -id: mac-desktop-app -title: Troubleshooting Mac Desktop App Issues -sidebar_label: Mac Desktop App Issues -custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/mac-desktop-app.mdx +id: general +title: Troubleshooting General Issues +sidebar_label: General Issues +custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/getting-started/troubleshooting/general.mdx --- +import InternalGeneral from './fb/_general.mdx'; + Flipper is a work in progress and issues may occur. This page contains known issues associated with the Mac desktop apps and provides steps you can take to try to resolve them. + + ## Flipper won't launch on Mac * If the window is appearing, try opening the Chrome DevTools within Flipper. To do so, from the View menu select 'Toggle Developer Tools' or press CMD+Option+I and check if there are any errors on the console. * Launch Flipper from the command line using `/Applications/Flipper.app/Contents/MacOS/Flipper`. This should give you some logs, that might be helpful when debugging. * Delete `~/.flipper` and try relaunching Flipper. -* Delete Flipper from your applications folder and redownload [Flipper](https://www.facebook.com/fbflipper/public/mac). +* Delete Flipper from your applications folder and [re-install it](../index.mdx#installation). * If you're using `yarn start` to run from source, make sure all dependencies are installed correctly by running yarn install. ## Flipper shows weird render artifacts @@ -20,22 +24,6 @@ Flipper is a work in progress and issues may occur. This page contains known iss This is a long standing MacOS + Electron issue outside our control. In general, restarting your computer fixes the problem. For a quick, temporarily work around start Flipper with hardware acceleration disabled. Please note that this will consume a lot of CPU: `FLIPPER_DISABLE_GPU=1 open -a Flipper`. -## iOS Simulator fails to connect with error "Failed to find device..." - -Try executing `idb kill` and restarting Flipper. See [this comment](https://fb.workplace.com/groups/flippersupport/posts/1288502608297061/?comment_id=1290222721458383&reply_comment_id=1290374518109870) for details. - -## iOS Simulator missing from devices dropdown - -* Check that `xcode-select -p` shows the same XCode version that you're using. If not, see xcode-select for how to select the correct version. - -## iOS physical device not showing up - -Make sure [`idb`](https://fbidb.io/docs/installation) is installed and configured in the Flipper settings. - -## App on physical iOS device stuck in 'connecting...' state - -Make sure you are building and installing the application from source. - ## No plugins showing up for your device * Check your device isn't on the list of [known incompatibilities](#known-incompatibilities). @@ -47,36 +35,9 @@ Make sure you are building and installing the application from source. * Make sure the time and date are set correctly on your mobile device and desktop computer. * If no app plugins are showing up, there may be a connectivity issue between Flipper and your app. Check [connection issues](#connection-issues) to see if anything is failing. - - -## Connection Issues -The Flipper SDK includes an in-app connection diagnostics screen to help you diagnose problems. - -### Android - -Replace `` below with the package name of your app, for example, such as `com.facebook.flipper.sample`. - -On a terminal, run the following: - -```bash -adb shell am start -n /com.facebook.flipper.android.diagnostics.FlipperDiagnosticActivity -``` - -This will only work if you added `FlipperDiagnosticActivity` to your `AndroidManifest.xml`. See [getting started](./getting-started/android-native.mdx#diagnostics) for help. - -### iOS - -You'll need to manually add this [ViewController](https://github.com/facebook/flipper/blob/main/iOS/FlipperKit/FlipperDiagnosticsViewController.m) to your app to see the in-app diagnostics. - - - ## Known Incompatibilities The following devices are known to be incompatible or face issues with Flipper: * Some Samsung devices ([Tracking Issue](https://github.com/facebook/flipper/issues/92)). * Genymotion emulators on Android 8+ are reported to have issues. - -## File an Issue - -Still not working? File an issue on [GitHub](https://github.com/facebook/flipper/issues) with the chrome DevTools logs and the output from the diagnostics screen, if relevant. diff --git a/docs/getting-started/troubleshooting/ios.mdx b/docs/getting-started/troubleshooting/ios.mdx new file mode 100644 index 000000000..d75b6cc0f --- /dev/null +++ b/docs/getting-started/troubleshooting/ios.mdx @@ -0,0 +1,33 @@ +--- +id: ios +title: Troubleshooting iOS Issues +sidebar_label: iOS Issues +custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/getting-started/troubleshooting/ios.mdx +--- + +import InternalIos from './fb/_ios.mdx'; + + + + + +## In-app diagnostics + +You'll need to manually add this [ViewController](https://github.com/facebook/flipper/blob/main/iOS/FlipperKit/FlipperDiagnosticsViewController.m) to your app to see the in-app diagnostics. + +## iOS device not showing up + +- Make sure [`idb`](https://fbidb.io/docs/installation) is installed and configured in the Flipper settings. + + + +## iOS simulator device not showing up + +Ensure that your simulator is on the same version as selected in `xcode-select`. +You can do that by checking that commands `ps aux | grep CoreSimulator` and `xcode-select -p` shows the same Xcode version. +If not, update the xcode version by sudo `xcode-select --switch ` + +## iOS app connection error "Connection failed. Failed to find device..." + +If during connecting iOS app to Flipper you see error message "Connection failed. Failed to find device while trying to connect app" - +try executing `idb kill` on a terminal and restarting Flipper as workaround to reset idb state. diff --git a/docs/getting-started/troubleshooting/portal.mdx b/docs/getting-started/troubleshooting/portal.mdx deleted file mode 100644 index bcd63c5b3..000000000 --- a/docs/getting-started/troubleshooting/portal.mdx +++ /dev/null @@ -1,15 +0,0 @@ ---- -id: portal -title: Troubleshooting Portal Issues -sidebar_label: Portal Issues -custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/portal.mdx ---- - -We've found that some portal devices running Android 10 fail to connect to Flipper by default. - -You can work around this by running the following on a terminal: - -``` -adb root -adb shell setenforce 0 -``` diff --git a/docs/getting-started/troubleshooting/react-native.mdx b/docs/getting-started/troubleshooting/react-native.mdx index 2110ac0b7..45eee1b7f 100644 --- a/docs/getting-started/troubleshooting/react-native.mdx +++ b/docs/getting-started/troubleshooting/react-native.mdx @@ -6,6 +6,8 @@ custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/mast --- import useBaseUrl from '@docusaurus/useBaseUrl'; +import InternalReactNative from './fb/_react-native.mdx'; + Flipper is a work in progress and issues may occur. This page contains known issues associated with React Native and provides steps you can take to try to resolve them. Make sure the project is using the [latest Flipper SDK](getting-started/react-native.mdx#using-the-latest-flipper-sdk). @@ -15,6 +17,10 @@ When using Flipper with React Native, two devices should show up: 1. **The 'React Native' device** - this is the "device" that talks to the Metro server and shows plugins that connect to or through Metro, such as the React DevTools, the Hermes Debugger and Metro logs. 2. **The device on which your app is running** - This is the device that Flipper connects to ADB / IDB. Flipper primarily support emulators and USB connected devices (examples: `SM760FS`, `Pixel 3`, `android_emulator`, and `iPhone 11`). + + + + ### I don't see the 'React Native' device 1. Make sure that the Metro server is running. @@ -147,3 +153,5 @@ To speed up CI builds, Flipper can be disabled on CI environments by making the end end ``` + + diff --git a/docs/getting-started/troubleshooting/troubleshooting.mdx b/docs/getting-started/troubleshooting/troubleshooting.mdx index b44ca685b..341062eb3 100644 --- a/docs/getting-started/troubleshooting/troubleshooting.mdx +++ b/docs/getting-started/troubleshooting/troubleshooting.mdx @@ -5,10 +5,19 @@ sidebar_label: Introduction custom_edit_url: https://www.internalfb.com/intern/diffusion/FBS/browsefile/master/xplat/sonar/docs/getting-started/troubleshooting/troubleshooting.mdx --- +import InternalTroubleshooting from './fb/_troubleshooting.mdx'; + Flipper is a work in progress and, as such, there's a chance that issues may occur while you're using it. The 'troubleshooting' section contains known issues that have occurred within various Flipper environments and the steps you can take if you encounter them. -If the information in this section doesn't help or if you encounter an issue that is not covered, please post the details in the [Flipper Support](https://fb.facebook.com/groups/230455004101832/) Workplace group first. + -Likewise, if you have a Flipper-related question, please post it in the [Flipper Support](https://fb.facebook.com/groups/230455004101832/) Workplace group. +## How to file an issue or ask a question? + +If you are still blocked after checking Troubleshooting guide you may file an issue on [GitHub](https://github.com/facebook/flipper/issues) +with the chrome DevTools logs and the output from the diagnostics screen, if relevant. + + + + diff --git a/website/sidebars.js b/website/sidebars.js index c9f845062..50c0d8ab1 100644 --- a/website/sidebars.js +++ b/website/sidebars.js @@ -62,11 +62,10 @@ module.exports = { { 'Troubleshooting': [ 'getting-started/troubleshooting/troubleshooting', - ...fbInternalOnly(['getting-started/troubleshooting/general-issues']), - 'getting-started/troubleshooting/mac-desktop-app', + 'getting-started/troubleshooting/general', 'getting-started/troubleshooting/android', + 'getting-started/troubleshooting/ios', 'getting-started/troubleshooting/react-native', - ...fbInternalOnly(['getting-started/troubleshooting/portal']), ], }, {