Summary:
This is a replacement for PR https://github.com/facebook/flipper/pull/1486 which had the wrong username
When the network plugin is loaded, the route table in the device is empty. It needs to be populated with whatever routes have already been created and saved in local storage. Otherwise, the user would need to modify the routes to force an update.
Issue is described here - https://github.com/facebook/flipper/issues/1476
## Changelog
Routes updated in device when plugin is initialized
Pull Request resolved: https://github.com/facebook/flipper/pull/1491
Test Plan:
1. Create a mock for the get request in the sample Android app
2. Kill the app
3. Start the app
4. Issue the get request in the app
5. Verify that the request is mocked in the Network plugin

Reviewed By: passy
Differential Revision: D23292355
Pulled By: mweststrate
fbshipit-source-id: 2fe16e9067a627cae02a4b1db422952d364fd036
Summary:
Changelog: Fixed react-native-flipper causing Android release builds to fail
https://github.com/facebook/flipper/issues/1325 made progress but did not quite fix https://github.com/facebook/flipper/issues/1303. Android Release builds would still fail because `PackageList` depended on `FlipperPackage` and couldn't find it in release builds. There doesn't appear to be a clear way to set up a debug-only package with React Native's Android autolinking (see https://github.com/react-native-community/cli/issues/1211), so this change creates an empty `FlipperPackage` to satisfy that dependency, while still avoiding bundling the Flipper library into the release build.
(manual linking also works, but seems less-desirable for consumers of the library)
## Changelog
Add an empty `FlipperPackage` to the `release` folder to satisfy the reference put in `PackageList` by the autolinker for release builds.
Pull Request resolved: https://github.com/facebook/flipper/pull/1329
Test Plan:
Verified that release builds did fail without this change (using ReactNativeFlipperExample app)
Successfully built a React Native Android Release app from Android Studio using this library and verified that the APK still did not contain Flipper. Built debug and verified that Flipper still worked as before.
Reviewed By: passy
Differential Revision: D23292543
Pulled By: mweststrate
fbshipit-source-id: cb897a0e6dcdc04e29d676596447ca9dd68182c8
Summary:
Bringing the pkd CPU usage fix to open source releases.
Now when idb is installed, Flipper will always use it to check for devices, and only fallback to instruments if not.
Fixes https://github.com/facebook/flipper/issues/1028
Reviewed By: passy
Differential Revision: D23293675
fbshipit-source-id: 6ff3e89167f5f6d4130f197b2a675202334d0e7d
Summary:
Fixes https://github.com/facebook/flipper/issues/1481
## Changelog
Fix symlinked scoped module resolving to outer directory
Pull Request resolved: https://github.com/facebook/flipper/pull/1482
Test Plan:
Added one more case to the existing test case for `getWatchFolders.ts`
```
❯ yarn run test:debug getWatchFolders
yarn run v1.22.4
$ yarn build:pkg && node --inspect node_modules/.bin/jest --runInBand getWatchFolders
$ cd pkg && yarn build
$ tsc -b
Debugger listening on ws://127.0.0.1:9229/41e16e0b-8a44-42fe-93ac-9dd9d06e418d
For help, see: https://nodejs.org/en/docs/inspector
PASS pkg-lib/src/__tests__/getWatchFolders.node.ts
getWatchFolders
✓ getWatchFolders correctly resolves symlinked packages (12 ms)
Test Suites: 1 passed, 1 total
Tests: 1 passed, 1 total
Snapshots: 1 passed, 1 total
Time: 2.358 s
Ran all test suites matching /getWatchFolders/i.
{emoji:2728} Done in 8.60s.
```
Reviewed By: mweststrate
Differential Revision: D23293357
Pulled By: nikoant
fbshipit-source-id: de2a506693727489238c6f6ec62d07526f8f0c69
Summary:
Documented all exposed Sandy APIs plugin developers should know about.
Honestly didn't proof-read it myself yet, but wanted to publish this diff at least before PTO, so that the information is available to anyone interested / playing with sandy
Reviewed By: jknoxville
Differential Revision: D22976373
fbshipit-source-id: c30918201d2feeb306ca0d9a3ae1ec10bdf7e2f5
Summary:
`scrollTo` used there caused the window to scroll to the most left when a user was inspecting an element which horizontal scroll wasn't in the most left position.
This diff removes the horizontal constrain and only scroll vertically.
Reviewed By: mweststrate
Differential Revision: D23284227
fbshipit-source-id: 7c19cac7496927c631572e222cb1d635dd1f8ea4
Summary:
Note: this is to be stacked upon https://github.com/facebook/flipper/pull/1479
Note: this PR will probably not succeed against FB internal flipper, as I'm pretty sure there are more call sites that need to be updated. So consider this WIP
Currently connection errors are managed in the connection reducers, and are displayed through their own means, the error bar. Showing console.errors is also hooked up to this mechanism in FB internal flipper, but not at all in the OSS version, which means that some connection errors are never shown to the user.
Besides that there is a notification system that is used by for example the crash reporter and plugin updater.
Having effectively (at least) two notifications mechanisms is confusing and error prone. This PR unifies both approaches, and rather than having the connection reducer manage it's own errors, it leverages the more generic notifications reducer. Since, in the previous PR, console errors and warnings have become user facing (even in OSS and production builds, which wasn't the case before), there is no need anymore for a separate error bar.
I left the notifications mechanism itself as-is, but as discussed in the Sandy project the notification screen will probably be overhauled, and the system wide notifications will become in-app notifications.
## Changelog
Pull Request resolved: https://github.com/facebook/flipper/pull/1483
Test Plan: Only updated the unit tests at this point. Manual tests still need to be done.
Reviewed By: passy
Differential Revision: D23220896
Pulled By: mweststrate
fbshipit-source-id: 8ea37cf69ce9605dc232ca90afe9e2f70da26652
Summary:
While converting Bloks-Script plugin, Timur found a bug where the message queue wasn't processed.
Although queue processing was unit tested, the integration into the rendering lifecycle wasn't explicitly tested and missed a TODO that already signalled this should have been implemented.
Added a unit test to verify the bug and fix. Also tested in a running Flipper instance with the converted plugin (next diff)
Reviewed By: jknoxville
Differential Revision: D23263909
fbshipit-source-id: 63783c980247bdf6c93d00a46881d7d0eb291d09
Summary: If myles is taking too long users might experience issues with multiple tabs open for 'open in diffusion' functionality. This diff addresses this problem by displaying 'open in ide' menu only if the path is already resolved.
Reviewed By: mweststrate
Differential Revision: D23242199
fbshipit-source-id: ffa698110d4c5e0c0e0686fbc56a7eea6b5782e6
Summary:
Some non-semantic changes. Mostly an earlier rename that was accidentally done only locally rather than across the codebase
Also support `.spec` test extension, which is more idiomatic Jest, since we don't use the `.node` and `.electron` distinction anymore anyway.
Reviewed By: jknoxville
Differential Revision: D22976438
fbshipit-source-id: f3abedb36cbac1e835295177117ccbca492a67a1
Summary: Little ux tweak, there are some rare scenarios where you can end up in an empty plugin screen, made a small message.
Reviewed By: jknoxville
Differential Revision: D22846396
fbshipit-source-id: 0ad19f1c252112d78a5587e6633fee2d9542d5e1
Summary:
Converted the DeviceLogs plugin to sandy.
Kept logic and UI the same (so same batching, localstorage mechanisms etc). But used sandy api's for log subscribing, state, and separating the logical part of the component from the UI.
Note that some mechanisms work slightly different, like deeplinking and scrollToBottom handling, to reflect the fact that plugins are now long lived
Reviewed By: jknoxville
Differential Revision: D22845466
fbshipit-source-id: 7c98b2ddd9121dc730768ee1bece7e71bb5bec16
Summary:
Handling issues typically start with: did you look at the Electron logs? Since Flipper is such an extensible tool, running in varying environments I think the console should be support as first class concept. Many errors are currently not shown to the user. This PR is a first attempt to fix that.
The implementation is based on https://github.com/samdenty/console-feed, which is used by quite some web based IDE like tools (like codesandbox), and offers a lot of goodies out of the box, like collapsing errors, objects, etc.
Edit: also added a counter keeping track of the amount of errors
N.B. no need to immediately review this diff, I'll import it to phabricator as soon as I can :)
## Changelog
changelog: Introduce 'Debug Logs' section to help users to troubleshoot issues or to provide more accurate reports.
Pull Request resolved: https://github.com/facebook/flipper/pull/1479
Test Plan: 
Reviewed By: jknoxville
Differential Revision: D23198103
Pulled By: passy
fbshipit-source-id: a2505f9fa59e10676a44ffa33312efe83c7be55d
Summary:
I've gone through all imported pages and fixed all images and links (and anything else) that didn't get converted successfully.
Also changed the new # headings to use ##, because it works better here.
And organized the sidebar like it was on the wiki
Reviewed By: passy
Differential Revision: D23241772
fbshipit-source-id: 7eab8d7d520c5d605525d9b4ad9b12b48ca92bcc
Summary:
This is an automated PR to update the Podfile.lock.
- Make sure that the Podfile.lock contains latest FlipperKit and Flipper pod versions.
- Also make sure that all the dependencies are updated to the latest one.
- This is auto-generated by [create-pull-request](https://github.com/peter-evans/create-pull-request)
Pull Request resolved: https://github.com/facebook/flipper/pull/1485
Reviewed By: priteshrnandgaonkar
Differential Revision: D23241704
Pulled By: passy
fbshipit-source-id: 025947bdf480bdee800717396c1317a5926c6210
Summary:
As per the title
Bug:
{F288338655}
Reviewed By: mweststrate
Differential Revision: D23168390
fbshipit-source-id: e57ac1f22c0a3932fe9948d16cf9fc9cc74ab636
Summary: Bringing this to the latest version everywhere.
Reviewed By: priteshrnandgaonkar
Differential Revision: D23051537
fbshipit-source-id: 5cad59ab6fcc57fc72df8ace985a7b5f39de2bda
Summary:
Bumps [data-encoding](https://github.com/ia0/data-encoding) from 2.2.0 to 2.3.0.
<details>
<summary>Commits</summary>
<ul>
<li><a href="c0facaff53"><code>c0facaf</code></a> Release 2.3.0</li>
<li><a href="d215bc04cb"><code>d215bc0</code></a> lib: Add encode_append function</li>
<li><a href="07dfc9bde4"><code>07dfc9b</code></a> Remove fuzzit</li>
<li><a href="eaa9e11482"><code>eaa9e11</code></a> Release 2.2.1</li>
<li><a href="5aa1d4709b"><code>5aa1d47</code></a> lib: move cargo.toml badges to readme</li>
<li><a href="b6de71c398"><code>b6de71c</code></a> fix coveralls badge</li>
<li><a href="5d4ce64fbb"><code>5d4ce64</code></a> lib: use tarpaulin</li>
<li><a href="9b53af1e4a"><code>9b53af1</code></a> lib: explicit description</li>
<li><a href="f9d4bc3fc2"><code>f9d4bc3</code></a> lib: Add no-std category in Cargo.toml</li>
<li><a href="168aff449e"><code>168aff4</code></a> Release macro 0.1.8</li>
<li>See full diff in <a href="https://github.com/ia0/data-encoding/compare/v2.2.0...v2.3.0">compare view</a></li>
</ul>
</details>
<br />
[](https://help.github.com/articles/configuring-automated-security-fixes)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/1449
Reviewed By: mweststrate
Differential Revision: D23161719
Pulled By: passy
fbshipit-source-id: a7512b96ea8336595435f7a1eed5043b1578d642
Summary:
Detect the framework used for a given component and accordingly, display a proper IDE list.
[FB Only]
changelog: It is now possible to directly open CKComponents from the Layout inspect
Reviewed By: adityasharat
Differential Revision: D23158628
fbshipit-source-id: 305f10752c72eac001334f09bab29264e3e328a6
Summary:
Added corresponding method for CKComponents which handles two main cases:
- CKSomeComponent_Spec should have corresponding CKSomeComponentSpec.mm
- CKSomeComponent should have corresponding CKSomeComponent.mm
Reviewed By: cuva
Differential Revision: D23158626
fbshipit-source-id: 9d5645a70d838847696aced6bbc947a8c4383f0c
Summary: Useful for next diffs: enables to detect whether we have LithoComponent or CKComponent
Reviewed By: adityasharat
Differential Revision: D23128972
fbshipit-source-id: b9aef358c1426df4f05213c42e43402e8cae984f
Summary:
Few cases to consider:
- SomeComponent.* might correspond to SomeComponentSpec.java
- SomeComponent.* might correspond to SomeComponentSpec.kt
- SomeComponent.* might not have a corresponding Spec file
- SomeComponent.kt (if it's a KComponent) corresponds to SomeComponent.kt
Reviewed By: adityasharat
Differential Revision: D23100032
fbshipit-source-id: f0604f3d1061f0e15fa2f455bdddd4d07ac12305
Summary:
- Passing the `treeNodeIndexPath` from `FocusInfo` all the way to the `Tree` component.
- Using the index path to find the right node and give it a different visual appearance.
Reviewed By: kevin0571
Differential Revision: D23161057
fbshipit-source-id: 05a95444bb76c1f28a21b42bf477ed9c9929e3b1
Summary:
- Added `treeNodeIndexPath` to `FocusInfo` which represents the path to the selected node in the component tree.
- Extracting scope root ID from payload to identify the time line track that corresponds to the selected component.
- Finding the most recent 'Tree Build' event on the track so we can be sure the selected component is in the associated component tree.
- Extracting the index path to the selected node in the tree.
Reviewed By: kevin0571
Differential Revision: D23160875
fbshipit-source-id: 8607bf7b34bca1374f9fafded197b35c811f3f75
Summary:
- Use `FocusInfo` type instead of a raw string (I'll add another field to it in the next diff and it made sense to keep the changes separate).
- `userSelectedGenerationId` now has the type of `string | undefined` for consistency.
Reviewed By: fabiomassimo
Differential Revision: D23160820
fbshipit-source-id: f210d93b9ed7cb25eb3c2c8e6e6aadec4dc872d7
Summary:
This diff adds upload and download logic for certs. It makes changes on both Flipper Client and Desktop side. With this we enable cert exchange through WWW.
Next Diffs:
1) Add Flipper state in cert provider for more debug data
2) Tests
Reviewed By: jknoxville
Differential Revision: D23092706
fbshipit-source-id: e576253606b64b62848b70203db7e09a3bd77fd9
Summary:
The new version's disableSwitch isn't equivalent to disabling dark mode like it did before. The default is still dark but now there's no way to change it.
This makes the default light again. Would be nice to enable the dark mode switch, we just need someone to make sure the CSS colours have good enough contrast etc. PRs very welcome!
Dark mode:
{F287823751}
Reviewed By: mweststrate
Differential Revision: D23161145
fbshipit-source-id: fa887afbffa8a1e1e753833b2dba618c5f93435f
Summary:
Added papercuts link to the thanks message after user submits a rating within the star rating popup.
Also increased the timeout after submitting ratings from 1500 to 5000, due to the longer thanks message. Also added a dismiss option.
Reviewed By: jknoxville
Differential Revision: D23115320
fbshipit-source-id: 78de3481e5a085949ddbfbdd51ff499b8b567959
Summary:
Upgrading to 61 to get support for absolute links with markdown syntax.
All other changes here are required by the new config validators.
Reviewed By: passy
Differential Revision: D23130020
fbshipit-source-id: cadb3c629d6a8e64931a8db0b86621d05ee5c30e
Summary:
Removing extra space in README.md
## Changelog
Change in README.md
Pull Request resolved: https://github.com/facebook/flipper/pull/1464
Test Plan: Removing extra space between text
Reviewed By: cekkaewnumchai
Differential Revision: D23103953
Pulled By: passy
fbshipit-source-id: e5f0b6338d64ca2384fe1c42efce1604088c6ce7