Summary: Fixed a potential NPE that could happen in layout editor.
Reviewed By: passy
Differential Revision: D30870185
fbshipit-source-id: 3ae5860ce63761336d8bc508dd8eff761a5ab1f8
Summary:
Enable Flipper Desktop to run both RSocket and WebSocket servers.
I've used 'alt' ports and/or server instead of tying the name explicitly to web sockets. This more general approach can be used later on to supply and use an alternative socket pair for other usages.
Reviewed By: fabiomassimo
Differential Revision: D30482531
fbshipit-source-id: a2c5f25b925c731e7970614b5ed987ce00219918
Summary:
Changelog: Fixed startup error when loading default theme
The theme defaulted to `auto`, instead of `system`, causing an startup exception. Fixed by adding types and having a more defensive startup check.
Fixes https://github.com/facebook/flipper/issues/2835
Reviewed By: jknoxville
Differential Revision: D30866648
fbshipit-source-id: 83b6d9fc235eaa0a7e959df4276d3f378eed7d1f
Summary:
Connections from VSCode and Kite would remain forever pending because they don't go through the secure connection handler. This diff fixes that. Also removed the separate event that existed for that, since registering a new client is already a 'success' signal, so it doesn't need a separate event.
It turned out that the VSCode pending connection is actually correct, as it never handles the `getPlugins` event, so apparently the handling is broken. Added timeouts to guard against that as well.
Applied several code simplications as well.
Introduced an explicit cert exchange medium 'NONE' so that in code it is a bit clearer where CSR negotiation is supposed to happen.
Changelog: Fixed an issue where Kite / Unity apps didn't connect anymore
Reviewed By: timur-valiev
Differential Revision: D30866301
fbshipit-source-id: 8bd214fd9eebcd9a7583f1b44ee283883002f62e
Summary:
In an attempt to trace Android issues:
1. added more logging to the process (opted for info level for now since this is pretty critical for support requests, yet not super repetitive overall. We could maybe turn it into usage tracking at some point to have central stats?).
2. rewrote promise chains to async/await since they are easier to follow and harder to do accidentally wrong
3. fixed some minor potential problems, will highlights those in code.
Changelog: Improved handling of edge cases in certificate exchange, which should address cases where a Flipper connection wouldn't come up when connection to Android / IOS. Added explicit logging around connection negation.
Reviewed By: lblasa
Differential Revision: D30838947
fbshipit-source-id: a898c6d3be6edc22bd24f9d2bad76e81871360da
Summary:
This is the third diff for M3
- Started abstractions to remove repetitive code as a part of M3
- Implemented a new abstracted component in GuideAnserScreen and removed PluginErrored.tsx to integrate it here.
- Using a map object that maps a string to function. Here I have used helper functions to get each screens context as first class members.
- The map is global and is populated globally (as discussed) and we invoke the required function based on the state we are at from GuideAnswerScreen.
Reviewed By: mweststrate
Differential Revision: D30772236
fbshipit-source-id: f8fc175c6d308e2f72c5f6ce826f70245ad46797
Summary:
I've been really sweating about this one. It looks like Google now removed NDK 21 as it's too old. However, we've been struggling with the upgrade because OpenSSL was built against an old version of the NDK/glibc/LLVM/some other stuff.
I've now managed to create an OpenSSL distribution for 1.1.1k (we had 1.1.0h before) that seems to build with this after some small modifications.
This seems to do the trick, but I wouldn't be shocked if we found some more incompatibilities further down the line.
Pull Request resolved: https://github.com/facebook/flipper/pull/2836
Test Plan:
- Locally: `./gradlew :tutorial:installDebug`. Builds, starts up. Cool.
- Public GitHub CI: Happy.
- Circle CI: Only triggers post-land. We'll see. But the setup is simple, so hopefully it should work there, too.
- Internal CI: Waiting for signal.
Reviewed By: fabiomassimo
Differential Revision: D30839209
Pulled By: passy
fbshipit-source-id: efe599f28cc0edfdf2149f905c3483555239edc0
Summary: per title, the logs (e.g. `[interaction] "clear" clicked in 3ms.`) are not super interesting, unless you're trying to build some scuba graphs
Reviewed By: timur-valiev
Differential Revision: D30839590
fbshipit-source-id: d22deec130f947d2d440d499b8e2e146c1b44b68
Summary: Seems Antd always requires a `key` for Menu Items, even when React doesn't strictly need them.
Reviewed By: timur-valiev
Differential Revision: D30839589
fbshipit-source-id: 9cbef32c8fa083a7e23e486e15c537b4a9259a08
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/2838
Test Plan:
Imported from GitHub, without a `Test Plan:` line.
|[Site Preview: flipper](https://our.intern.facebook.com/intern/staticdocs/eph/D30838706/V2/flipper/)
Reviewed By: timur-valiev
Differential Revision: D30838706
Pulled By: passy
fbshipit-source-id: 6f7acf441211d9c5f61a4663af6eaf94f86c4dad
Summary: Upgrade React Native to 0.65.1 in the reference project. Verified that the app installs on Android, iPhone 12, with and without Hermes
Reviewed By: timur-valiev
Differential Revision: D30807062
fbshipit-source-id: 79f4aba2ca9767769842f77221d4cf3eeefbf478
Summary: per title. TS 4.4 is awesome btw, with the much improved control flow analysis.
Reviewed By: timur-valiev
Differential Revision: D30806769
fbshipit-source-id: a41aa7bf10fdb0047ddb6210082b5e1fbdfb255f
Summary:
if a resolved client doesn't become available, we were eating the exception. This diff changes that, as exceptions might actually occur (e.g. a timeout, indicating that for example the device didn't become available, which points out a bug in the example below).
We might now over report some issues, causing regressions in our monitoring, but let's work from there.
Reviewed By: timur-valiev
Differential Revision: D30806511
fbshipit-source-id: 09d62bd7c41439aa452b6df501426e239559eba2
Summary: `yarn start` basically starves if watchman is still scanning the system, until that is completed (which took 40 minutes for me last time). Added a timeout of 1 minute, to signal that you can better to some dishes, instead of trying to hunt a bug that looks like an exception has been eaten somewhere (guess what I did..)
Reviewed By: timur-valiev
Differential Revision: D30806512
fbshipit-source-id: a2ebc3672d82f3388fc7b00f41c7e9c4f37794b3
Summary: During testing, observed that Flipper always starts with an exception if `darkMode` is `true` or `false` (the old format) during startup, and this exception keeps on happening until the setting is changed. The root cause is that the setting is treated verbatim since D30666966 (9a4d94c971), trigger a very confusing Electron error. This diff addresses that.
Reviewed By: timur-valiev
Differential Revision: D30806453
fbshipit-source-id: fc7bbdda4e8bdf2dc4e3ca7ab1b05984c9406c68
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/2834
Test Plan:
Imported from GitHub, without a `Test Plan:` line.
|[Site Preview: flipper](https://our.intern.facebook.com/intern/staticdocs/eph/D30808471/V2/flipper/)
Reviewed By: timur-valiev
Differential Revision: D30808471
Pulled By: passy
fbshipit-source-id: 3cb5d487f1222a08ae9b67cb50fbf459ded40058
Summary: Larger list of fixes. Adding another package to the flipper export is a bit nasty but it unblocks us for now and centralises `remote` access which seems like a win for FAAS.
Reviewed By: mweststrate
Differential Revision: D30785421
fbshipit-source-id: 931297e8566b5d8a213b69ae87d0cda7648b3ed4
Summary: A few more lints. Some already got fixed since the task was created.
Reviewed By: timur-valiev
Differential Revision: D30782192
fbshipit-source-id: 2d03d24034173d632280035e6ba68f485fbe62f3
Summary:
Add an setting option to allow automatic dark theme
A feature requested by swrobel https://github.com/facebook/flipper/issues/2708
## Changelog
### UI change
Replace the `Enable Dark Theme` Toggle button with a Radio group containing three Radio buttons.
The available options are `Dark`, `Light` and `Use System Default`, of which `Use System Default` is the default value
<img width="548" alt="Screenshot 2021-08-31 at 3 32 44 PM" src="https://user-images.githubusercontent.com/410850/131462798-4e74f757-41fc-4a3f-ba28-53d00fc1cf03.png">
### Data structure change
The `darkMode` property of [Settings](c0cd32564a/desktop/app/src/reducers/settings.tsx (L20)) is changed from `boolean` to `string`, the available values are `dark`, `light` and `auto`
Pull Request resolved: https://github.com/facebook/flipper/pull/2759
Test Plan:
### Test 1
- Step: Choose `Dark` in the Settings page and click on `Apply and Restart` button
- Expect: The application is displayed in Dark mode
### Test 2
- Step: Choose `Light` in the Settings page and click on `Apply and Restart` button
- Expect: The application is displayed in Light mode
### Test 3
- Step: Choose `Use System Default` in the Settings page and click on `Apply and Restart` button
- Expect: The application is displayed in System Default mode
Reviewed By: mweststrate
Differential Revision: D30666966
Pulled By: passy
fbshipit-source-id: a63e91f2d0dbff96890e267062cb75bffd0007f4
Summary: For now this seems to be the recommended way as the old npm package is dead.
Reviewed By: timur-valiev
Differential Revision: D30767043
fbshipit-source-id: 6b388138a0592e784b31ff2e3b79635927f31e16
Summary:
This diff has been automatically generated by the inpage editor.
If you want to update this diff, go through the preview link that would be attached to the test plan.
Please ensure you are editing the same page that was used to create this diff.
Reviewed By: timur-valiev
Differential Revision: D30767036
fbshipit-source-id: 8e828f9f6fb6a5590be428ed325418a62df55c4d
Summary:
Bumps [ws](https://github.com/websockets/ws) from 7.5.3 to 8.2.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/websockets/ws/releases">ws's releases</a>.</em></p>
<blockquote>
<h2>8.2.1</h2>
<h1>Bug fixes</h1>
<ul>
<li>Fixed an issue where the socket was not resumed, preventing the connection
from being closed cleanly (869c9892).</li>
</ul>
<h2>8.2.0</h2>
<h1>Features</h1>
<ul>
<li>Added <code>WebSocket.WebSocket</code> as an alias for <code>WebSocket</code> and
<code>WebSocket.WebSocketServer</code> as an alias for <code>WebSocket.Server</code> to fix name
consistency and improve interoperability with the ES module wrapper (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1935">https://github.com/facebook/flipper/issues/1935</a>).</li>
</ul>
<h2>8.1.0</h2>
<h1>Features</h1>
<ul>
<li>Added ability to skip UTF-8 validation (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1928">https://github.com/facebook/flipper/issues/1928</a>).</li>
</ul>
<h1>Bug fixes</h1>
<ul>
<li>Fixed an issue with a breaking change in Node.js master (6a72da3e).</li>
<li>Fixed a misleading error message (c95e695d).</li>
</ul>
<h2>8.0.0</h2>
<h1>Breaking changes</h1>
<ul>
<li>
<p>The <code>WebSocket</code> constructor now throws a <code>SyntaxError</code> if any of the
subprotocol names are invalid or duplicated (0aecf0c9).</p>
</li>
<li>
<p>The server now aborts the opening handshake if an invalid
<code>Sec-WebSocket-Protocol</code> header field value is received (1877ddeb).</p>
</li>
<li>
<p>The <code>protocols</code> argument of <code>handleProtocols</code> hook is no longer an <code>Array</code> but
a <code>Set</code> (1877ddeb).</p>
</li>
<li>
<p>The opening handshake is now aborted if the <code>Sec-WebSocket-Extensions</code> header
field value is empty or it begins or ends with a white space (e814110e).</p>
</li>
<li>
<p>Dropped support for Node.js < 10.0.0 (552b5067).</p>
</li>
<li>
<p>The <code>WebSocket</code> constructor now throws a <code>SyntaxError</code> if the connection URL
contains a fragment identifier or if the URL's protocol is not one of <code>'ws:'</code>,
<code>'wss:'</code>, or <code>'ws+unix:'</code> (ebea038f).</p>
</li>
<li>
<p>Text messages and close reasons are no longer decoded to strings. They are
passed as <code>Buffer</code>s to the listeners of their respective events. The listeners
of the <code>'message'</code> event now take a boolean argument specifying whether or not
the message is binary (e173423c).</p>
<p>Existing code can be migrated by decoding the buffer explicitly.</p>
<pre lang="js"><code>websocket.on('message', function message(data, isBinary) {
const message = isBinary ? data : data.toString();
// Continue as before.
});
</code></pre>
</li>
</ul>
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="cc7a7798b7"><code>cc7a779</code></a> [dist] 8.2.1</li>
<li><a href="869c9892cd"><code>869c989</code></a> [fix] Resume the socket in the next tick</li>
<li><a href="ea6c054e97"><code>ea6c054</code></a> [test] Reorganize some tests</li>
<li><a href="7647a8920b"><code>7647a89</code></a> [dist] 8.2.0</li>
<li><a href="d5e3549a03"><code>d5e3549</code></a> [minor] Add <code>WebSocket.WebSocket{,Server}</code> aliases (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1935">https://github.com/facebook/flipper/issues/1935</a>)</li>
<li><a href="c677aab978"><code>c677aab</code></a> [doc] Fix <code>createWebSocketStream()</code> documentation</li>
<li><a href="f38247e5e0"><code>f38247e</code></a> [doc] Sort options alphabetically</li>
<li><a href="142f0911b5"><code>142f091</code></a> [dist] 8.1.0</li>
<li><a href="d21c81034f"><code>d21c810</code></a> [feature] Add ability to skip UTF-8 validation (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1928">https://github.com/facebook/flipper/issues/1928</a>)</li>
<li><a href="9bd3bd1251"><code>9bd3bd1</code></a> [minor] Fix typo (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1929">https://github.com/facebook/flipper/issues/1929</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/websockets/ws/compare/7.5.3...8.2.1">compare view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
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/2756
Reviewed By: lblasa
Differential Revision: D30727123
Pulled By: passy
fbshipit-source-id: b06ab55427b7798d004d2f3371f76bda6af69947
Summary:
ESM module snuck in and wasn't caught in tests or builds.
Fixes Q244903.
Should fix https://github.com/facebook/flipper/issues/2768
Reviewed By: mweststrate
Differential Revision: D30760296
fbshipit-source-id: 36c632260e069830da1121e3d5de4ab21cef90f2
Summary:
This allows us to configure a simulator to use a non-default port pair by using the `defaults` mechanism. For instance, this can be done by running
```
xcrun simctl spawn booted defaults write "Apple Global Domain" "com.facebook.flipper.ports" -string "9088,9089"
```
Reviewed By: lblasa, timur-valiev
Differential Revision: D30731874
fbshipit-source-id: 689d60b1c392f36dceef1b3c3cfa0c88f54a7a82
Summary:
Bumps [tar](https://github.com/npm/node-tar) from 6.1.6 to 6.1.11.
<details>
<summary>Commits</summary>
<ul>
<li><a href="e573aeea19"><code>e573aee</code></a> 6.1.11</li>
<li><a href="edb8e9a3fa"><code>edb8e9a</code></a> fix: perf regression on hot string munging path</li>
<li><a href="a9d9b05fc9"><code>a9d9b05</code></a> chore(test): Avoid spurious failures packing node_modules/.cache</li>
<li><a href="24b8bdadf3"><code>24b8bda</code></a> fix(test): use posix path for testing path reservations</li>
<li><a href="e5a223c6b2"><code>e5a223c</code></a> fix(test): make unpack test pass on case-sensitive fs</li>
<li><a href="188baddc1d"><code>188badd</code></a> 6.1.10</li>
<li><a href="23312ce7db"><code>23312ce</code></a> drop dirCache for symlink on all platforms</li>
<li><a href="4f1f4a21fc"><code>4f1f4a2</code></a> 6.1.9</li>
<li><a href="875a37e3ec"><code>875a37e</code></a> fix: prevent path escape using drive-relative paths</li>
<li><a href="b6162c7faf"><code>b6162c7</code></a> fix: reserve paths properly for unicode, windows</li>
<li>Additional commits viewable in <a href="https://github.com/npm/node-tar/compare/v6.1.6...v6.1.11">compare view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
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)
You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/facebook/flipper/network/alerts).
</details>
Pull Request resolved: https://github.com/facebook/flipper/pull/2762
Reviewed By: lblasa
Differential Revision: D30727122
Pulled By: passy
fbshipit-source-id: 3d458874b3d7f2b81598b713031fb1e09d44e554
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/2764
Reviewed By: lblasa
Differential Revision: D30727119
Pulled By: passy
fbshipit-source-id: 67e5f9bf429244c009d2a27134eb4867ff16d254
Summary: Based on afcoplan's feedback, now we're showing a button for launching the emulators instead of having it inline.
Reviewed By: mweststrate
Differential Revision: D30603659
fbshipit-source-id: edae6c63fd58647b406398c897215910938ae429
Summary:
Remove IPC rendering / connection implementation. This has been behind GK for a couple of weeks, and no one complained / white listed. See also D30367413.
flipper_js_client_emulator
Reviewed By: passy
Differential Revision: D30452442
fbshipit-source-id: fbe7b4914fecc023f3ec78a027106ea32c5a99bd
Summary:
This diff has been automatically generated by the inpage editor.
If you want to update this diff, go through the preview link that would be attached to the test plan.
Please ensure you are editing the same page that was used to create this diff.
Reviewed By: nikoant
Differential Revision: D30685168
fbshipit-source-id: cf5fa06d23390e293b8986e513d9b739efd5210b