Summary:
This diff is the first out of n for the troubleshooting guide for flipper.
What has been done -
- Defined a structure for the troubleshooting guide in TroubleshootingGuide.tsx (parent component ) to render children components or the individual questions from here.
- The initial screen of the trouble shooting guide along with the 3 sections of questions users face. Clicking them prompts to individual question screens that will be built in future diffs.
- Units tests in jest for the rendering of the screens and functions.
Reviewed By: mweststrate
Differential Revision: D30279739
fbshipit-source-id: 3e317b67e5ac461902c6779eaa584e1032741b85
Summary: Made a start with decoupling JS device. Incomplete as there are still Electron deps.
Reviewed By: timur-valiev
Differential Revision: D30309257
fbshipit-source-id: b8002170cbbe8d68e1795ce7c12ffce4c8eac853
Summary: Decoupled metro 'device' from Redux store. Extracting some commonalities with Android device management up into FlipperServer
Reviewed By: timur-valiev
Differential Revision: D30309256
fbshipit-source-id: 1a9ac01e3f21d2d08761554d3644a7ae8d00a93e
Summary: See earlier diffs in the stack. This diff decouple android device management from the Redux store, replacing it with specific events.
Reviewed By: timur-valiev
Differential Revision: D30286345
fbshipit-source-id: 42f52056bf123b862e2fc087f2e7130c02bdd742
Summary:
This diff takes care of current plugin status when handling deeplinks. It checks:
1. if the plugin failed to load
2. if the plugin is behind GK
3. if the plugin is installable from bundle
4. if the plugin is installable from marketplace
Reviewed By: passy
Differential Revision: D29875483
fbshipit-source-id: 8dac1aab63822f43a0d002b10efa5b4a756fce41
Summary: We're currently getting errors for every duplicate key and can't easily unify them, so we're adding the additional information to a warning instead.
Reviewed By: mweststrate
Differential Revision: D30337821
fbshipit-source-id: db9dc44d7d3424de169bed9b4447b482e411eb19
Summary:
This works for forwarded as well as local devices.
There is a bunch more unification work that needs to be done here as we currently have three completely different ways of querying iOS devices. More on that next week.
Reviewed By: jknoxville
Differential Revision: D30308405
fbshipit-source-id: c58ac73e971ce2cc4da92e9508bc05dff9c1a95a
Summary:
Moved all logic per device type we support to its own dir, including tools and utilities around it, which makes it easier to consolidate logic and decouple in turn per device type.
Per type, all logic can be found in
`server/devices/(desktop|metro|android|ios|webapp)`
Reviewed By: timur-valiev
Differential Revision: D30277817
fbshipit-source-id: 2b5339c363d5d31ceeba07cec03826fc67cf3748
Summary: This diff moves the first small pieces of getting device detection up and running to `server/`, and the wiring between FlipperServer and flipper core / redux is setting up specific events and dispatch actions from there.
Reviewed By: timur-valiev
Differential Revision: D30276776
fbshipit-source-id: b30b996d03c27459815bebeb97b05b5fe5d24bec
Summary: idb has a command for doing the same now.
Reviewed By: timur-valiev
Differential Revision: D30277192
fbshipit-source-id: eb46cdc7a7218077a7da90f6182d5f17bfcc758a
Summary:
This is the first of many diffs that extracts the connection, device, client detection out of the flipper core, to create a reusable flipper-server library that can be used in e.g. flipper-dump.
To keep diffs a little smaller, the current connection logic is first moved to the `server/` directory, and decoupled manually from the rest of the core, before moving it over to a separate package.
This first diffs moves the `comms/`, `devices/` and certificate utilities to the `server` directory.
Further untangling will follow in next diffs
Reviewed By: timur-valiev
Differential Revision: D30246551
fbshipit-source-id: c84259bfb1239119b3267a51b015e30c3c080866
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/2682
Run path-specific tests only on Unix-like OSes. We could
easily change the path to Windows, but honestly it's enough
to confirm this on one platform.
Reviewed By: timur-valiev
Differential Revision: D30255014
fbshipit-source-id: 7db36bc1738d721625e3c86c210d46dfaf8f0ab8
Summary: This turns the bridge type into a simpler struct with always-present methods so you don't need to add additional null check to the calling logic which are hard to deal with.
Reviewed By: mweststrate
Differential Revision: D30248628
fbshipit-source-id: cdaee44efcbb19dcbb301099b4a7d0eb0c350e67
Summary:
In order to support IOS cloud devices, we need to abstract
over the direct uses of idb/xcrun so we can switch them
out based on more than the device type.
Note that there's a bit of a type weirdness in there. I'll
clean this up with the next diff.
Reviewed By: mweststrate
Differential Revision: D30248036
fbshipit-source-id: ec8571429e04abe059850ef334a6645ae4a5e034
Summary:
The results are often unpredictable, poorly typed and we have
dependencies that do the wrapping for us.
Listen, I'll get to writing some real code soon, I promise,
but I need to clean up my workspace first, okay?
Reviewed By: mweststrate
Differential Revision: D30247484
fbshipit-source-id: f5326ff71ff43af2dc64ab85ca1368f95fe87083
Summary:
`electron.remote` access is slow so we can cache this
like we do in other places. Also means one fewer `electron`
import which is gonna add up for Flipper Decap.
Reviewed By: mweststrate
Differential Revision: D30247431
fbshipit-source-id: 90f0e8df99af8bed40fbebcfd445abaca2965b7c
Summary:
Error is handled, doesn't need a task. Also, prefix is wrong here
as it's used.
Reviewed By: mweststrate
Differential Revision: D30247416
fbshipit-source-id: 049490cb7e45b7ce6f433bf7366eb94893947625
Summary:
A few drive-by changes ahead of the sustainathon.
(More to come.)
Reviewed By: mweststrate
Differential Revision: D30247395
fbshipit-source-id: e707377a1169eb634a42f08c3d27fe3e065b63bb
Summary:
Got my first auto-created crashbot task. {emoji:1f973}
We do have some pretty granular handling for errors during disconnects but this one has fallen through the cracks.
I'm not 100% sure if this is the right way to handle it which is why I added mweststrate. :)
Reviewed By: mweststrate
Differential Revision: D30218833
fbshipit-source-id: 2b4c9201ee7faf1c278b1cc5268ad2648dc4c820
Summary: Introduce `Dialog.alert` to show users a FYI message, and be able to wait for it to be handled, as utility around several `Modal` utilities.
Reviewed By: jknoxville
Differential Revision: D29875484
fbshipit-source-id: 5d2ea83e486631ac18a81800b467f97dfaac6d34
Summary: Check if Flipper is up to date before handling deeplink.
Reviewed By: nikoant
Differential Revision: D29846236
fbshipit-source-id: 011d05958346c3d18c76cf0ae63c3cb087f5933c
Summary: First steps in smoother deeplink flow, where connection and login status is being checked before trying to handle the deeplink.
Reviewed By: lblasa
Differential Revision: D29790461
fbshipit-source-id: e1e42ceb5db59c695077f316e836f1f216c7204a
Summary: Excluding `react-virtual` which seems to include a breaking change with the patch release.
Reviewed By: jknoxville
Differential Revision: D30189687
fbshipit-source-id: b40cb5edd407fd03009ee38c0af5202c8deaaa26
Summary:
- This diff adds usage statistics for
- How often was the troubleshooting button opened
- What were its end states ( Problem solved or file a support request)
- I am using the tracked flipper plugin to obtain and analyse the stats on Infinity analytics events dev in Scuba backend.
(Since this is not yet productionized we are using the dev version now )
Reviewed By: nikoant
Differential Revision: D30098054
fbshipit-source-id: 871cc18872bccf70a829dc1dd173a337b02ec6e6
Summary:
- Added a dialogue with 2 possible end state buttons
- Problem Solved
- File Support Request
- This diff is the start of the implementation of the troubleshooting wizard.
- The previously implemented troubleshooting button (D29993355 (921a65bc17)) now links to a modal dialogue box.
- This is essentially the last screen of the troubleshooting guide to be implemented.
- We have options for a user to either select file a support request if the issue persists after navigating the guide or click on problem solved if the guide helped them solve it.
- Selecting option 2 (file support request) links to the pre-existing form
The modal has been implemented as an independent reusable component and can be easily extended.
Reviewed By: passy
Differential Revision: D30069270
fbshipit-source-id: f61bf8c03de786e11b7f06194328dbee703abf8b
Summary:
This change enables a WebSocket server if the user is on the 'flipper_websocket_server' GK.
I don't expect this change to make it as the final product of the entire solution. Instead, it can be used to quickly enable/disable WebSocket during development/testing without requiring any code changes.
Reviewed By: passy
Differential Revision: D30069694
fbshipit-source-id: 75daac75e6dad7f63cf194d8287971c33d3abb61
Summary:
This change addresses a problem with using data.id straight into the if statement.
If `data.id` is not undefined but has a value of 0 then the expression evaluates to false.
Right now, that wasn't the intended usage.
Using this change to also export some types from Client.
Reviewed By: passy
Differential Revision: D30069746
fbshipit-source-id: 04a8d161efceadf7a38ee556be70c15b45c11056
Summary: The markdown bump required ignoring another prop, the rest was smooth.
Reviewed By: timur-valiev
Differential Revision: D30067682
fbshipit-source-id: 6038ffe29d2e0041c81bac132eed747cbfe40f54
Summary:
- Minor change on Diff - D30040808
- Removed cyclic dependancy on AppSelector
- Previous dependancy chain : AppSelector -> TroubleshootingGuide -> AppSelector
- Now the NoDevices component that troubleshooting guide was importing has been moved to an independent file.
Reviewed By: passy
Differential Revision: D30041820
fbshipit-source-id: 17856aad7d2a569ec4e0f19e63f458472b22dcf8
Summary:
- Added a troubleshooting guide button which on clicking will open the expert chat bot system of flipper. ( Will be implemented in future diffs)
- This has been added only in the internal version of flipper available to FB.
- The public version shall continue to link to the troubleshooting guide for now.
- Also a new gatekeeper flipper_self_sufficiency was set up.
- This currently gives access to ongoing changes only to a few team members.
- In the future access shall be extended to the entire team, followed by the entire org and then finally all internal FB users in the final stages of the project.
Reviewed By: passy
Differential Revision: D29993355
fbshipit-source-id: afdb76baef6fde2c785c50ad6530ea2f76ce7284
Summary:
WebSocket implementation of ServerAdapter.
About the setup payload:
RSocket uses a setup payload sent by the client when the initial handshake takes place.
WebSocket handshake doesn't use one.
Instead, it is proposed to use the URL query string to embed any arguments that the server may require to correctly identify and verify a client.
This is the case for the existing Browser WebSocket server.
The only extra adjustment was made for the CSR, proposed to be Base64 encoded.
There's no particular reason to Base64 encode it, as it was already tested by simply escaping any necessary characters.
I feel Base64 adds a layer of simple obfuscation that although doesn't offer any security, it abstracts the content to the URL reader.
The only concern was about the URL maximum length. It seems to be accepted that URL lengths should be at most 2048 characters.
Also, it seems to be the case that the PEM encoded public key size is 451 characters.
That, combined with all the extra necessary arguments, the final URL seem to fit well within the 2048 characters limit.
Reviewed By: passy
Differential Revision: D30014341
fbshipit-source-id: f3e13754b9e513eb84473e45de03f9e101c73862
Summary:
This is the change that will pull the previous diffs together by making ServerController use the refactored components.
There are no logical changes.
The only additions are the ServerEventsListener interface implementation that re-use logic that was previously scattered around this same type.
Reviewed By: passy
Differential Revision: D29989270
fbshipit-source-id: 9ed7ff84ae8cd8ca46fad0db0737456eb705241c
Summary:
ServerController creates, configures, and contains any necessary servers to be used by Flipper.
ServerFactory is added as a means to abstract the creation of servers from it.
Reviewed By: passy
Differential Revision: D29987328
fbshipit-source-id: ff60a408710dbd51ea28ff27a9f85c0020741f4b
Summary:
Introduce a base class for WebSocket based servers and a Browser-based implementation which is in use by Kite.
The implementation for the Browser-based one is basically taken as is from ServerController but slightly adapted to match the existing interface.
As with the RSocket-based implementation, this diff doesn't put this implementation into use but is a good opportunity to revisit the existing implementation.
Reviewed By: passy
Differential Revision: D29985886
fbshipit-source-id: 32abba37ec31478b6497ef5cfe90bb9aedc282d3
Summary:
RSocket server which implements the ServerAdapter interface.
Most of the code was taken from the ServerController class with a few minor adjustments.
Once ServerController starts using ServerAdapter instances the code will be removed from there.
Reviewed By: fabiomassimo
Differential Revision: D29984578
fbshipit-source-id: e35e7635dff995314b3c1fbc85177f90384e025d
Summary:
Introduce ServerAdapter which should be used as a base class for different server implementations e.g. RSocket, WebSocket.
The type is not used elsewhere at this point but this is a good chance to look at the API and suggest changes and/or improvements.
Reviewed By: passy
Differential Revision: D29958434
fbshipit-source-id: 50ba46332d40e836b0a87bcf354d3237bf8fe7c5