Commit Graph

25 Commits

Author SHA1 Message Date
Lorenzo Blasa
007cdfee76 Enable flipper import/export
Summary: These two functions were not enabled for the browser experience.

Reviewed By: antonk52

Differential Revision: D48315991

fbshipit-source-id: 2944a386d9de8a06b043305e7ceb8a6c41e11209
2023-08-14 11:33:06 -07:00
Lorenzo Blasa
daa3a38ed3 Flipper export file implementation
Summary:
^

Changelog: add export file implementation for browsers

Reviewed By: antonk52

Differential Revision: D46840341

fbshipit-source-id: 8a011f2a7c0ce329286cb8813def8f9c0572d133
2023-06-19 08:33:54 -07:00
Andrey Goncharov
778a56d7ac Create and upload a universal export when using the support request link
Summary: Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Reviewed By: passy

Differential Revision: D40586468

fbshipit-source-id: 4d6a8706c7d1cad1951bda701c51f0998c985628
2022-10-25 05:31:48 -07:00
Andrey Goncharov
14bdc87b11 Remove Flipper logs export menu
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

We have a universal export now. Why would we ask for logs only?

Reviewed By: passy

Differential Revision: D40553127

fbshipit-source-id: 674482e39746e789d70bf800daa5f021d83bb093
2022-10-25 05:31:48 -07:00
Andrey Goncharov
2289d6c0e2 Create a partial universal export in case of errors
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Attach what we can to the universal export file if any of the steps time out

CHANGELOG: Add a universal debug export button

Reviewed By: passy

Differential Revision: D40552235

fbshipit-source-id: 775afccacf053fbcf764d1f39e93a89ad20dee0a
2022-10-25 05:31:48 -07:00
Andrey Goncharov
80f947212b Add a modal with status updates for the universal export
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Exporting all files form a device and export Flipper's own state could take a long time. We need to keep our users updated on the status.

Reviewed By: passy

Differential Revision: D40551661

fbshipit-source-id: d5c94fb99d4bc8b4495ce463915b77c475548f01
2022-10-25 05:31:48 -07:00
Andrey Goncharov
96aa0ac02b Automatically export all plugins as a part of a universal export
Summary: Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Reviewed By: passy

Differential Revision: D40550440

fbshipit-source-id: 2f88c84124c35524d020fd2bcd8487dc2c64d8f3
2022-10-25 05:31:48 -07:00
Andrey Goncharov
6af6652ab2 Export data for the universal export as a single zip archive
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

It is better UX not to prompt a user multiple times to save various pieces of the debug export

Reviewed By: passy

Differential Revision: D40550084

fbshipit-source-id: 51ea3acee7daf5074682219020e1e1eed2182b7d
2022-10-25 05:31:48 -07:00
Andrey Goncharov
2db9bccf75 Export client logs for the active client as a part of the universal export
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Introduce a command rto fetch debug data from the devices

Reviewed By: passy

Differential Revision: D40470838

fbshipit-source-id: 40a7ec66b1266ceff1b31b5b4f19b93765b78615
2022-10-25 05:31:48 -07:00
Andrey Goncharov
ef0d9fb77e Export Flipper state as a part of the universal export
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Create Flipper export as a part on the universal export

Reviewed By: passy

Differential Revision: D40468242

fbshipit-source-id: b1b8e4df3b630c6163bb383482123c12dfc6e118
2022-10-25 05:31:48 -07:00
Andrey Goncharov
0e5af8095f Stash and export debug logs
Summary:
Design doc: https://docs.google.com/document/d/1HLCFl46RfqG0o1mSt8SWrwf_HMfOCRg_oENioc1rkvQ/edit#

Stash all logs including debug ones for the export

Reviewed By: lblasa

Differential Revision: D40467905

fbshipit-source-id: 963ce8e92d2131220640a63f5e9c38f4317af061
2022-10-25 05:31:48 -07:00
Andrey Goncharov
47956087ee Add a menu item to export Flipper logs to a file
Summary:
CHANGELOG: Add Flipper logs export to file

Allows users to export their Flipper logs with a single click. The export always includes all log levels but debug.

Reviewed By: antonk52

Differential Revision: D37485571

fbshipit-source-id: 82b02132794da30b255e6178db4a17c1ba8091ee
2022-06-28 06:27:43 -07:00
Andrey Goncharov
17ab7a86ef Use getRenderHost from flipper-frontned-core in flipper-ui-core
Summary: See D37139129

Reviewed By: lblasa

Differential Revision: D37236435

fbshipit-source-id: 927e9f741bfedb65165f5d24f0acfb775925cdc7
2022-06-20 12:18:40 -07:00
Andrey Goncharov
fd380a4c1e Use BaseDevice from flipper-frontend-core in flipper-ui-core
Summary: Use BasDevice definition from flipper-frontend-core in flipper-ui-core and remove the redundant definition from flipper-ui-core

Reviewed By: lblasa

Differential Revision: D37234785

fbshipit-source-id: 6e768090a197c1d2c49cb1cd573acea12fb65d24
2022-06-20 12:18:40 -07:00
Andrey Goncharov
ef5fa275a3 Use AbstractClient from flipper-frontend-core in fliper-ui-core
Summary: This stack attempts to start using flipper-frontend-core from flipper-ui-core. Currently, flipper-frontend-core contains lots of copy-pasted code from flipper-ui-core.

