Summary:
I'm in the progress of releasing a prefab-enabled FBJNI release. This dramatically reduces the hackery around integrating with separately released native libraries.
This will fail until the release is actually out.
Pull Request resolved: https://github.com/facebook/flipper/pull/1941
Test Plan:
`./gradlew :sample:installDebug` works as before.
Once the release is out, we need to check if this creates any problems with RN but because we advice to exclude the dependency, I expect it not to cause any trouble.
Reviewed By: mweststrate
Differential Revision: D26545104
Pulled By: passy
fbshipit-source-id: 1e21fa1816f28e2fcb52da68863fabc8bc625136
Summary:
Upgraded to the latest Android Studio and this popped up.
Pull Request resolved: https://github.com/facebook/flipper/pull/1936
Test Plan:
Built the sample app.
Repro'd the previous build failure. Weirdly enough, this only occurred on Linux, not on my Mac. Now it's passing.
Reviewed By: mweststrate
Differential Revision: D26483694
Pulled By: passy
fbshipit-source-id: 9c27eb6d28a0f390154899d67469a504d68c2ad4
Summary:
This removes Bintray/JCenter specific code and replaces it with a new plugin recommended by [Chris Banes](https://chris.banes.dev/publishing-to-maven-central/).
Pull Request resolved: https://github.com/facebook/flipper/pull/1914
Test Plan:
Manually uploaded as snapshot and full release, but with this setup still requires all sorts of manual setup, including GPG. Next PR will include automation for this.
CI here should also verify that I didn't split this diff up incorrectly.
Reviewed By: jknoxville
Differential Revision: D26367350
Pulled By: passy
fbshipit-source-id: faa6b488d6c95bc643d2f9328362e29fb4b05ded
Summary:
- Made `EnumMapping` support generic value type - `ImageView.ScaleType` is a Java enum; the scaleType api uses this instead of int types.
- Introduce descriptor for `ImageView` and allow getting/setting scaleType.
Reviewed By: mweststrate
Differential Revision: D26092725
fbshipit-source-id: ea3a4ee036b2b808f14277387d360318b7d25824
Summary: Legacy resources are deprecated, this is what we should be using
Reviewed By: jselbo
Differential Revision: D25903962
fbshipit-source-id: ffa91a3aee8956591b7daab523bda2e59fec9932
Summary:
The Network Plugin does not properly handle network requests that return an empty body (because of the body actually being empty or because the network call returns something like a 404 status).
Also, the creation of mocks using the "Copy Highlighted" command when the original response returns an empty body is not handled properly.
## Fix
The Android plugin now returns a response when the body length is 0.
The client plugin creates a body containing an empty string instead of null when the body is empty.
## Changelog
Fix problem in Network Plugin when original call or mock has an empty body in the response.
Pull Request resolved: https://github.com/facebook/flipper/pull/1776
Test Plan:
The following screen output for the Network Plugin shows that the call is now being handled correctly. The fields for "status", "size" and "duration" are now populated.
Also, the mock calls are properly defined and shown in yellow.

Reviewed By: mweststrate
Differential Revision: D25804212
Pulled By: passy
fbshipit-source-id: b31cc87619c604b4df76e05bca5c86554a1cabff
Summary: This change will allow loading flipper not only internal build but also in builds that explicitly turn on LOAD_FLIPPER_EXPLICIT in build config
Reviewed By: timur-valiev
Differential Revision: D25369245
fbshipit-source-id: 9f8e5c7033aa4ded6ce7bc8cc5b5c252ba65692b
Summary:
This diff adds the Java classes that serialize to the data expected by the new timeline widget. See D23865369 for the JS counterpart.
Currently the Flipper plugin uses `toString` to get the wire values. I'm not feeling like using a json library or dealing with JSONObject's nonsense, so these are rolled manually for now.
Reviewed By: astreet
Differential Revision: D24254377
fbshipit-source-id: b2fc00400c40b47ac29c9b83c0b66621c3677974
Summary:
The current ownership and release model prevents cleanly releasing new versions of the plugin while the code is split between two repos.
This diff moves the flipper-litho plugin to the Litho repository. You'll find new releases as `litho-editor-flipper` that'll be reexported via gradle's `api` to the old artifact.
Reviewed By: colriot
Differential Revision: D23962234
fbshipit-source-id: 7884423342904219ae9b41632c6df90cda870798
Summary: FlipperEditor has migrated to `litho-editor-flipper`, so this diff fixes the dependency tree and deletes the file.
Reviewed By: muraziz
Differential Revision: D23380023
fbshipit-source-id: 75f5f037dc392194212fc156499f090c381999bd
Summary: jknoxville helped me debug this. The underlying problem was that we didn't include a dependency which is transitive in gradle land. We swallowed the exception and just returned an empty list. I left an error log in there to make future debugging easier. For reference, this was the error:
Reviewed By: cekkaewnumchai
Differential Revision: D23759727
fbshipit-source-id: 244510d2765913bf4c89458e336889c3c6838fc4
Summary:
Adds a link to the Yoga playground atop all properties of Yoga-based views.
We could make the playground match the properties below if I figure out the hashing mechanism the website uses. This is a start.
Reviewed By: muraziz
Differential Revision: D23758538
fbshipit-source-id: 6a3f206914aa9962e55852df548f8026783506e9
Summary: This broke DB opening in FB apps. Will try to fix and reland this, but need to unblock people first.
Reviewed By: cekkaewnumchai
Differential Revision: D23705962
fbshipit-source-id: 3c9ff3a74e5a6d34e6cb2c75e7e2cec749b5a60e
Summary:
This change will allow to use various SQLiteDatabase implementations: standard Android implementation, [requery/sqlite-android](https://github.com/requery/sqlite-android) and so on. See issue https://github.com/facebook/flipper/issues/1183
## Changelog
Android Databases Plugin: `SqliteDatabaseConnectionProvider` returns `SupportSQLiteDatabase` instead of `SQLiteDatabase`.
Pull Request resolved: https://github.com/facebook/flipper/pull/1196
Test Plan: Check that Databases Plugin shows correct data on the sample Android application.
Reviewed By: mweststrate
Differential Revision: D23294272
Pulled By: passy
fbshipit-source-id: c07ebeb869ab01d41281f75541cbb3411f0ebae0
Summary:
The function `setLayoutParams` expects the values to be set to be at array position 0+, and they were on position 1+ instead.
This effectively prevented users from setting LayoutParameters.
Reviewed By: muraziz
Differential Revision: D23538531
fbshipit-source-id: cc828363ee8d7408d1df29d98c37b09893826bb1
Summary: This diff uses the new picker defined in EnumMapping for regular Android View properties.
Reviewed By: muraziz
Differential Revision: D23538532
fbshipit-source-id: be5b776453e7322fb13a5f9e6a66a1f8d1243e79
Summary: This diff makes EnumMapping compatible with the new Layout widget "picker"
Reviewed By: muraziz
Differential Revision: D23538548
fbshipit-source-id: 7bdb01648c1ad5e2d0d7594c98df5ed89d893702
Summary: Detect if resolved path is properly computed and accordingly display a success or error notification within InAppErrorReporter.
Reviewed By: arpitratan
Differential Revision: D23425001
fbshipit-source-id: 4ca903a8b9e83dc0e11bb823537f56678dd85b76
Summary: This change removes the dependency of FlipperEditor from AndroidX, which prevents it from moving to the Litho repository
Reviewed By: Andrey-Mishanin
Differential Revision: D23475867
fbshipit-source-id: a330c676859ed9ce9a0ab186dd206310d2eccca5
Summary:
The default max body size for the OkHttpInterceptor that is reported to Flipper seems unreasonably small, as most images, graphql responses etc are bigger. Increased it to 1MB
Since the network plugin doesn't do any work if it is not explicitly enabled in Flipper, this should not lead to further performance regression / starvation.
Reviewed By: jknoxville
Differential Revision: D23375720
fbshipit-source-id: e901105209aec7108d61fc20295a149c5582f22d
Summary:
Images in the network plugin are rarely displayed in the network plugin, as it tries to use the public url to preview it. However, that won't if the endpoint is behind authentication, idempotent, etc. This diff changes the behavior to instead send the network body to flipper and use that to preview.
Changelog: [Network] Fixed image preview
Reviewed By: jknoxville, passy
Differential Revision: D23370743
fbshipit-source-id: 0070e9e38c10a5761b9f7190467e26f01a7b2471
Summary:
Related diff [CK]: D23243009
This diff adds support for a protocol for layout messages where the type is recursively encoded as:
```
{
kind: "type",
data: ???
}
```
The meat of the diff is on FlipperEditor.java, SetDataOperations.java and InspectorFlipperPlugin.java. The others are there just for a change on an interface.
We check if the message adheres to the new encoding, otherwise we fall back to the old behavior. If it's the new encoding, the message is traversed recursively flattening the types to EditorValue using the type hints provided.
Reviewed By: muraziz
Differential Revision: D23243009
fbshipit-source-id: 0f313455885930f3beaaadb66f3bf394f109ea23
Summary: Adds support in Flipper for the picker widget. The way it reaches Flipper is a bit nasty, using `toString` to produce a JSON value.
Reviewed By: passy
Differential Revision: D23294091
fbshipit-source-id: e3398e6fb474e46bdaac1960aeaf57e201946413
Summary:
Just released a new version.
Pull Request resolved: https://github.com/facebook/flipper/pull/1428
Test Plan:
`./gradlew :android:installDebug`
However, I'm tethering right now and this is taking ages so I haven't
been able to complete this.
Reviewed By: mweststrate
Differential Revision: D23295098
Pulled By: passy
fbshipit-source-id: aa53fa1c47f0b02d2c8b9f12d66b1c600a37075b
Summary: See linked task, data larger than 5KB would always be reported as blob. Increased this limit to 100KB, since if the user is looking at this data, it is proactively requested so it is fine if it is larger
Reviewed By: jknoxville
Differential Revision: D23317197
fbshipit-source-id: f563a980fa9567ac7e2f950b83c1888a7b295d77
Summary: Useful for next diffs: enables to detect whether we have LithoComponent or CKComponent
Reviewed By: adityasharat
Differential Revision: D23128972
fbshipit-source-id: b9aef358c1426df4f05213c42e43402e8cae984f
Summary:
It's common for responses to be completely missing in the network inspector. This is because they are larger than can be serialized in one go on some devices, so we drop all messages larger than 1MB.
This changes the android client to send large responses in individually serialized batches. This way we avoid running out of memory and can still send arbitrarily large payloads.
Changelog: Android network inspector can now handle responses large than 1MB.
Reviewed By: passy
Differential Revision: D22999905
fbshipit-source-id: ff4eb8fa72a7e42ea90d12ffe0f20c6d1e58b7e5
Summary:
Populate class name for Litho Sections.
See D22922106 (86cafb9e80) for reference
Reviewed By: adityasharat
Differential Revision: D22949896
fbshipit-source-id: d804971708cf8c8466dd74eda3e750957dc95fc9
Summary: Populate class name for Litho Components.
Reviewed By: adityasharat
Differential Revision: D22922106
fbshipit-source-id: e18b748e0e0bd6f511558124a28b4b58d217ded7
Summary:
Added IDE menu functionalities.
Changed minor UX detail - for classes that cannot be opened user will always see 'Can't open' prompt.
Design: https://www.figma.com/file/M0l6qhQqzllIcefVE4tQvG/Error-Reporter-IDE-Selector?node-id=82%3A0
Reviewed By: arpitratan, adityasharat
Differential Revision: D22790328
fbshipit-source-id: 8dfbcf7408c53947909bcf3fa700dee7ae47e14a
Summary: Adds a toggle switch to show/hide disk cache images defaulting to inactive. The image data is only sent on the adb connection when the toggle is activated.
Reviewed By: defHLT
Differential Revision: D20002059
fbshipit-source-id: 05c9e515ffe09441e5cfb6f66eb14559ac4a322c
Summary:
This diff implements the integration between a Litho Editor and Flipper. It does so by converting the Editor format to FlipperObject, and then converting it back from FlipperDynamic.
This conversion works for both `State` and `Prop`. We already provide default implementations for primitive + wrapped types and String, so the functionality should match the existing one.
Reviewed By: passy, Katalune
Differential Revision: D22455220
fbshipit-source-id: f7f633765f3d997ce6de09d2c1277019e72c0802
Summary: Created buttons which enable opening in IDE for classes which are valid.
Reviewed By: adityasharat
Differential Revision: D22724496
fbshipit-source-id: 3532213ab7730aae5e61877ccfecd0558b329d57
Summary:
Created functionality which allows user to open clicked file from inAppErrorReporter.
Created "iface" interface for openInIDE API and created default implementation which indicates that openInIDE is not supported.
Created "impl" implementation specifically for fb4a.
Reviewed By: arpitratan
Differential Revision: D22642497
fbshipit-source-id: 7b3011c128a479e556b869fcc8c4147e153caf71
Summary: Created a communication between Layout Plugin and Flipper Desktop. The API allows users to open given file in a selected IDE. The openInIDE function returns true if the connection with Flipper is established, otherwise returns false.
Reviewed By: adityasharat
Differential Revision: D22625829
fbshipit-source-id: feaf186c107d62b1a75dfc6bbe2c1d66ffd7fd78
Summary:
I think it's somewhat common to have large containers that can hold future views, especially fragments. The problem is the presence of these containers can block the layout inspector's "target" mode.
I found out from cekkaewnumchai that Flipper does in fact return multiple results from the pick, but I think it could still be helpful to have this new tag since it is more convenient than having to do the secondary drill down each time.
Reviewed By: jknoxville
Differential Revision: D22284972
fbshipit-source-id: 1a2826ec746e4f31690db33ed72815ae168bffab
Summary:
Before this diff, `TouchOverlayView` would be an inner non-static class,so it'd be difficult to track memory ownership for it.
It also made `InspectorFlipperPlugin` longer and harder to read.
Reviewed By: cekkaewnumchai
Differential Revision: D22285744
fbshipit-source-id: 6fdd8c33a07be6ab900ebb28a8c3ebf3761fb598
Summary:
Fix for https://github.com/facebook/flipper/issues/1300
The weak refs were not being cleared in two cases:
- On config changes, isFinishing() would be false in onPause()
- When calling finish() from Activity.onCreate(), onPause() isn't guaranteed to be called.
## Changelog
Pull Request resolved: https://github.com/facebook/flipper/pull/1301
Reviewed By: mweststrate
Differential Revision: D22286182
Pulled By: passy
fbshipit-source-id: 948d1d9b2145b6526c0030cf537330409ff7f8c4