Commit Graph

360 Commits

Author SHA1 Message Date
Michel Weststrate
a31494f321 Fix unnecessary 'still authorizing' error
Summary:
When connection to Android, I always get an error popup with 'device still authorizing', which disappears itself and the device connects fine. It seems that this was a case we handled gracefully before, but the error message we check for has changed. Also updated the log message so that we get it in our monitoring I don't silently get stuck in this state.

Changelog: Fixed 'device still authorizing' errors showing up while connecting to an Android device

Reviewed By: aigoncharov

Differential Revision: D33976028

fbshipit-source-id: dbb055bbbd43bad129b10ffee4a8dbb50be8e87a
2022-02-03 04:20:54 -08:00
Andrey Goncharov
7376774a95 Add RSocket deprecation warning
Reviewed By: lblasa

Differential Revision: D33976369

fbshipit-source-id: c100c145d7c77369347200d32448015ad971d585
2022-02-03 03:52:22 -08:00
dependabot[bot]
e26540ddd7 Bump axios from 0.24.0 to 0.25.0 in /desktop (#3383)
Summary:
Bumps [axios](https://github.com/axios/axios) from 0.24.0 to 0.25.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/axios/axios/releases">axios's releases</a>.</em></p>
<blockquote>
<h2>v0.25.0</h2>
<h3>0.25.0 (January 18, 2022)</h3>
<p>Breaking changes:</p>
<ul>
<li>Fixing maxBodyLength enforcement (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3786">#3786</a>)</li>
<li>Don't rely on strict mode behaviour for arguments (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3470">#3470</a>)</li>
<li>Adding error handling when missing url (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3791">#3791</a>)</li>
<li>Update isAbsoluteURL.js removing escaping of non-special characters (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3809">#3809</a>)</li>
<li>Use native Array.isArray() in utils.js (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3836">#3836</a>)</li>
<li>Adding error handling inside stream end callback (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3967">#3967</a>)</li>
</ul>
<p>Fixes and Functionality:</p>
<ul>
<li>Added aborted even handler (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3916">#3916</a>)</li>
<li>Header types expanded allowing <code>boolean</code> and <code>number</code> types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4144">#4144</a>)</li>
<li>Fix cancel signature allowing cancel message to be <code>undefined</code> (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3153">https://github.com/facebook/flipper/issues/3153</a>)</li>
<li>Updated type checks to be formulated better (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3342">https://github.com/facebook/flipper/issues/3342</a>)</li>
<li>Avoid unnecessary buffer allocations (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3321">https://github.com/facebook/flipper/issues/3321</a>)</li>
<li>Adding a socket handler to keep TCP connection live when processing long living requests (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3422">#3422</a>)</li>
<li>Added toFormData helper function (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3757">#3757</a>)</li>
<li>Adding responseEncoding prop type in AxiosRequestConfig (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3918">#3918</a>)</li>
</ul>
<p>Internal and Tests:</p>
<ul>
<li>Adding axios-test-instance to ecosystem (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3786">#3786</a>)</li>
<li>Optimize the logic of isAxiosError (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3546">#3546</a>)</li>
<li>Add tests and documentation to display how multiple inceptors work (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3564">#3564</a>)</li>
<li>Updating follow-redirects to version 1.14.7 (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4379">#4379</a>)</li>
</ul>
<p>Documentation:</p>
<ul>
<li>Fixing changelog to show corrext pull request (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4219">#4219</a>)</li>
<li>Update upgrade guide for https proxy setting (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3604">#3604</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/HEAD/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/rijkvanzanten">Rijk van Zanten</a></li>
<li><a href="https://github.com/koh110">Kohta Ito</a></li>
<li><a href="https://github.com/bfaulk96">Brandon Faulkner</a></li>
<li><a href="https://github.com/NoriSte">Stefano Magni</a></li>
<li><a href="https://github.com/fanguangyi">enofan</a></li>
<li><a href="https://github.com/puzpuzpuz">Andrey Pechkurov</a></li>
<li><a href="https://github.com/doowonee">Doowonee</a></li>
<li><a href="https://github.com/emilbroman-eqt">Emil Broman</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/BlackHole1">Black-Hole</a></li>
<li><a href="https://github.com/wolframkriesing">Wolfram Kriesing</a></li>
<li><a href="https://github.com/repl-andrew-ovens">Andrew Ovens</a></li>
<li><a href="https://github.com/PauloRSF">Paulo Renato</a></li>
<li><a href="https://github.com/carpben">Ben Carp</a></li>
<li><a href="https://github.com/wafuwafu13">Hirotaka Tagawa</a></li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/axios/axios/blob/master/CHANGELOG.md">axios's changelog</a>.</em></p>
<blockquote>
<h3>0.25.0 (January 18, 2022)</h3>
<p>Breaking changes:</p>
<ul>
<li>Fixing maxBodyLength enforcement (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3786">#3786</a>)</li>
<li>Don't rely on strict mode behaviour for arguments (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3470">#3470</a>)</li>
<li>Adding error handling when missing url (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3791">#3791</a>)</li>
<li>Update isAbsoluteURL.js removing escaping of non-special characters (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3809">#3809</a>)</li>
<li>Use native Array.isArray() in utils.js (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3836">#3836</a>)</li>
<li>Adding error handling inside stream end callback (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3967">#3967</a>)</li>
</ul>
<p>Fixes and Functionality:</p>
<ul>
<li>Added aborted even handler (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3916">#3916</a>)</li>
<li>Header types expanded allowing <code>boolean</code> and <code>number</code> types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4144">#4144</a>)</li>
<li>Fix cancel signature allowing cancel message to be <code>undefined</code> (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3153">https://github.com/facebook/flipper/issues/3153</a>)</li>
<li>Updated type checks to be formulated better (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3342">https://github.com/facebook/flipper/issues/3342</a>)</li>
<li>Avoid unnecessary buffer allocations (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3321">https://github.com/facebook/flipper/issues/3321</a>)</li>
<li>Adding a socket handler to keep TCP connection live when processing long living requests (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3422">#3422</a>)</li>
<li>Added toFormData helper function (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3757">#3757</a>)</li>
<li>Adding responseEncoding prop type in AxiosRequestConfig (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3918">#3918</a>)</li>
</ul>
<p>Internal and Tests:</p>
<ul>
<li>Adding axios-test-instance to ecosystem (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3786">#3786</a>)</li>
<li>Optimize the logic of isAxiosError (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3546">#3546</a>)</li>
<li>Add tests and documentation to display how multiple inceptors work (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3564">#3564</a>)</li>
<li>Updating follow-redirects to version 1.14.7 (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4379">#4379</a>)</li>
</ul>
<p>Documentation:</p>
<ul>
<li>Fixing changelog to show corrext pull request (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4219">#4219</a>)</li>
<li>Update upgrade guide for https proxy setting (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3604">#3604</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/master/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/rijkvanzanten">Rijk van Zanten</a></li>
<li><a href="https://github.com/koh110">Kohta Ito</a></li>
<li><a href="https://github.com/bfaulk96">Brandon Faulkner</a></li>
<li><a href="https://github.com/NoriSte">Stefano Magni</a></li>
<li><a href="https://github.com/fanguangyi">enofan</a></li>
<li><a href="https://github.com/puzpuzpuz">Andrey Pechkurov</a></li>
<li><a href="https://github.com/doowonee">Doowonee</a></li>
<li><a href="https://github.com/emilbroman-eqt">Emil Broman</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/BlackHole1">Black-Hole</a></li>
<li><a href="https://github.com/wolframkriesing">Wolfram Kriesing</a></li>
<li><a href="https://github.com/repl-andrew-ovens">Andrew Ovens</a></li>
<li><a href="https://github.com/PauloRSF">Paulo Renato</a></li>
<li><a href="https://github.com/carpben">Ben Carp</a></li>
<li><a href="https://github.com/wafuwafu13">Hirotaka Tagawa</a></li>
<li><a href="https://github.com/lzxb">狼族小狈</a></li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="5c5cbdf4ba"><code>5c5cbdf</code></a> Removed cancel token request test till debugging on FireFox can be done</li>
<li><a href="63dfce85ab"><code>63dfce8</code></a> Releasing v0.25</li>
<li><a href="dccaeb1b68"><code>dccaeb1</code></a> Updated changelog for release</li>
<li><a href="51f3ccb08e"><code>51f3ccb</code></a> Updating follow-redirects with security updates (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4379">#4379</a>)</li>
<li><a href="ccc9516af8"><code>ccc9516</code></a> Fixing removing package-lock from gitignore (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4346">#4346</a>)</li>
<li><a href="ea0d9c69f7"><code>ea0d9c6</code></a> Adding error handling inside stream end callback (<a href="https://github-redirect.dependabot.com/axios/axios/issues/3967">#3967</a>)</li>
<li><a href="4fbf61dc75"><code>4fbf61d</code></a> Adding responseEncoding prop type in AxiosRequestConfig (<a href="https://github-redirect.dependabot.com/axios/axios/issues/3918">#3918</a>)</li>
<li><a href="a76571abec"><code>a76571a</code></a> Use native <code>Array.isArray()</code> in <code>utils.js</code> (<a href="https://github-redirect.dependabot.com/axios/axios/issues/3836">#3836</a>)</li>
<li><a href="a8cd75a081"><code>a8cd75a</code></a> Update isAbsoluteURL.js (<a href="https://github-redirect.dependabot.com/axios/axios/issues/3809">#3809</a>)</li>
<li><a href="95792908f0"><code>9579290</code></a> Adding error handling when missing url (<a href="https://github-redirect.dependabot.com/axios/axios/issues/3791">#3791</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/axios/axios/compare/v0.24.0...v0.25.0">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=axios&package-manager=npm_and_yarn&previous-version=0.24.0&new-version=0.25.0)](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/3383

Reviewed By: nikoant

Differential Revision: D33892131

Pulled By: cekkaewnumchai

fbshipit-source-id: 50c82da299e0e8ca025e0a0868a3f5deb31f475c
2022-02-02 11:14:39 -08:00
Andrey Goncharov
c238cef5b0 Verify certificate provider medium
Reviewed By: antonk52

Differential Revision: D33917041

fbshipit-source-id: 91a9554397063d53a903a5b1406b46ddf07360b2
2022-02-02 03:07:00 -08:00
Andrey Goncharov
c7492a83c7 Remove global access to adb client and idb config
Summary: Idb and adb sholuld not really be accessed out side of Adnroid and iOS device managers

Reviewed By: lawrencelomax

Differential Revision: D33915162

fbshipit-source-id: 0d1bb028b9a53254cf5b0ce6289ae76339c5a254
2022-02-02 03:07:00 -08:00
Andrey Goncharov
51ef1810b2 Defer initialization of Android and iOS device managers
Summary: Remove hidden async initialization of adb and idb. Make it explicit. Remove nullable fields in Android and iOS device managers.

Reviewed By: lawrencelomax

Differential Revision: D33915177

fbshipit-source-id: 882f79310410e0dfde6169abf343ab808644e4a2
2022-02-02 03:07:00 -08:00
Andrey Goncharov
fd13399cb9 Extract WWW certificate provider
Summary: Extract WWW certificate provider from the iOS certificate provider. Hide its implementation from OSS since it is not relevant for OSS folks.

Reviewed By: mweststrate

Differential Revision: D33895378

fbshipit-source-id: 376afda3b5fa3857c0eb280b92555314eb1a0d1f
2022-02-02 03:07:00 -08:00
Andrey Goncharov
29f6d0e711 Add device-specific Certificate Providers
Reviewed By: mweststrate

Differential Revision: D33821880

fbshipit-source-id: c75c71db4d7dc680f75cf41ba2d5dad009a5fd03
2022-02-02 03:07:00 -08:00
Andrey Goncharov
b9aeaa9339 Enhance iOS device manager tests
Reviewed By: lawrencelomax

Differential Revision: D33915694

fbshipit-source-id: fc4bfd30b8f504f2f242f94e61967ee68cc83100
2022-02-02 03:07:00 -08:00
Andrey Goncharov
7bf89a840a Remove a circular dependency between KeytarManager and FlipperServerImpl
Reviewed By: passy

Differential Revision: D33846051

fbshipit-source-id: c83f5609308ad732a02b2ee55466f5ed0918d733
2022-02-02 03:07:00 -08:00
Andrey Goncharov
b1f19ecd68 Extract certificate utils
Summary: Extract utilities for certificate server-side certificate handling

Reviewed By: lawrencelomax

Differential Revision: D33820263

fbshipit-source-id: 21f1a9ed5f3b83b8350151bdf6d8862aa0b18e8f
2022-02-02 03:07:00 -08:00
Andrey Goncharov
e686766e5f Simplify CertificateProvider setup
Summary:
Currently, certificateSetup is called in two places:
- processCertificateSigningRequest
- loadSecureServerConfig

`loadSecureServerConfig` is a mandatory step of Flipper server initialization ([ServerController.init](https://www.internalfb.com/code/flipper/[24785758018a2ffbd4751ad2b9093b5ef97c611d]/src/fbsource/xplat/sonar/desktop/flipper-server-core/src/comms/ServerController.tsx?lines=118)). Flipper cannot start without executing it.

As a result, calling `certificateSetup` in `processCertificateSigningRequest` always results in the early return.

This diff removes executing `certificateSetup` from `processCertificateSigningRequest`. Since it's called only during server setup (so only once), it no longer makes sense to use `didCertificateSetup`.

Next steps:
- Extract Android and iOS certificate utils. Remove the dependency on accessing adb/idb dynamically. See D33711652 (da618fd3f3).

Reviewed By: jknoxville

Differential Revision: D33817119

fbshipit-source-id: 675d1e2fe468782da458832c2e88259c92951fdb
2022-02-02 03:06:59 -08:00
Lawrence Lomax
ed03f1b107 Use idb to record devices
Summary:
`idb` has supported video recording on devices for quite some time now. We even have the implementation in `iOSDevice`, but it's currently unused.

As a result, we just need to remove the check within `iOSDevice` that the target is an "emulator" and it will use the `idb` implementation. Removing this check means that the button is now selectable within the UI.

Reviewed By: passy

Differential Revision: D33913383

fbshipit-source-id: b3d6b4c480c79b54f0d2c206c68092ab62bf71ed
2022-02-01 04:57:16 -08:00
Lawrence Lomax
3a9c875e03 Avoid double recording in iOSDevice
Summary: This should in theory never happen since the state of the recording is also managed within the UI. However, it's better to ensure that if `startRecording` is called twice, without calling `stopRecording` first it will error rather than leak a recording (the first process will still run but the object representing it is oprhaned)

Reviewed By: passy

Differential Revision: D33913298

fbshipit-source-id: f8fa6b0e4fdbdf4282633fa29a736d3e7dedf3bb
2022-02-01 04:57:16 -08:00
Lawrence Lomax
7d34c86f78 Remove recording invariants
Summary:
The state of the destination and the process are coupled together. As a result it makes sense to move these to an object type.

This prevents destination and process being independently settable. No change in behaviour, just a removal of invariants that need to be checked

Reviewed By: passy

Differential Revision: D33913213

fbshipit-source-id: ed18650cac4f72d40e82d20254674f7fa12cbb48
2022-02-01 04:57:16 -08:00
Lawrence Lomax
a9b9a1bff4 Remove redundant xcodeCommandLineToolsDetected
Summary: This is public but never read, no need for it to exist

Reviewed By: passy

Differential Revision: D33893097

fbshipit-source-id: aa423464f9cc0c35768a549fd5cb481784d8bcd6
2022-02-01 00:44:34 -08:00
Lawrence Lomax
9cbdc3038f Remove mising iOS Bridge invariant in iOSDeviceManager
Summary:
There's no need for us to have a property that can be undefined, since we can use the magic of *passing arguments* to achieve the same end result.

The unit test a bit more precarious, but it's left here for posterity or until we decide to kill it otherwise.

Reviewed By: passy

Differential Revision: D33892407

fbshipit-source-id: 3b499511189862e2265d8d6d29f849a7b813050e
2022-02-01 00:44:34 -08:00
Lawrence Lomax
757b82757e Use polymorphic IOSBridge to perform iOS target listing
Summary:
Bulding on the work from prior diffs we can use the created bridge directly. No need to have if statements calling out to sub-functions, just use the base type itself which will use the appropriate implementation.

There's no behavioural change here. Either idb was queried for sims/devices or simctl was queried for just sims, they were always mutually exclusive.

Reviewed By: passy

Differential Revision: D33842604

fbshipit-source-id: 0bf63ffc34368c70df31c105ea0ba5df941e72cc
2022-02-01 00:44:34 -08:00
Lawrence Lomax
b0046c8ddb Check for xcode mismatch once and only once
Summary:
We perform this *repeatedly* (every 2s!!!). Which is clearly excessive.

Let's perform this check once to avoid noise and a waste of system resources

Reviewed By: passy

Differential Revision: D33844194

fbshipit-source-id: 226dc9d67bb83b167afa8e28ade8e1911470ef8a
2022-02-01 00:44:34 -08:00
Lawrence Lomax
e16662a28f Improve xcode version mismatch messaging
Summary:
This runs in a very hot loop (which I will change shortly)

However, there's also some simplification that we can do here:
- Only look for `Simulator.app` processes instead of all the processes. This limits the amount of string comparison to do. If there's a `Simulator.app` running, then we know a sim is running for that Xcode.
- Use piping to extract the launch path of the process, instead of then regex'ing this out.
- Use a simpler substring match to determine if paths have a different start.

Reviewed By: passy

Differential Revision: D33891296

fbshipit-source-id: e37d5f260fc6c6113be9c5268b7c8cffb4057b9a
2022-02-01 00:44:34 -08:00
Anton Kastritskiy
c5dd1fc350 rename files from ts to tsx in flipper-* packages
Summary: mass files rename

Reviewed By: nikoant

Differential Revision: D33890252

fbshipit-source-id: d5afaa60af7340313a97d8e4967fe37f00abd9db
2022-01-31 10:16:19 -08:00
Lawrence Lomax
ccae37aa71 Extract idb device querying to IOSBridge
Summary:
Again this is just a code move for now.

However, we now have a common method between simctl and idb cases. This means that the next diff can call an `IOSBridge` with polymorpism taking over. This is still delegated out, but there's an argument to be made to move `iosUtil` functionality back so that this all lives in the same place.

Reviewed By: passy

Differential Revision: D33843093

fbshipit-source-id: 5cd884140817df851cccf63e5780582b16d4231c
2022-01-31 07:29:34 -08:00
Lawrence Lomax
aeb0b5f317 Extract getSimulators to IOSBridge
Summary:
Extracts `getSimulator` interrnals to `SimctlBridge`. This allows this functionality to be used independently of things like the the flipper server.

For now this just moves the functionality, but future diffs will build on top of this.

Reviewed By: passy

Differential Revision: D33842986

fbshipit-source-id: bae26a9bd5c21c9813f8a2b10c3b3e3efc1c5929
2022-01-31 07:29:34 -08:00
Lawrence Lomax
959a2a77d7 Extract launchSimulator to IOSBridge
Summary:
This is related to `simctl` functionality, so can be extracted there.

This will aid in future changes whereby we can hide `getDeviceSetPath` in the IOSBridge module

Reviewed By: passy

Differential Revision: D33842987

fbshipit-source-id: de292ce5afba3e7d79d8ba27c2b8852909d7e6f3
2022-01-31 07:29:34 -08:00
Anton Kastritskiy
1aff8466b1 let linter handle type naming conventions
Summary: {gif:kosnw403}

Reviewed By: passy

Differential Revision: D33846715

fbshipit-source-id: 5de4bb0cf88f24f5a26acedb82a0816417fb0787
2022-01-31 02:49:09 -08:00
Lawrence Lomax
2573462cec Use provided idb path in iOSBridge idb execs
Summary:
We pass the `idbPath` to only the log listener function, when in reality it should be used by all of these functions that call out to idb.

This could result in some bizzare inconsistencies where some idb functions to fail as they are not using the supplied path

Reviewed By: passy

Differential Revision: D33818298

fbshipit-source-id: f0fb7f26579c646a0d5265364d539dfded711c2e
2022-01-28 00:35:23 -08:00
Lawrence Lomax
e2abe1c89a Separate concerns of reading screenshot into buffer & execing screenshot function
Summary: This allows us to change the way that the command is itself exec'd (for instance to change the idb exec'ing in D33818298)

Reviewed By: passy

Differential Revision: D33818822

fbshipit-source-id: c90b7e58c7476f5db08da0e74e9791230ff97f6f
2022-01-28 00:35:23 -08:00
Lawrence Lomax
4f886448e0 Move simctl iOSBridge free-functions into class
Summary: Similar to D33818267, but for simctl. Brings logical ordering of methods as well as consistency

Reviewed By: passy

Differential Revision: D33818687

fbshipit-source-id: 3fbcea128d06c900b49b83ad583ec8a7a07cae2c
2022-01-28 00:35:23 -08:00
Lawrence Lomax
1e5a070dbd Move idb iOSBridge free-functions into class
Summary:
This isn't that important right now, but will help as the `IOSBridge` is expanded in the future. There's also an argument for logical ordering of functions within a container (a class!), but that's not the real motivation here.

The existence of `bind` shows that this free function is effectively closing over this argument anyway.

Reviewed By: passy, lblasa

Differential Revision: D33818267

fbshipit-source-id: e7b83f013121cedbd31cb28746b69c1fa76a0803
2022-01-28 00:35:23 -08:00
Andrey Goncharov
e0204486a5 Fix stale idbConfig and adb in CertificateProvider
Summary: CertificateProvider initializes too early, and set abd and idb to undefined, before adb and idb are initialized by android and ios manager.

Reviewed By: lawrencelomax

Differential Revision: D33792854

fbshipit-source-id: b6bba32dead7edf62e360b2e2563f2b67243b1b8
2022-01-26 10:23:45 -08:00
Andrey Goncharov
da618fd3f3 Decouple CertificateProvider and adb/idb client intialization
Summary:
Previously CertificateProvider initialized ADB and provided config to IDB. As result, AndroidDeviceManager and iOSDeviceManager indirectly depended on CertificateProvider.

With this diff we:
1. Make idbConfig resemble adbClient.
2. Make AndroidDeviceManager and iOSDeviceManager initialize their own clients
3. Fix server crash when one of the clients couldn't be initialized. The reason for the crash is CertificateProvider.prototype.init which is no longer needed.

Reviewed By: passy

Differential Revision: D33711652

fbshipit-source-id: 055b5625ed993827b65396f4af5157808479242b
2022-01-26 04:23:05 -08:00
dependabot[bot]
0d1520bbec Bump ws from 8.4.0 to 8.4.2 in /desktop (#3354)
Summary:
Bumps [ws](https://github.com/websockets/ws) from 8.4.0 to 8.4.2.
<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.4.2</h2>
<h1>Bug fixes</h1>
<ul>
<li>Fixed a data framing issue introduced in version 8.4.1 (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/2004">https://github.com/facebook/flipper/issues/2004</a>).</li>
</ul>
<h2>8.4.1</h2>
<h1>Notable changes</h1>
<ul>
<li>To improve performance, strings sent via <code>websocket.ping()</code>,
<code>websocket.pong()</code>, and <code>websocket.send()</code> are no longer converted to
<code>Buffer</code>s if the data does not need to be masked (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/2000">https://github.com/facebook/flipper/issues/2000</a>).</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="33fd1016ec"><code>33fd101</code></a> [dist] 8.4.2</li>
<li><a href="0c0754b897"><code>0c0754b</code></a> [fix] Use the byte length of the data (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/2004">https://github.com/facebook/flipper/issues/2004</a>)</li>
<li><a href="6ebfeb8be7"><code>6ebfeb8</code></a> [dist] 8.4.1</li>
<li><a href="5b7fbb0009"><code>5b7fbb0</code></a> [perf] Reduce buffer allocations (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/2000">https://github.com/facebook/flipper/issues/2000</a>)</li>
<li><a href="8de448fbd1"><code>8de448f</code></a> [test] Fix failing tests</li>
<li><a href="91f3c07b26"><code>91f3c07</code></a> [minor] Replace echo.websocket.org with websocket-echo.com</li>
<li><a href="ad3fe6dc4f"><code>ad3fe6d</code></a> [test] Improve test title</li>
<li><a href="4081a368ff"><code>4081a36</code></a> [test] Do not call the <code>done</code> callback prematurely</li>
<li><a href="d2c935a477"><code>d2c935a</code></a> [doc] Fix typo in <code>WebSocketServer</code> description (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1996">https://github.com/facebook/flipper/issues/1996</a>)</li>
<li><a href="5edf1f4a1b"><code>5edf1f4</code></a> [doc] Clarify interpretation of <code>verifyClient</code> (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1994">https://github.com/facebook/flipper/issues/1994</a>)</li>
<li>See full diff in <a href="https://github.com/websockets/ws/compare/8.4.0...8.4.2">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=ws&package-manager=npm_and_yarn&previous-version=8.4.0&new-version=8.4.2)](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/3354

Reviewed By: aigoncharov

Differential Revision: D33741798

Pulled By: lblasa

fbshipit-source-id: e8d43d2408118f6b19a2c59603b92c701100f355
2022-01-24 09:38:27 -08:00
Andrey Goncharov
b5cd33f7e8 Fix excessive error login for FLIPPER_BROWSER_PORT
Summary: Prior to this diff, an empty env var FLIPPER_BROWSER_PORT resulted in an error

Reviewed By: passy

Differential Revision: D33712720

fbshipit-source-id: 760fc92bbf44268ec428a3d2947735d5cf8567b7
2022-01-21 13:31:33 -08:00
Andrey Goncharov
3865a3d9a2 Support a custom port for the insecure connection flow
Summary:
1. Remove GK.get('comet_enable_flipper_connection') which does not seem to be needed anymore
2. Support custom ports for the insecure connection flow

Reviewed By: lblasa

Differential Revision: D33632891

fbshipit-source-id: 045d6886ea94e15bff38f2f61c7d5a2c56c39859
2022-01-18 05:52:57 -08:00
dependabot[bot]
97f861b2dc Bump ws from 7.5.6 to 8.4.0 in /desktop (#3240)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/3240

Bumps [ws](https://github.com/websockets/ws) from 7.5.6 to 8.4.0.
<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.4.0</h2>
<h1>Features</h1>
<ul>
<li>Added ability to generate custom masking keys (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1990">https://github.com/facebook/flipper/issues/1990</a>).</li>
</ul>
<h2>8.3.0</h2>
<h1>Features</h1>
<ul>
<li>Added ability to pause and resume a <code>WebSocket</code> (0a8c7a9c).</li>
</ul>
<h1>Bug fixes</h1>
<ul>
<li>Fixed a bug that could prevent the connection from being closed cleanly when
using the stream API (ed2b8039).</li>
<li>When following redirects, an error is now emitted and not thrown if the
redirect URL is invalid (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1980">https://github.com/facebook/flipper/issues/1980</a>).</li>
</ul>
<h2>8.2.3</h2>
<h1>Bug fixes</h1>
<ul>
<li>When context takeover is enabled, messages are now compressed even if their size
is below the value of the <code>perMessageDeflate.threshold</code> option (41ae5631).</li>
</ul>
<h2>8.2.2</h2>
<h1>Bug fixes</h1>
<ul>
<li>Some closing operations are now run only if needed (ec9377ca).</li>
</ul>
<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>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="00c34d726d"><code>00c34d7</code></a> [dist] 8.4.0</li>
<li><a href="35d45c2a4f"><code>35d45c2</code></a> [perf] Skip masking and unmasking if the masking key is zero</li>
<li><a href="eb2e3a84a1"><code>eb2e3a8</code></a> [feature] Introduce the <code>generateMask</code> option</li>
<li><a href="c82b08737f"><code>c82b087</code></a> [dist] 8.3.0</li>
<li><a href="0a8c7a9c4f"><code>0a8c7a9</code></a> [api] Add <code>WebSocket#pause()</code> and <code>WebSocket#resume()</code></li>
<li><a href="ed2b803905"><code>ed2b803</code></a> [fix] Resume the socket in the <code>CLOSING</code> state</li>
<li><a href="b8186dd115"><code>b8186dd</code></a> [fix] Do not throw if the redirect URL is invalid (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1980">https://github.com/facebook/flipper/issues/1980</a>)</li>
<li><a href="5a905e49be"><code>5a905e4</code></a> [minor] Add missing label to the issue form</li>
<li><a href="89d81e8670"><code>89d81e8</code></a> [minor] Fix nit</li>
<li><a href="4916d03ad8"><code>4916d03</code></a> [minor] Allow to write frames with up to 2^48 - 1 bytes of data (<a href="https://github-redirect.dependabot.com/websockets/ws/issues/1973">https://github.com/facebook/flipper/issues/1973</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/websockets/ws/compare/7.5.6...8.4.0">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=ws&package-manager=npm_and_yarn&previous-version=7.5.6&new-version=8.4.0)](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/3218

Reviewed By: antonk52, timur-valiev

Differential Revision: D33348279

Pulled By: nikoant

fbshipit-source-id: c245f53556e8f58ba1df619d3d0e106e8e5b1911
2022-01-17 05:03:10 -08:00
Michel Weststrate
b6c884f011 Make sure flipper server initialization errors are propagated properly
Summary:
This diff makes sure that errors are propagated similarly in flipper desktop and browser version, and that they are shown in either case.

Since in the browser version, the UI loads after the error happened, we'll store the error so that any client connecting in the future will read and report it.

Also added a `--failFast` flag to flipper-server, so that the process exits immediately if misconfigured, which is convenient in CI use cases and such

Reviewed By: nikoant

Differential Revision: D33348922

fbshipit-source-id: 0f584104f881141fde38da3f0031748415343ea2
2022-01-04 02:57:25 -08:00
Michel Weststrate
8259f92983 Make sure Flipper server startup errors are propagated for desktop
Summary:
If openssl is not available, this would lead to an unhandled rejection exception. That is because a lot initialization logic generates promises that don't get a catch chained on immediately. Changed the flipper server startup flow to be more idiomatically async

Fixes https://github.com/facebook/flipper/issues/2766

Changelog: More clearly communicate if flipper server failed to start (e.d. due to port already taken, openssl not being available)

This change fixes it only for desktop flipper, will make sure the browser UI will support this as well (the error will fire correctly there, but there are no listeners during startup)

Reviewed By: nikoant

Differential Revision: D33348923

fbshipit-source-id: f561bb27b18a3041c514b37f7aed11435a49647f
2022-01-04 02:57:25 -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
cbda298b9d Add support to build flipper-server from SandCastle
Summary:
This refactors the flipper-server release script in such a way that it works the same as the normal release script, which solves two problems:

1) the official release script modifies versioned files, as it touches the package.json
2) it was slightly confusing that `flipper-server/static` was filled for release builds only, but not used in dev builds
3) running test:npx without running a release build before it, would fail with hard to comprehend errors. this has been solved now by removing that script and make it an arg of `build:flipper-server`

Also some further minor changes to prepare running a corresponding build / release job from SandCastle (later in this stack)

Reviewed By: nikoant

Differential Revision: D33297214

fbshipit-source-id: f6299aa982c3e59d1cc6479a93c56cbe4b57f85c
2021-12-24 07:18:11 -08:00
Michel Weststrate
72fa481d27 Fix generation of bundled.json, make source maps work in prod builds
Summary:
This diff fixes several issues around loading plugin, such as:

* make suresource maps work in the flipper-server production build
* make sure default plugins are no symlinked, which wouldn't work anywhere else but on the the system where it was build
* support release channel param for flipper-server

Bundled flipper-server is now 42MB (with icons (see later diffs) and plugins
```
ll flipper-server-v0.0.0.tgz
-rw-r--r--  1 mweststrate  staff    42M 23 Dec 15:29 flipper-server-v0.0.0.tgz
```

Reviewed By: nikoant

Differential Revision: D33294677

fbshipit-source-id: 63538dc8127f883fee6a3608673ad11ce239b350
2021-12-24 02:16:48 -08:00
Michel Weststrate
86b6d2c99d Make flipper-server NPX-able
Summary: Make sure flipper-server is bundled in such a way that it is self-contained NPX-able. Also added some checks to make sure that dev dependencies don't accidentallly end up in in Flipper buidls

Reviewed By: nikoant

Differential Revision: D33190254

fbshipit-source-id: 443162e537d8ca9f956acac2d7bd52cbf0c92172
2021-12-24 02:16:48 -08:00
Michel Weststrate
f9c769aee3 Fix Metro crash if no origin header is set
Summary:
Changelog: Work-around for missing `origin` header problem https://github.com/facebook/flipper/issues/3189; causing Metro to crash when Flipper tries to connect

Will follow up with separate fix in React Native itself as well

Reviewed By: nikoant

Differential Revision: D33276414

fbshipit-source-id: 34d1510262ac24172ac1c6660799bb755b0f1f11
2021-12-22 03:18:52 -08:00
Andrey Goncharov
5e3e777b5c Enable DownloadFile write stream error test (#3207)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/3207

Followup of D33191515 (e0afebeb32)

Reviewed By: mweststrate

Differential Revision: D33253520

fbshipit-source-id: 30bca740dd8674b9bbba4e157d27f2dcedbc5ed5
2021-12-21 08:10:49 -08:00
dependabot[bot]
3d28991cbe Bump axios from 0.21.4 to 0.24.0 in /desktop (#3166)
Summary:
Bumps [axios](https://github.com/axios/axios) from 0.21.4 to 0.24.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/axios/axios/releases">axios's releases</a>.</em></p>
<blockquote>
<h2>v0.24.0</h2>
<h3>0.24.0 (October 25, 2021)</h3>
<p>Breaking changes:</p>
<ul>
<li>Revert: change type of AxiosResponse to any, please read lengthy discussion here: (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4141">#4141</a>) pull request: (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4186">#4186</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/HEAD/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/ImRodry">Rodry</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/ITenthusiasm">Isaiah Thomason</a></li>
</ul>
<h2>v0.23.0</h2>
<h3>0.23.0 (October 12, 2021)</h3>
<p>Breaking changes:</p>
<ul>
<li>Distinguish request and response data types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4116">#4116</a>)</li>
<li>Change never type to unknown (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4142">#4142</a>)</li>
<li>Fixed TransitionalOptions typings (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4147">#4147</a>)</li>
</ul>
<p>Fixes and Functionality:</p>
<ul>
<li>Adding globalObject: 'this' to webpack config (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3176">https://github.com/facebook/flipper/issues/3176</a>)</li>
<li>Adding insecureHTTPParser type to AxiosRequestConfig (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4066">#4066</a>)</li>
<li>Fix missing semicolon in typings (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4115">#4115</a>)</li>
<li>Fix response headers types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4136">#4136</a>)</li>
</ul>
<p>Internal and Tests:</p>
<ul>
<li>Improve timeout error when timeout is browser default (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3209">#3209</a>)</li>
<li>Fix node version on CI (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4069">#4069</a>)</li>
<li>Added testing to TypeScript portion of project (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4140">#4140</a>)</li>
</ul>
<p>Documentation:</p>
<ul>
<li>Rename Angular to AngularJS (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4114">#4114</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/HEAD/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/Evan-Finkelstein">Evan-Finkelstein</a></li>
<li><a href="https://github.com/Jezorko">Paweł Szymański</a></li>
<li><a href="https://github.com/dobesv">Dobes Vandermeer</a></li>
<li><a href="https://github.com/caugner">Claas Augner</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/egmen">Evgeniy</a></li>
<li><a href="https://github.com/DigitalBrainJS">Dmitriy Mozgovoy</a></li>
</ul>
<h2>v0.22.0</h2>
<h3>0.22.0 (October 01, 2021)</h3>
<p>Fixes and Functionality:</p>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/axios/axios/blob/master/CHANGELOG.md">axios's changelog</a>.</em></p>
<blockquote>
<h3>0.24.0 (October 25, 2021)</h3>
<p>Breaking changes:</p>
<ul>
<li>Revert: change type of AxiosResponse to any, please read lengthy discussion here: (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4141">#4141</a>) pull request: (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4186">#4186</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/master/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/ImRodry">Rodry</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/ITenthusiasm">Isaiah Thomason</a></li>
</ul>
<h3>0.23.0 (October 12, 2021)</h3>
<p>Breaking changes:</p>
<ul>
<li>Distinguish request and response data types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4116">#4116</a>)</li>
<li>Change never type to unknown (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4142">#4142</a>)</li>
<li>Fixed TransitionalOptions typings (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4147">#4147</a>)</li>
</ul>
<p>Fixes and Functionality:</p>
<ul>
<li>Adding globalObject: 'this' to webpack config (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3176">https://github.com/facebook/flipper/issues/3176</a>)</li>
<li>Adding insecureHTTPParser type to AxiosRequestConfig (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4066">#4066</a>)</li>
<li>Fix missing semicolon in typings (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4115">#4115</a>)</li>
<li>Fix response headers types (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4136">#4136</a>)</li>
</ul>
<p>Internal and Tests:</p>
<ul>
<li>Improve timeout error when timeout is browser default (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3209">#3209</a>)</li>
<li>Fix node version on CI (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4069">#4069</a>)</li>
<li>Added testing to TypeScript portion of project (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4140">#4140</a>)</li>
</ul>
<p>Documentation:</p>
<ul>
<li>Rename Angular to AngularJS (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4114">#4114</a>)</li>
</ul>
<p>Huge thanks to everyone who contributed to this release via code (authors listed below) or via reviews and triaging on GitHub:</p>
<ul>
<li><a href="https://github.com/axios/axios/blob/master/mailto:jasonsaayman@gmail.com">Jay</a></li>
<li><a href="https://github.com/Evan-Finkelstein">Evan-Finkelstein</a></li>
<li><a href="https://github.com/Jezorko">Paweł Szymański</a></li>
<li><a href="https://github.com/dobesv">Dobes Vandermeer</a></li>
<li><a href="https://github.com/caugner">Claas Augner</a></li>
<li><a href="https://github.com/remcohaszing">Remco Haszing</a></li>
<li><a href="https://github.com/egmen">Evgeniy</a></li>
<li><a href="https://github.com/DigitalBrainJS">Dmitriy Mozgovoy</a></li>
</ul>
<h3>0.22.0 (October 01, 2021)</h3>
<p>Fixes and Functionality:</p>
<ul>
<li>Caseless header comparing in HTTP adapter (<a href="https://github-redirect.dependabot.com/axios/axios/pull/2880">https://github.com/facebook/flipper/issues/2880</a>)</li>
<li>Avoid package.json import fixing issues and warnings related to this (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4041">#4041</a>), (<a href="https://github-redirect.dependabot.com/axios/axios/pull/4065">#4065</a>)</li>
<li>Fixed cancelToken leakage and added AbortController support (<a href="https://github-redirect.dependabot.com/axios/axios/pull/3305">#3305</a>)</li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="53d6d37556"><code>53d6d37</code></a> Adding minfied files</li>
<li><a href="6d613b4fe4"><code>6d613b4</code></a> Updated changelog</li>
<li><a href="2c9cc76ee9"><code>2c9cc76</code></a> revert: change type of AxiosResponse to any (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4186">#4186</a>)</li>
<li><a href="1025d1231a"><code>1025d12</code></a> Release v0.23.0</li>
<li><a href="6d1e30fd80"><code>6d1e30f</code></a> Prepared release notes</li>
<li><a href="20e8b6bc8c"><code>20e8b6b</code></a> chore(docs): rename Angular to AngularJS (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4114">#4114</a>)</li>
<li><a href="94a9344799"><code>94a9344</code></a> Test types (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4140">#4140</a>)</li>
<li><a href="fce210a67e"><code>fce210a</code></a> Fixed TransitionalOptions typings (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4147">#4147</a>)</li>
<li><a href="547815d9fd"><code>547815d</code></a> Mending merge conflict</li>
<li><a href="e462973a4b"><code>e462973</code></a> fix response headers types (<a href="https://github-redirect.dependabot.com/axios/axios/issues/4136">#4136</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/axios/axios/compare/v0.21.4...v0.24.0">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=axios&package-manager=npm_and_yarn&previous-version=0.21.4&new-version=0.24.0)](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/3166

Reviewed By: passy

Differential Revision: D33234007

Pulled By: aigoncharov

fbshipit-source-id: 1be18f528a4f8eae84a7a19afec92d8b11ce7cf9
2021-12-20 13:52:52 -08:00
Andrey Goncharov
debf872806 Allow to start only one instance of log listener and crash watcher
Summary:
Changelog: Allow only a single crash watcher and a single log listener per device. Start log listener and crash watcher for every device upon connection. Remove commands to start/stop them externally.

Monitored CPU load for a physical Android device with the log listener on and off. Did not notice any real difference.

Resolved crashing adbkit-logcat by forcing the usage of 2.0.1. A proper fix would be to unify babel transforms for browser flipper and electron flipper, but we might re-think how we distribute flipper in the next half, so a simple hot fix might be a better use of time and resources.

Reviewed By: mweststrate

Differential Revision: D33132506

fbshipit-source-id: 39d422682a10a64830ac516e30f43f32f416819d
2021-12-20 11:39:01 -08:00
Andrey Goncharov
731749b41f Move crash reporting listener to the server
Summary: Changelog: Move crash watcher to the server. Add 'device-crash' event. Add 'device-start-crash-watcher', 'device-stop-crash-watcher' commands. Add 'onDeviceCrash' method to Plugin Client.

Reviewed By: mweststrate

Differential Revision: D33089810

fbshipit-source-id: ed62ee7c1129e5e25af18b444744b0796f567b72
2021-12-20 11:39:00 -08:00
Michel Weststrate
e0afebeb32 Disabled consistently failing OSS test (#3188)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/3188

Fixes failing typescript issue (probably case sensitivity thing, on windows it was complaining about `Metro` not being resolvable while we use `metro` everywhere). Put a `ts-ignore` on it, since the metro typings we use are empty anyway

Disabled a test that failed consistently on GH CI. Maybe timing or Node version issue?

Reviewed By: fabiomassimo

Differential Revision: D33191515

fbshipit-source-id: 18a143024824eeeafaffe4941df474591fb7b70a
2021-12-17 14:03:53 -08:00
Michel Weststrate
d9488f06ac Clean up flipper-ui-core deps
Summary: Noticed that flipper-ui-core bundled quite some unused / node based deps. No longer

Reviewed By: aigoncharov

Differential Revision: D33184489

fbshipit-source-id: a180f9b8f3eb00ffa6c91e0cca654d4b9b609692
2021-12-17 10:04:23 -08:00
Michel Weststrate
cea7be7fde Clean up globals
Summary: This diff is some boyscouting on cleaning up our globals, and stop using them inconsistently icmw global or window

Reviewed By: aigoncharov

Differential Revision: D33171108

fbshipit-source-id: 400893e5f31523631a7ab6fda428524c751901f1
2021-12-17 10:04:23 -08:00
Michel Weststrate
8f40949bb0 clean slate package resolutions
Summary:
Over time we collected a lot of harcoded resolutions, but it is really hard to get signal about their sanity:
* some resolutions generate a lot of yarn warnings as they resolve with a different major than required, and it's really hard to tell whether they actually make things worse or better
* some resolutions are for package we don't even use any more
* some resolutions were there to fix type incompatibilities which have been solved now by keeping them uniquely required
* some resolutions are there to fix "security issues" or security issues in transient dependencies that might have been upgraded int he mean time

So this diff radically removes all of them, trusting Github to propose restoring the sane ones of them :). In terms of functionality everything seems to be working at least

Reviewed By: timur-valiev

Differential Revision: D33158981

fbshipit-source-id: 83e74cdbc8e47ccbf554b97620cf7caa2c6599ce
2021-12-17 07:36:07 -08:00