Reviewed By: lblasa

Differential Revision: D37139198

fbshipit-source-id: 042db7492c550e10ea72c32fd15001c141bf53f9
2022-06-20 12:18:40 -07:00
Pascal Hartig
b25a212890 Remove SupportRequestFormV2
Summary: This is now replaced by the support entry point and we need to delete the calling sites before we can clean up the everstore type.

Reviewed By: lawrencelomax

Differential Revision: D37090901

fbshipit-source-id: 597684bb149783d75e46ba61113e73878bf271a8
2022-06-13 07:16:47 -07:00
Andrey Goncharov
9113006851 Make Client initialize server add-ons
Reviewed By: mweststrate

Differential Revision: D34044353

fbshipit-source-id: 99bcb1559787b2a904bdd796233666a7a4783ea4
2022-02-28 03:50:34 -08:00
Andres Suarez
79023ee190 Update copyright headers from Facebook to Meta
Reviewed By: bhamodi

Differential Revision: D33331422

fbshipit-source-id: 016e8dcc0c0c7f1fc353a348b54fda0d5e2ddc01
2021-12-27 14:31:45 -08:00
Michel Weststrate
5df34a337c Unshare global types
Summary:
This diff adds `types` fields on the compiler config for every project. This way we can make sure that for example node types and packages are not available in flipper-ui-core. Without an explicit types field, all types would be shared between all packages, and implicitly included into the compilation of everything. For the same reason `types/index.d.ts` has been removed, we want to be intentional on which types are being used in which package.

This diff does most of the work, the next diff will fine tune the globals, and do some further cleanup.

As an alternative solution I first tried a `nohoist: **/node_modules/types/**` and make sure every package list explicitly the types used in package json, which works but is much more error prone, as for example two different react types versions in two packages will cause the most unreadable compiler error due to the types not being shared and not literally the same.

Reviewed By: lawrencelomax

Differential Revision: D33124441

fbshipit-source-id: c2b9d768f845ac28005d8331ef5fa1066c7e4cd7
2021-12-17 07:36:07 -08:00
Michel Weststrate
accef856fc Remove remaining Node imports from core
Summary:
Removed remaining path / fs imports from Flipper core.

`expand-tide` needed replacement too, but noticed that it never actually rewrites paths since all use cases were already using absolute paths, so removed it instead.

Reviewed By: aigoncharov

Differential Revision: D33017654

fbshipit-source-id: e12f66ef68b5f9e4279411c94445a2fb87249e9a
2021-12-13 05:48:17 -08:00
Michel Weststrate
943d535e86 Move sending intern requests from client to server
Summary: This diff moves send intern request from the browser to the server. The reason to make this change is that making such requests from a browser environment causes CORS restrictions to kick in.

Reviewed By: nikoant

Differential Revision: D32835449

fbshipit-source-id: e8e92e51ca963aa50b3c859bb61c2381171e85ae
2021-12-08 04:30:57 -08:00
Michel Weststrate
2b4981c7cb Remove remaing from 'os' imports
Summary: Per title.

Reviewed By: passy

Differential Revision: D32721206

fbshipit-source-id: 9e465d0ed60c0c6da33c462aa76468faac620626
2021-12-08 04:30:56 -08:00
Michel Weststrate
2a4fe77404 Extract environment config initialisation to server-core
Summary: This diff makes most stuff that is read from the `os` package, and version info etc available from the `serverConfig` object, so that flipper-ui-core no longer needs the `os` package.

Reviewed By: passy

Differential Revision: D32694848

fbshipit-source-id: 93af1e95d898da9aaf351a6970b5a7652ee835c8
2021-12-08 04:30:56 -08:00
Michel Weststrate
2bf8ae2364 Get rid of perf_hooks package in Flipper UI
Summary:
perf_hooks is no longer needed as these APIs are widely available in both browser and electron.

Still needed in unit tests, as they run from Node

Reviewed By: lblasa, aigoncharov

Differential Revision: D32648253

fbshipit-source-id: 5718ea99b57f96f6858311fd0815ad18c476c99e
2021-12-08 04:30:55 -08:00
Michel Weststrate
7e50c0466a Move app/src (mostly) to flipper-ui-core/src
Summary:
This diff moves all UI code from app/src to app/flipper-ui-core. That is now slightly too much (e.g. node deps are not removed yet), but from here it should be easier to move things out again, as I don't want this diff to be open for too long to avoid too much merge conflicts.

* But at least flipper-ui-core is Electron free :)
* Killed all cross module imports as well, as they where now even more in the way
* Some unit test needed some changes, most not too big (but emotion hashes got renumbered in the snapshots, feel free to ignore that)
* Found some files that were actually meaningless (tsconfig in plugins, WatchTools files, that start generating compile errors, removed those

Follow up work:
* make flipper-ui-core configurable, and wire up flipper-server-core in Electron instead of here
* remove node deps (aigoncharov)
* figure out correct place to load GKs, plugins, make intern requests etc., and move to the correct module
* clean up deps

Reviewed By: aigoncharov

Differential Revision: D32427722

fbshipit-source-id: 14fe92e1ceb15b9dcf7bece367c8ab92df927a70
2021-11-16 05:29:21 -08:00