Summary:
Simplifies medium usage. Clients report this value as an integer. Internally, we transform this integer as type (a set of valid strings).
Instead of transform this value in different places, do it once when the client query is received.
Reviewed By: antonk52
Differential Revision: D46358024
fbshipit-source-id: ecd2b6c6ccbe7c38787a89d4e2f81930c7b91864
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/4794
Reviewed By: antonk52
Differential Revision: D46355046
Pulled By: passy
fbshipit-source-id: e676d4c9d8bef0b3ab29bc9e6cb23838b262c5bf
Summary:
Bumps [com.google.protobuf:protobuf-java](https://github.com/protocolbuffers/protobuf) from 3.23.1 to 3.23.2.
<details>
<summary>Commits</summary>
<ul>
<li><a href="a74f54b724"><code>a74f54b</code></a> Updating version.json and repo version numbers to: 23.2</li>
<li><a href="45ddc11b50"><code>45ddc11</code></a> Update upb dependency (<a href="https://redirect.github.com/protocolbuffers/protobuf/issues/12907">#12907</a>)</li>
<li><a href="91e5e6e76d"><code>91e5e6e</code></a> Merge pull request <a href="https://redirect.github.com/protocolbuffers/protobuf/issues/12906">#12906</a> from mkruskal-google/java-fix-23</li>
<li><a href="b556b8871c"><code>b556b88</code></a> Automated rollback of commit 4d76f12a82bc53cc2d846e65dd8c4bce6c1d4645.</li>
<li><a href="ab367ad73d"><code>ab367ad</code></a> Merge pull request <a href="https://redirect.github.com/protocolbuffers/protobuf/issues/12852">#12852</a> from fowles/23.x</li>
<li><a href="5bc7e02036"><code>5bc7e02</code></a> fix missing int32_t (<a href="https://redirect.github.com/protocolbuffers/protobuf/issues/12554">#12554</a>)</li>
<li><a href="a171d20df3"><code>a171d20</code></a> Merge pull request <a href="https://redirect.github.com/protocolbuffers/protobuf/issues/12845">#12845</a> from protocolbuffers/23.x-202305171614</li>
<li><a href="3cda141b4d"><code>3cda141</code></a> Updating version.json to: 23.2-dev</li>
<li>See full diff in <a href="https://github.com/protocolbuffers/protobuf/compare/v3.23.1...v3.23.2">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/4779
Reviewed By: antonk52
Differential Revision: D46355076
Pulled By: passy
fbshipit-source-id: 72e493ea24b11a00d5fec978489d78fc048bc9de
Summary:
Until now when we filter by a column value we only get the items that match this value exactly.
Release: we can add loose filters that match value or `undefined`
Reviewed By: lblasa, ivanmisuno
Differential Revision: D46318631
fbshipit-source-id: 94ecb3f074674d4b0ce3a480f4f3b9ddc058ceef
Summary:
^
Basically, update Jest and fix any raised issues. Mainly:
- Update necessary dependencies
- Update snapshots
- `useFakeTimers` caused a few issues which meant that the way we hook into the performance object had to be tweaked. The main code change is: `//fbsource/xplat/sonar/desktop/scripts/jest-setup-after.tsx`
- `mocked` -> `jest.mocked`
Changelog: Update Jest to v29.5.1
Reviewed By: antonk52
Differential Revision: D46319818
fbshipit-source-id: d218ca8f7e43abac6b00844953ddeb7f4e1010a2
Summary: On my mac localhost resolves to an IP6 address by the new adb lib. This should fix it.
Reviewed By: LukeDefeo
Differential Revision: D46314612
fbshipit-source-id: 3771efd2c6b79fe9ae9851ce4aac35bcede28847
Summary:
It seems the available binary for macOS arm64 is not signed:
```
codesign -dv --verbose=4 ./node-v16.16.0-macos-arm64
./node-v16.16.0-macos-arm64: code object is not signed
```
This is an issue as it crashes for our flipper server releases.
This can be compared to a binary downloaded from the Node distribution page:
```
codesign -dv --verbose=4 ./node
Executable=/Users/realpassy/Downloads/node-v16.15.0-darwin-arm64/bin/node
Identifier=node
Format=Mach-O thin (arm64)
CodeDirectory v=20500 size=597360 flags=0x10000(runtime) hashes=18657+7 location=embedded
VersionPlatform=1
VersionMin=720896
VersionSDK=721152
Hash type=sha256 size=32
CandidateCDHash sha256=31cdf84cac42a622c1a68558376700a2dd12d40d
CandidateCDHashFull sha256=31cdf84cac42a622c1a68558376700a2dd12d40d81c5118f3b0e0370c414eb69
Hash choices=sha256
CMSDigest=31cdf84cac42a622c1a68558376700a2dd12d40d81c5118f3b0e0370c414eb69
CMSDigestType=2
Executable Segment base=0
Executable Segment limit=56082432
Executable Segment flags=0x1
Page size=4096
Launch Constraints:
None
CDHash=31cdf84cac42a622c1a68558376700a2dd12d40d
Signature size=8986
Authority=Developer ID Application: Node.js Foundation (HX7739G8FX)
Authority=Developer ID Certification Authority
Authority=Apple Root CA
Timestamp=26 Apr 2022 at 23:00:57
Info.plist=not bound
TeamIdentifier=HX7739G8FX
Runtime Version=11.1.0
Sealed Resources=none
Internal requirements count=1 size=164
```
For additional context:
Node binary by using pkg-fetch. We just get the binary from this release page: https://github.com/vercel/pkg-fetch/releases/tag/v3.4
The exact binary we're downloading is https://github.com/vercel/pkg-fetch/releases/download/v3.4/node-v16.15.0-macos-arm64
If you just download that via Chrome, it will trigger Gatekeeper and you need to manually click "Allow" in the system privacy settings. You can also do the same by just running:
xattr -c ./node-v16*
Afterwards you can:
chmod +x ./node*
It will crash in the same way that it does after our distribution.
Reviewed By: passy
Differential Revision: D46225503
fbshipit-source-id: f0ae2d5101b99c9db7fe80333573caef52c787a2
Summary: It is hard to pass auth token to Jest E2E tests.
Reviewed By: lblasa
Differential Revision: D46279204
fbshipit-source-id: ee0138c3bd014bafb416f7fa8951fb25b25b4067
Summary: It seems that adb path has changed on the jest-e2e side. That might case the flipper e2e test failure. With this fallback we have granular control of the path.
Reviewed By: antonk52
Differential Revision: D46278512
fbshipit-source-id: 97310459de54eeb003eefb3a3ff06af8b13bebae
Summary:
Need to answer:
- Certificate exchange success rate, fails and errors a day per OS and device type.
Reviewed By: antonk52
Differential Revision: D46221301
fbshipit-source-id: 03c6993aa15f56fdf98a7abd57d00b2af0e9ce1a
Summary: Same as previous diff but for plain socket.
Reviewed By: antonk52
Differential Revision: D46220933
fbshipit-source-id: 235ca860891b8514dd0d743d32fe85f15a2cdd7e
Summary: Same as previous diff but for TLS attempts.
Reviewed By: antonk52
Differential Revision: D46220897
fbshipit-source-id: 9495c39edffbdebe0ba21ec7320b63bad8759dde
Summary:
Need to answer:
- How many app connections a day/week?
- How many connections a day/week per app?
- How many connections a day/week per os?
- How many connections a day/week over WWW exchange?
- How many connections a day/week over FS exchange?
- How many connections over a device?
- How many connections over a simulator?
Reviewed By: antonk52
Differential Revision: D46220581
fbshipit-source-id: 6783f49b59cba91cd04625044314973d98cef301
Summary:
Need to answer:
- How many starts a day over time
Reviewed By: antonk52
Differential Revision: D46219995
fbshipit-source-id: bffaeadf684a2d34c6e145784c5a86dbaf5f532a
Summary:
Need to answer:
- Proxy errors rate over time
Reviewed By: antonk52
Differential Revision: D46219927
fbshipit-source-id: 1ad8cc60303ed3aa34828b9ff87009ff7754a146
Summary:
Some times the socket can already be in use by an existing process. Track it as to quantify how likely this is found in production. May remove later.
Need to answer:
- Socket already in use rate over time
Reviewed By: antonk52
Differential Revision: D46219768
fbshipit-source-id: 27da82cddb707f729a1d43079e84c221bb544a82
Summary:
Define the tracker interface and replace the existing authentication token verification tracking.
Subsequent diffs will add analytics for remaining connectivity areas.
Need to answer:
- No tokens rate over time
- Unable to verify tokens rate over time
Reviewed By: antonk52
Differential Revision: D46219661
fbshipit-source-id: dfc41cae664bc1ef211d312990120111fca3808b
Summary:
Brotli response decoding was introduced via https://github.com/facebook/flipper/pull/4288, and released in 0.177.0. We noticed from that release that many of our iOS response bodies were not being rendered. It simply showed `(empty)` in the `Response Body` section.
As noted in the gzip decoder ([here](2a52656d0b/desktop/plugins/public/network/utils.tsx (L117-L119))) within Flipper, iOS already provides an inflated `data` value, so it doesn't need inflating again.
This PR adds a best-effort guess to detect when the same problem arises in the Brotli decoder.
I'm definitely not a Brotli expert, but according to [this SO post](https://stackoverflow.com/questions/39008957/is-there-a-way-to-check-if-a-buffer-is-in-brotli-compressed-format), there's no sure-fire way to detect Brotli data, and some blobs of random data will still present as Brotli. We may still occasionally see false positives that continue to show `(empty)`, however in my testing, all of our server responses have rendered JSON responses perfectly.
The library used for decoding doesn't throw an error on failure with any responses we've seen, it just simply returns a 0-length buffer. So the naïve approach taken in this PR simply looks for a 0-length output buffer on a non-zero-length input buffer, and concludes "probably not Brotli, shrug emoji".
## Changelog
Ignore Brotli decode result on 0-length return value
Pull Request resolved: https://github.com/facebook/flipper/pull/4632
Test Plan:
We can use Facebook's servers to test this. Fire up a RN app, and add the following somewhere you can run it:
```typescript
fetch('https://graph.facebook.com/facebook/picture?redirect=false', {
headers: {
'accept-encoding': 'br',
},
})
```
Before this patch, we can see that `Response Body` is `(empty)` in Flipper:
<img width="1211" alt="Screenshot 2023-03-30 at 1 26 48 am" src="https://user-images.githubusercontent.com/33126/228690254-988b5a01-5d7b-4ab3-b6dc-49f3b0607d10.png">
But after this patch, we can see some valid JSON in the `Response Body`:
<img width="1213" alt="Screenshot 2023-03-30 at 1 26 07 am" src="https://user-images.githubusercontent.com/33126/228690351-9611759a-5b7d-4ccb-9170-22b950c8afbe.png">
Most importantly, both responses have `Content-Encoding: br` headers.
Reviewed By: passy
Differential Revision: D46219337
Pulled By: mweststrate
fbshipit-source-id: 2ae775d381fa325c6d9e543bdbc617d1fd986671
Summary:
The file manifest.json is injected with the auth token and it happens with every launch.
Because the file is tracked, these changes will always get picked no matter what the .gitignore file specifies, because is a tracked file.
So, the solution is to have a template with a different name, that gets copied into the right location during build time.
Reviewed By: LukeDefeo
Differential Revision: D46184772
fbshipit-source-id: 938b9433045485d9846a6a50c1c955ebe7925581
Summary:
Replace an existing running instance, if any.
This is useful for:
- Applying updates
- Ensuring freshness of server
Reviewed By: passy
Differential Revision: D46146814
fbshipit-source-id: bfb760f3ab26b7632510773609f1c6ca3a97c4ec
Summary:
Right now, this simply avoids trying to create a server instance if one appears to be already running.
In a future change, we may decide to kill the existing instance and replace it with a new one.
But, in this case, running this as is will be useful as it will provide the connection URL with the auth token.
Also remove flipper server dependency from finding installation. In this case, we don't need it and can use `os.getPlatform()` instead.
Reviewed By: antonk52
Differential Revision: D46144843
fbshipit-source-id: 2922843b916d37e0126e43ae65a622f87a6920ec
Summary: We didn't define the build for aarch64 locally previously, so packer didn't know how to bundle it up. Since it shares the layout of x64, we will also save on CDN resources because it will automatically get deduplicated.
Reviewed By: lblasa, antonk52
Differential Revision: D46144879
fbshipit-source-id: 20087010db02d3965ed0c5d4add72e0b19849d13
Summary:
There's a picture with a broken link in the hero section:
{F999641292}
I checked a list of existing static images and found one which was on this place before: https://fburl.com/code/yh73399d. But the image no longer align with others, since it has low resolution and an old version of the Flipper interface, so I decided to simply remove the broken image from the page.
Reviewed By: passy
Differential Revision: D46074714
fbshipit-source-id: 186b17b9b992f123fc667c701b4f49d9e3cbbb2d