Summary: Logview reported "Error: Maximum call stack size exceeded" for "getElementLeaves". Apparently, there was a cycle in the graph that caused it. The new implementation should ignore cycles.
Reviewed By: lblasa
Differential Revision: D43976359
fbshipit-source-id: bb5218a3b29706146501241492ee079773d5abc3
Summary: We can't do much if a phone is not setup properly
Reviewed By: lblasa
Differential Revision: D43980508
fbshipit-source-id: 5baf82ae36030b81c7cc90bcf6a5de2af9304fb3
Summary:
I've just packaged Flipper for Gentoo Linux and I wanted to use the system electron instead of bundling its own copy into the flipper executable. To do so I use my custom `electron-builder` and `app-builder` versions, which also allows me to support otherwise unsupported architectures like ppc64. That means skipping the downloading/unzipping/bundling steps for electron, which greatly shortens the overall build process.
Being that fast resulted in countless hours of debugging, because the resulting `app.asar` wouldn't work. At some point I noticed that electron-builder cli was working flawlessly while processing the same exact config through the Javascript API resulted in failure, so I started digging into your scripts and I've noticed that you didn't await `stripSourceMapComment` into `desktop/scripts/build-utils.ts`.
In particular the `compile` function was returning before `stripSourceMapComment` had finished doing its stuff, which ended up messing with electron-builder later.
You didn't notice because you download electron, unzip it, etc which takes enough time to let `stripSourceMapComment` finish its stuff before the actual build starts, but since I skip these steps in order to use system electron I've been able to notice it.
## Changelog
I simply await `stripSourceMapComment` promises in `build-utils`.
Pull Request resolved: https://github.com/facebook/flipper/pull/4586
Test Plan:
`cd desktop && yarn && yarn build` is enough to test this.
## Additional Suggestions
I also suggest to enable the [no-floating-promises](https://typescript-eslint.io/rules/no-floating-promises/) eslint rule in order to ensure similar mistakes won't happen in the future.
Reviewed By: ivanmisuno, mweststrate
Differential Revision: D43974442
Pulled By: passy
fbshipit-source-id: 5acfa3d1479828e9373070c40fe3dd865a862561
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/4528
Reviewed By: ivanmisuno
Differential Revision: D43974467
Pulled By: passy
fbshipit-source-id: b2a0b3539add658f59221acadc6701bdcae3238c
Summary:
Add a frameworks events tab. This is currently using the `TimelineDataDescription` component which may ultimately be replaced by something more sophisticated.
In the meanwhile, this does the job of chronologically displaying events with a label.
Reviewed By: mweststrate
Differential Revision: D43948891
fbshipit-source-id: 31ebf8a1d0e126856c3aa5291a1a06d7f2547233
Summary: Make properties optional. Additionally, only show them if found.
Reviewed By: mweststrate
Differential Revision: D43948493
fbshipit-source-id: 0aa77a725663b456f069c717b4ea051008516c9e
Summary: Make this property optional as is not always required to implement it, if not needed.
Reviewed By: mweststrate
Differential Revision: D43948425
fbshipit-source-id: 43ed761c70c4779134f277a4cda53c1e3d326cb8
Summary:
Instead of showing events as inline attributes, just show a badge with the number of it. Event details will be displayed with other means:
- Hover
- Dedicated tab
- Other
Reviewed By: mweststrate
Differential Revision: D43946575
fbshipit-source-id: 762a241040d7fc6afb2c86d129a620ff2bb15feb
Summary:
Bumps [rayon](https://github.com/rayon-rs/rayon) from 1.6.1 to 1.7.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/rayon-rs/rayon/blob/master/RELEASES.md">rayon's changelog</a>.</em></p>
<blockquote>
<h1>Release rayon 1.7.0 / rayon-core 1.11.0 (2023-03-03)</h1>
<ul>
<li>The minimum supported <code>rustc</code> is now 1.59.</li>
<li>Added a fallback when threading is unsupported.</li>
<li>The new <code>ParallelIterator::take_any</code> and <code>skip_any</code> methods work like
unordered <code>IndexedParallelIterator::take</code> and <code>skip</code>, counting items in
whatever order they are visited in parallel.</li>
<li>The new <code>ParallelIterator::take_any_while</code> and <code>skip_any_while</code> methods work
like unordered <code>Iterator::take_while</code> and <code>skip_while</code>, which previously had
no parallel equivalent. The "while" condition may be satisfied from anywhere
in the parallel iterator, affecting all future items regardless of position.</li>
<li>The new <code>yield_now</code> and <code>yield_local</code> functions will cooperatively yield
execution to Rayon, either trying to execute pending work from the entire
pool or from just the local deques of the current thread, respectively.</li>
</ul>
<h1>Release rayon-core 1.10.2 (2023-01-22)</h1>
<ul>
<li>Fixed miri-reported UB for SharedReadOnly tags protected by a call.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="7ffaf3463b"><code>7ffaf34</code></a> Merge <a href="https://github-redirect.dependabot.com/rayon-rs/rayon/issues/716">https://github.com/facebook/flipper/issues/716</a></li>
<li><a href="163003e0e3"><code>163003e</code></a> bump the release date</li>
<li><a href="f7d75532fc"><code>f7d7553</code></a> Release rayon 1.3.0 / rayon-core 1.7.0</li>
<li><a href="b98bb23f05"><code>b98bb23</code></a> Remove unneeded extern crate statements</li>
<li><a href="9b92c7deb9"><code>9b92c7d</code></a> cargo fmt</li>
<li><a href="e02f439bbf"><code>e02f439</code></a> Remove useless 'use crate;' in favor of the crate prelude</li>
<li><a href="a1db0fe390"><code>a1db0fe</code></a> Fix clippy::flat_map_identity</li>
<li><a href="4e4025693f"><code>4e40256</code></a> Update ci/compat-Cargo.lock</li>
<li><a href="1f9d117d51"><code>1f9d117</code></a> Remove cfg(rayon_unstable)</li>
<li><a href="198ca7f6aa"><code>198ca7f</code></a> Remove rayon-futures</li>
<li>Additional commits viewable in <a href="https://github.com/rayon-rs/rayon/compare/rayon-core-v1.6.1...rayon-core-v1.7.0">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/4571
Reviewed By: lblasa
Differential Revision: D43904929
Pulled By: passy
fbshipit-source-id: 7e8fdb590b30c89a6f144a936a28b118633fb688
Summary:
Bumps com.github.ben-manes.versions from 0.44.0 to 0.46.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/4551
Reviewed By: lblasa
Differential Revision: D43904939
Pulled By: passy
fbshipit-source-id: 1208535e181822dd954959304b497a021d2f9b9b
Summary:
^
With these changes, we can build the project by overriding these version from a gradle build.
./gradlew :assembleDebug -DNDK_VERSION=21.4.7075529 -DFBJNI_VERSION=0.2.2
Reviewed By: passy
Differential Revision: D43879098
fbshipit-source-id: 8790aa12a086373194d45687d70ceb73b07713b9
Summary: Currently, Flipper server cannot be used with Flipper Launcher on Linux because there is no `flipper` binary in the root of the directory. Adding a quick shell script bridges the call from the checked-in node binary and the server JS file.
Reviewed By: ardavank
Differential Revision: D43837781
fbshipit-source-id: d954ae21d5330aa549d4bc76aefb1d76af8e2c84
Summary: It wasn't exported, instead it was consumed by the 'flipper' deprecated module.
Reviewed By: fabiomassimo
Differential Revision: D43872434
fbshipit-source-id: 70a4a525c660f0779f942739311205417cef3834
Summary: Without the margin, the point is displayed at the top-left which is not centrally aligned with both time and label.
Reviewed By: antonk52
Differential Revision: D43872394
fbshipit-source-id: 087c09e44c65ddaef79cfb25a860d7b4893ba072
Summary: The margin was miss-aligning with the label.
Reviewed By: antonk52
Differential Revision: D43872373
fbshipit-source-id: 8a6ff8104c6e532d8139053aad221244c2cd5feb
Summary:
Set a fixed number of decimals for the 'ms'.
More doesn't give more insights and it messes with the overall layout.
Reviewed By: antonk52
Differential Revision: D43872203
fbshipit-source-id: 343278923ee27dbf884af41c997457bfba337ba8
Summary: Remove the bottom padding as this was not really making it any better.
Reviewed By: antonk52
Differential Revision: D43872178
fbshipit-source-id: 8302385d190c65000afda02b5c8aa9d272ccc271
Summary:
The hover background colour had complete disregard on the selected theme, both light and dark.
This change removes the gradient and instead sets a right hover background.
Reviewed By: antonk52
Differential Revision: D43872161
fbshipit-source-id: 4f0bfd97a2cb6bb9ceb7869dd38b37dc68ad6bb7
Summary: Same as the previous diff but for js-flipper.
Reviewed By: lblasa
Differential Revision: D43739851
fbshipit-source-id: ea85b132980241381efa4887fb02045ec921159c
Summary: This is firing regularly when people have a broken local setup.
Reviewed By: lawrencelomax
Differential Revision: D43834469
fbshipit-source-id: 1fbc2cf52f93046984e9846f8aed931106542b03
Summary:
Hoping that this will fix our docs build.
Note that I also had to fix a syntax error in `extending/loading-custom-plugins.mdx` that
broke the build with:
```
SyntaxError: /Users/realpassy/fbsource/xplat/sonar/docs/extending/loading-custom-plugins.mdx: Expected corresponding JSX closing tag for <admonition>. (10:10)
8 | <FbInternalOnly>
9 | <admonition {...{"type":"caution"}}><p parentName="admonition">{`Within Meta, plugins sources are stored and loaded from `}<inlineCode parentName="p">{`~/fbsource/xplat/sonar/desktop/plugins`}</inlineCode>{`, in which case no further configuration is needed.`}</p><p parentName="admonition">{`If your team uses Flipper plugins that are stored outside `}<inlineCode parentName="p">{`fbsource`}</inlineCode>{`, please follow your team specific instructions.
> 10 | ::::`}</p></FbInternalOnly><p parentName="admonition">{`Flipper loads and runs plugins it finds in a configurable location. The paths searched are specified in `}<inlineCode parentName="p">{`~/.flipper/config.json`}</inlineCode>{`. These `}<inlineCode parentName="p">{`pluginPaths`}</inlineCode>{` should contain one folder for each of the plugins it stores.`}</p><p parentName="admonition">{`An example config setting and plugin file structure is shown below:`}</p><p parentName="admonition"><inlineCode parentName="p">{`~/.flipper/config.json`}</inlineCode>{`:`}</p><pre parentName="admonition"><code parentName="pre" {...{"className":"language-bash"}}>{`{
| ^
11 | ...,
12 | "pluginPaths": ["~/flipper-plugins"]
13 | }
client (webpack 5.74.0) compiled with 1 error
```
Reviewed By: ivanmisuno
Differential Revision: D43767006
fbshipit-source-id: 64288d63c305bc9a9c9b797110889a703c7dcfee
Summary:
The website generation fails on newer versions of `flipper-plugin` as it contains an import-time side effect. This leads to this error during build time:
```
[ERROR] Docusaurus server-side rendering could not render static page with path /docs/extending/style-guide/.
[INFO] It looks like you are using code that should run on the client-side only.
To get around it, try using `<BrowserOnly>` (https://docusaurus.io/docs/docusaurus-core/#browseronly) or `ExecutionEnvironment` (https://docusaurus.io/doc
s/docusaurus-core/#executionenvironment).
It might also require to wrap your client code in `useEffect` hook and/or import a third-party library dynamically (if any).
```
This ain't pretty but by wrapping the entire file in a single function that conditionally imports the `flipper-plugin` if we are indeed in a browser environment fixes the problem.
Reviewed By: antonk52
Differential Revision: D43773298
fbshipit-source-id: 8e1099249626ca9fe745ce51014491fe9674a5a4
Summary: It has served its purpose, remove.
Reviewed By: LukeDefeo
Differential Revision: D43769239
fbshipit-source-id: 36fb575b15fe9d092c7728a56b735ff98ff78608
Summary:
In newer builds of react-native if you passed parameters PRODUCTION=1, flipper pods won't get installed
you can see that in their codebase here [react_native_pods.rb](6a43fafd78/scripts/react_native_pods.rb (L140))
so when building ios `react-native-flipper` set `compiler_flags = '-DFB_SONARKIT_ENABLED=1'` in the podspec file
which initializeFlipper and lead to the following error:
`node_modules/react-native-flipper/ios/FlipperReactNativeJavaScriptPluginManager.h:12:9: 'FlipperKit/FlipperClient.h' file not found`
## Changelog
use same condition as react-native to wrap `s.compiler_flags = compiler_flags`
and conditionally pass `compiler_flags = '-DFB_SONARKIT_ENABLED=1'` to compiler_flags to avoid build problems
Pull Request resolved: https://github.com/facebook/flipper/pull/4275
Test Plan:
To reproduce
- create new react-native app
- install react-native-flipper `yarn add react-native-flipper`
- run `env PRODUCTION=1 npx pod-install `
- run `yarn ios`
Before patch:
```sh
node_modules/react-native-flipper/ios/FlipperReactNativeJavaScriptPluginManager.h:12:9: 'FlipperKit/FlipperClient.h' file not found
```
After patch:
```sh
▸ Build Succeeded
success Successfully built the app
```
Reviewed By: jknoxville
Differential Revision: D41298345
Pulled By: mweststrate
fbshipit-source-id: fb46772d46b8105fccb1abb673502bca428eea1d
Summary:
Added infra for collecting events from UI frameworks.
1. Framework event metadata captures all the static metadata around the event. This allows to us to not send the same metadata in every event as well as populate the monitoring drop down immediately. This is sent in init since this information is static
2. Framework event itself is quite bare at the moment. It will have thread and more attributes in the future
The UIdebugger litho support ulitity has been simplified now there are 3 extension points.
Context renamed to UIDContext since it is referenced in app initialisers where the android context is also imported and it create a naming collision
Reviewed By: lblasa
Differential Revision: D42606933
fbshipit-source-id: a419f3fd424c533d586813004c40b68feafd9a2e
Summary:
The goal is to restore the *TimeMachine* functionality in Flipper while the new UI Debugger is working in a revamped version. This version was previously removed in D42573698 (b31f8c8755).
This time machine functionality will only be available for *LithoView* that are backed by a *ComponentTree*.
Below you can find a high-level overview of the current schema:
{F884011465}
Reviewed By: LukeDefeo, adityasharat
Differential Revision: D43574130
fbshipit-source-id: fe9d661e5fcce9655e70be4785652e7048dade54
Summary: Use system linker by default on Android N and above devices.
Reviewed By: lblasa
Differential Revision: D43575139
fbshipit-source-id: 98ff074967ce431cdda46d02cbfaa2b6130efc39
Summary: Having a timeout of 10 seconds can create a connection loop if Desktop is slow and doesn't provide a client certificate within the timeframe.
Reviewed By: antonk52
Differential Revision: D43405793
fbshipit-source-id: b1eebb4d2d66f02000f15a9889992ed0cc79bde2
Summary:
https://pxl.cl/2tKXq
It was reported the feedback prompt title was unreadable.
Reviewed By: mweststrate
Differential Revision: D43533800
fbshipit-source-id: f756a9822c479105dae890159518c05c99405fb7
Summary:
The plugin is inteded to record intents being dispatched and handled
Current version is pretty simple and just records the intents correctly handled by IG app only (for now, integration is simple enough to add to FB, too)
Plugin prints the data associated with the target
Differential Revision: D43494264
fbshipit-source-id: 3e3cd41ade1d083990d15b3c2eb815db157c7163
Summary: This appears to be unreferenced and it constantly confuses our header autocomplete. Remove.
Reviewed By: d16r
Differential Revision: D43408140
fbshipit-source-id: ff6db8e5e4bbda394197168680cf8d15b07666c3