Summary: in FlipperRSocketResponder::handleFireAndForget, a responder object was being conditionally (for requests with an "id" field) created, resulting in a null pointer passed into FlipperClient::onMessageReceived when no id was present. FlipperClient::onMessage received, in the meantime, unconditionally dereferences that pointer, resulting in a segmentation fault. This change creates the responder object regardless of whether or not the "id" key is present in the request object, thus avoiding passing a null pointer into FlipperClient::onMessageReceived.
Reviewed By: jknoxville
Differential Revision: D18583898
fbshipit-source-id: 2112c45bc0cd639cec908d0039d6bdaed2f61491
Summary:
Well, now I feel dumb. That should have definitely been caught earlier.
I'll set up a CI job to verify this.
Fixes https://github.com/facebook/flipper/issues/648
Reviewed By: jknoxville
Differential Revision: D18657185
fbshipit-source-id: 5fea08103f5a4292159b519d62d84800c0444e41
Summary: Mimicking the workplace markdown style so people feel more familiar with it and don't get surprises when posting.
Reviewed By: passy
Differential Revision: D18639041
fbshipit-source-id: 0097087b8ae4da8e29609604eeffd5b349ebe7ab
Summary:
The spacing above headings didn't look right.
Also workplace purposely limits the different heading sizes to 2 to encourage using notes for large posts. So I'm changing this to match. If we need to have arbitrary depth in future, we can add a `workplaceMode` toggle, but so far that's the only use case we have.
Reviewed By: mweststrate
Differential Revision: D18638861
fbshipit-source-id: 3949a37515e4282bb8435c2740ef45a55e5a97cc
Summary:
Adds a side-by-side markdown preview to the support form.
No time spent on UI because it makes sense to do it all together.
There also seems to be a problem with state updates not propagating when values are changed, so currently it never gets updated.
Reviewed By: passy
Differential Revision: D18638025
fbshipit-source-id: c4a49286434c7e2e85d532aef3a36924e02a4467
Summary:
This reverts commit 5bd0cd3d63 and adds back the github actions which were temporarily disabled.
Pull Request resolved: https://github.com/facebook/flipper/pull/655
Reviewed By: passy
Differential Revision: D18656754
Pulled By: jknoxville
fbshipit-source-id: 9dc9a9aa4224f996677ddfbaf37387ae0b066c56
Summary:
### Connecting Flipper with JS apps by using electron's BrowserWindow and IPC
1. UI: there is a menu item in Devices tab which opens JS Emulator Launcher Sheet. Here we can configure URL to open and initial size of the window.
2. BrowserWindow, preloaded js: there is SupportJSClientPreload.js which initialize communication between flipper and app via electron's ipc
3. On flipper's side there is src/utils/js-client/serverUtils.tsx which contains most of JS emulator related code
4. Extracting of FlipperClientConnection: since we don't use RScocket to communicate with JS app I extracted needed methods to FlipperClientConnection (located in Client) and partly implemented them in JSClientFlipperConnection (requestResponse is just send a message now, doesn't return actual result)
Reviewed By: jknoxville
Differential Revision: D18572882
fbshipit-source-id: 56d1ca1a60ed2e51329b917021a09382cbb1ceec
Summary: If the GK is enabled, get the new litho support form from the sidebar!
Reviewed By: jknoxville
Differential Revision: D18639060
fbshipit-source-id: c10a32fc4725374dbd6d89e16944642d3124037e
Summary:
Styles the create support request form similarly to the details form, using the standard UI components.
N.B. Video section styling will be a separate diff
Reviewed By: jknoxville
Differential Revision: D18637989
fbshipit-source-id: f1cc6967b6841a55e770043f330e1a87ac7bfb50
Summary: I hope this will lower the support load for this a little.
Reviewed By: jknoxville
Differential Revision: D18638565
fbshipit-source-id: 57ce7f6855817a49bafab35517cf1e8ef2bc2e1e
Summary: Failing OSS check because of this right now.
Reviewed By: cekkaewnumchai
Differential Revision: D18638744
fbshipit-source-id: 1e5076f69a40f7dea87078c346e85f1797de42aa
Summary:
Long-standing 'security' issue. Doesn't matter for a static
site generator with controlled input, of course, but
we're failing our OSS validation if we just dismiss it.
Reviewed By: cekkaewnumchai
Differential Revision: D18638722
fbshipit-source-id: d8636dee67826c4e453ac0f74cd3dfa8f77ba0dd
Summary:
This diff enables a full roundtrip of exporting a bug report to file / link, and importing it again.
Styling is not part of this story.
Reviewed By: jknoxville
Differential Revision: D18636418
fbshipit-source-id: ef9a8e3622bdac9361f612d51415a593f4268b80
Summary:
This diff makes it possible to apply MC's to a currently running as part of the support form process.
Things _NOT_ done in the diff:
* make sure getUniverses and getGatekeepers returns valid configs (this broke since somewhere last week, opened T57918601 for that. However, before that this worked correctly
* provide a more interactive UI when applying MC's, such as beeing able to see a diff preview, ask confirmation before overriding current config, etc
Reviewed By: jknoxville
Differential Revision: D18452172
fbshipit-source-id: da3f24bccf88260282f86e2564e983a9ee217c2f
Summary: Just to distinguish this from the other bug reporter we have.
Reviewed By: cekkaewnumchai
Differential Revision: D18636872
fbshipit-source-id: d7bfca3908083d198647af90aa6d9d1c615e6a44
Summary:
It's camelCase for props in JS.
Would be good to have a linter for this in place.
Pull Request resolved: https://github.com/facebook/flipper/pull/646
Test Plan: yarn flow
Reviewed By: jknoxville
Differential Revision: D18613822
Pulled By: passy
fbshipit-source-id: 9cf03b2a02c7802853edb15cbde8df998df5deb2
Summary:
This diff introduces a set of components:
VBox: use this to group things vertically, it little more than a container that fills the full width and adds bottom margin (see screenshot: creating distance between the boxes)
HBox: use to divide a space horizontal in two, and distribute it over two children, supports growing the right side, left side or both equally. In the image used to reserve the necessary width for the image, and give the remaining space to the text
Info: A component that shows a message, prestyled with one of the four types: info, error, warning, pending.
{F222993480}
Reviewed By: jknoxville
Differential Revision: D18595291
fbshipit-source-id: 1957db1b606b2e44e3104b10d32ad8ce75af6adc
Summary: Collections of errors were not reported correctly in the UI. Also, reporting errors could crash flipper if the error is not serializable (for example due to being cyclic).
Reviewed By: jknoxville
Differential Revision: D18595257
fbshipit-source-id: 689b6dbfe5d7daa6d84bd703dba9daa6be2e6b82
Summary:
## The dependency [rsocket-tcp-server](https://github.com/rsocket/rsocket-js) was updated from `0.0.16` to `0.0.17`.
This version is **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
---
**Publisher:** [stevegury](https://www.npmjs.com/~stevegury)
**License:** BSD-3-Clause
[Find out more about this release](https://github.com/rsocket/rsocket-js).
---
<details>
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/650
Reviewed By: passy
Differential Revision: D18626836
Pulled By: cekkaewnumchai
fbshipit-source-id: d47926f1119f369676e42a346be8953b4a90a708
Summary:
## The dependency [rsocket-core](https://github.com/rsocket/rsocket-js) was updated from `0.0.16` to `0.0.17`.
This version is **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
---
**Publisher:** [stevegury](https://www.npmjs.com/~stevegury)
**License:** BSD-3-Clause
[Find out more about this release](https://github.com/rsocket/rsocket-js).
---
<details>
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/649
Reviewed By: passy
Differential Revision: D18626827
Pulled By: cekkaewnumchai
fbshipit-source-id: e3b7a05f6eaa987feb9cac8bee0b27eb54e14fe4
Summary:
- Basic Doctor UI showing issues with installation
- Run healthchecks in background on startup and show warning message if something is wrong
Reviewed By: jknoxville
Differential Revision: D18502599
fbshipit-source-id: 194939a080ba7412ed3293d95c533bfad7031d3b
Summary:
## The devDependency [electron](https://github.com/electron/electron) was updated from `7.1.1` to `7.1.2`.
This version is **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
---
**Publisher:** [electron-nightly](https://www.npmjs.com/~electron-nightly)
**License:** MIT
[Find out more about this release](https://github.com/electron/electron).
---
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/645
Test Plan: Imported from GitHub, without a `Test Plan:` line
Reviewed By: jknoxville
Differential Revision: D18613576
Pulled By: cekkaewnumchai
fbshipit-source-id: eddfbb3571c79ba79fae8078c98d74090cbff4f6
Summary:
## The dependency [yargs](https://github.com/yargs/yargs) was updated from `14.2.1` to `15.0.1`.
This version is **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
---
**Publisher:** [bcoe](https://www.npmjs.com/~bcoe)
**License:** MIT
<details>
<summary>Release Notes for yargs v15.0.1</summary>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> cliui, find-up, and string-width, all drop Node 6 support (<a href="https://www.github.com/yargs/yargs/issues/1479">#1479</a>) (<a href="6a9ebe2d95">6a9ebe2</a>)</li>
</ul>
</details>
<details>
<summary>Commits</summary>
<p>The new version differs by 22 commits ahead by 22, behind by 2.</p>
<ul>
<li><a href="aa09faf708"><code>aa09faf</code></a> <code>chore: release 15.0.1 (#1480)</code></li>
<li><a href="6a9ebe2d95"><code>6a9ebe2</code></a> <code>fix(deps): cliui, find-up, and string-width, all drop Node 6 support (#1479)</code></li>
<li><a href="5cc2b5e15b"><code>5cc2b5e</code></a> <code>chore: release 15.0.0 (#1462)</code></li>
<li><a href="62a114a90a"><code>62a114a</code></a> <code>force build</code></li>
<li><a href="1840ba22f1"><code>1840ba2</code></a> <code>feat: expose <code>Parser</code> from <code>require('yargs/yargs')</code> (#1477)</code></li>
<li><a href="afd5b4871b"><code>afd5b48</code></a> <code>fix(docs): update boolean description and examples in docs (#1474)</code></li>
<li><a href="c10c38cca0"><code>c10c38c</code></a> <code>feat(deps)!: yargs-parser now throws on invalid combinations of config (#1470)</code></li>
<li><a href="0cba424d8b"><code>0cba424</code></a> <code>build: switch to release-please for releases (#1471)</code></li>
<li><a href="445bc587d8"><code>445bc58</code></a> <code>chore: update engines to note Node 6 is dropped (#1469)</code></li>
<li><a href="52d875a46d"><code>52d875a</code></a> <code>test: add additional test for 1459</code></li>
<li><a href="12c82e6266"><code>12c82e6</code></a> <code>fix: stop-parse was not being respected by commands (#1459)</code></li>
<li><a href="b4812ac99a"><code>b4812ac</code></a> <code>test: add tests for argsert warning to display positional information (#1468)</code></li>
<li><a href="10f10ee189"><code>10f10ee</code></a> <code>test: cover missing filter arg in obj-filter (#1467)</code></li>
<li><a href="cb0396fda2"><code>cb0396f</code></a> <code>build: switch to c8 for coverage (#1464)</code></li>
<li><a href="ebee59d902"><code>ebee59d</code></a> <code>fix!: update to yargs-parser with fix for array default values (#1463)</code></li>
</ul>
<p>There are 22 commits in total.</p>
<p>See the <a href="2fe88f5e22...aa09faf708">full diff</a></p>
</details>
---
<details>
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/643
Reviewed By: cekkaewnumchai
Differential Revision: D18595724
Pulled By: passy
fbshipit-source-id: d2d1352d27e3059334ba71bfaa02929ef22e6861
Summary:
## There have been updates to the *react* monorepo:
- The `dependency` [react](https://github.com/facebook/react) was updated from `16.11.0` to `16.12.0`.
- The `dependency` [react-dom](https://github.com/facebook/react) was updated from `16.11.0` to `16.12.0`.
- The `dependency` [react-test-renderer](https://github.com/facebook/react) was updated from `16.11.0` to `16.12.0`.
These versions are **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
This monorepo update includes releases of one or more dependencies which all belong to the [react group definition](https://github.com/greenkeeperio/monorepo-definitions).
---
**Publisher:** [lunaruan](https://www.npmjs.com/~lunaruan)
**License:** MIT
[Find out more about this release](https://github.com/facebook/react).
---
<details>
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/640
Reviewed By: jknoxville
Differential Revision: D18527628
Pulled By: passy
fbshipit-source-id: 712f7be03091ee7f7de08408714cc599c9f1fe42
Summary: On Android, the stack trace looks different so we don't need to use the Regex we use on iOS. We can simply display all the lines in the trace.
Reviewed By: pasqualeanatriello
Differential Revision: D17181400
fbshipit-source-id: e471da17b89806a161edc7edcf05ac6faed44bf0
Summary: This will correctly show all view children instead of reverting to the non-ax default behavior. Fixes bug where recycler views showed no children.
Reviewed By: jknoxville
Differential Revision: D18574220
fbshipit-source-id: f22606fb582e0bfd1a171dc4497e1d1613e800d1
Summary: Show the simple name instead of the node info class since this is taken into account for the attributes.
Reviewed By: jknoxville
Differential Revision: D18574219
fbshipit-source-id: 4b134e8be18c313e08df423dcdbe286d96c80b56
Summary:
Adds a Markdown component to the component library.
The react-markdown library doesn't work out of the box because elements it outputs don't have any styles, e.g. h1, h2, p, em, etc.
So I've added a custom renderer to give styles to each of these that workplace markdown uses.
The only one I haven't done at the moment that I'm aware of is numbered-lists.
There's probably a way to get back the original styling of these elements so we don't need a custom renderer, but this works for now, and also allows us to customise their appearance.
Reviewed By: passy
Differential Revision: D18533085
fbshipit-source-id: a4332a11d34d577a6300074e4dde126362d46a6b
Summary:
Not the most recent release but this upgrade works now
with the stack of diffs underneath. Will do 0.112 next.
Reviewed By: mweststrate
Differential Revision: D18527871
fbshipit-source-id: 2346b9dac86768deec7b3cb9039adb1d76cb2d7e
Summary:
This diff migrates the current state variables of the support form to the redux store, so that they can be persisted. This change will make them exportable and also solve the bug, where user navigates away from the form and comes back to see the support form's data vanished.
Right now the videos are not persisted, as its uploading bit is a work in progress.
Reviewed By: passy
Differential Revision: D18531674
fbshipit-source-id: b1e824377da55cf531312920ff1bb5b862a12010
Summary: This fixes a regression bug introduced by the rework sidebar selection: when trying to export a Flipper Trace flipper would error: 'No client exported' after making plugin selection
Reviewed By: priteshrnandgaonkar
Differential Revision: D18571143
fbshipit-source-id: c7a292e53cb79d0b2d95e09f8e9b041ae0d711cf
Summary:
## The dependency [yargs](https://github.com/yargs/yargs) was updated from `14.2.1` to `15.0.1`.
This version is **not covered** by your **current version range**.
If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.
---
**Publisher:** [bcoe](https://www.npmjs.com/~bcoe)
**License:** MIT
<details>
<summary>Release Notes for yargs v15.0.1</summary>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> cliui, find-up, and string-width, all drop Node 6 support (<a href="https://www.github.com/yargs/yargs/issues/1479">#1479</a>) (<a href="6a9ebe2d95">6a9ebe2</a>)</li>
</ul>
</details>
<details>
<summary>Commits</summary>
<p>The new version differs by 22 commits ahead by 22, behind by 2.</p>
<ul>
<li><a href="aa09faf708"><code>aa09faf</code></a> <code>chore: release 15.0.1 (#1480)</code></li>
<li><a href="6a9ebe2d95"><code>6a9ebe2</code></a> <code>fix(deps): cliui, find-up, and string-width, all drop Node 6 support (#1479)</code></li>
<li><a href="5cc2b5e15b"><code>5cc2b5e</code></a> <code>chore: release 15.0.0 (#1462)</code></li>
<li><a href="62a114a90a"><code>62a114a</code></a> <code>force build</code></li>
<li><a href="1840ba22f1"><code>1840ba2</code></a> <code>feat: expose <code>Parser</code> from <code>require('yargs/yargs')</code> (#1477)</code></li>
<li><a href="afd5b4871b"><code>afd5b48</code></a> <code>fix(docs): update boolean description and examples in docs (#1474)</code></li>
<li><a href="c10c38cca0"><code>c10c38c</code></a> <code>feat(deps)!: yargs-parser now throws on invalid combinations of config (#1470)</code></li>
<li><a href="0cba424d8b"><code>0cba424</code></a> <code>build: switch to release-please for releases (#1471)</code></li>
<li><a href="445bc587d8"><code>445bc58</code></a> <code>chore: update engines to note Node 6 is dropped (#1469)</code></li>
<li><a href="52d875a46d"><code>52d875a</code></a> <code>test: add additional test for 1459</code></li>
<li><a href="12c82e6266"><code>12c82e6</code></a> <code>fix: stop-parse was not being respected by commands (#1459)</code></li>
<li><a href="b4812ac99a"><code>b4812ac</code></a> <code>test: add tests for argsert warning to display positional information (#1468)</code></li>
<li><a href="10f10ee189"><code>10f10ee</code></a> <code>test: cover missing filter arg in obj-filter (#1467)</code></li>
<li><a href="cb0396fda2"><code>cb0396f</code></a> <code>build: switch to c8 for coverage (#1464)</code></li>
<li><a href="ebee59d902"><code>ebee59d</code></a> <code>fix!: update to yargs-parser with fix for array default values (#1463)</code></li>
</ul>
<p>There are 22 commits in total.</p>
<p>See the <a href="2fe88f5e22...aa09faf708">full diff</a></p>
</details>
---
<details>
<summary>FAQ and help</summary>
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>
---
Your [Greenkeeper](https://greenkeeper.io) bot 🌴
Pull Request resolved: https://github.com/facebook/flipper/pull/642
Test Plan:
Imported from GitHub, without a `Test Plan:` line.
`yarn start` run
Reviewed By: mweststrate
Differential Revision: D18561405
Pulled By: cekkaewnumchai
fbshipit-source-id: 10548df44311e74630e047004f22307a7339b673
Summary:
Created as standard layout that can be used for both the import and export form
Standardized components used, so that we work towards a Design Framework that is consistent. Took inspiration from some existing plugins.
Also fixed weird sidebar transparency.
Reviewed By: passy
Differential Revision: D18504078
fbshipit-source-id: 7649abf7aa3eba8ba635337a41274bba93738e81
Summary:
- Make sure newly connecting apps are automatically selected
- Improved the sidebar UI by using more consistent, spacious styling, and giving some more attention to error states
Reviewed By: passy
Differential Revision: D18505636
fbshipit-source-id: 18b2c8e78be13aabb3a54c60553f6b0d1e613b27
Summary:
sadface
Hopefully this can be reverted quickly but right now we don't have
Actions support in our org and the failures here are causing all
sorts of downstream errors.
Pull Request resolved: https://github.com/facebook/flipper/pull/639
Test Plan: This PR
Reviewed By: cekkaewnumchai
Differential Revision: D18506405
Pulled By: passy
fbshipit-source-id: 325209d91b5d985772195703a3429e49700d7666
Summary:
Currently most components are shown anonymously in the component tree, because using `styled` creates unnamed components, shown as the HTML elements they result in.
This has two downsides:
1. React errors / warnings are really vague and it is hard to locate where they are coming from
2. The React Devtools don't show which components are rendering.
3. The effect of the latter it is hard to copy-from-example when developing plugins. This leads to a lot of inconsitency and duplication in the layouts of components
Reviewed By: jknoxville
Differential Revision: D18503675
fbshipit-source-id: 5a9ea1765346fb4c6a49e37ffa4d0b4bbcd86587
Summary:
Effectively just removes and re-installs but that way we know
we have everything we need.
Reviewed By: jknoxville
Differential Revision: D18479831
fbshipit-source-id: 5d47abfc660288e1137f393534512997e8b3f83e
Summary:
Display is functional, the update itself isn't just yet.
Want to keep this easier to review. Instead of GK, I just
have a top-level toggle for now, because that will go
away with one of the next diffs anyway.
Reviewed By: jknoxville
Differential Revision: D18479290
fbshipit-source-id: b49394d4ab681c9d1dc5db0e4bee54f9255494b9
Summary:
To be used in the following diff and because it's super side effect
heavy, I didn't bother to implement tests for it.
Reviewed By: jknoxville
Differential Revision: D18479311
fbshipit-source-id: 5cbcae0ebf2de4558b993325e50f6a2da1ed3ea7
Summary:
This diff adds one more section in the Support Screen V2. This section records and displays the emulator screen. Right now the videos are stored at the very same location where our currently recorded videos are stored. For displaying them on UI I have used `react-player` dependency.
For the upload bit:
I will see how the exisiting e2e tests upload videos and if we can use their approach. Or else we can just upload videos on everstore and export its handle as part of flipper trace. The last resort can be to base64 encode it along with the trace.
Reviewed By: mweststrate
Differential Revision: D18460779
fbshipit-source-id: 8ddd51f59e5237a1a80f05bf90dfc3bead651143
Summary: Initial setup for a support detail form. Will only show up if meta data is present in the flipper file, so use the attached one to see it.
Reviewed By: jknoxville
Differential Revision: D18479193
fbshipit-source-id: 61da089f1e883fea20b2422a6bea99b2f8a4434b
Summary: Adds a type for the return type of runHealthchecks()
Reviewed By: passy
Differential Revision: D18474919
fbshipit-source-id: b86968088d61d9d2d31815b4c725396cc05d8ca5
Summary: So we can use null coalescing and the other goodies in the doctor.
Reviewed By: passy
Differential Revision: D18477611
fbshipit-source-id: 60108d3c7c03e3fe4a4313653d5f615d287411fd