Commit Graph

82 Commits

Author SHA1 Message Date
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
Lorenzo Blasa
a935ab8a6c Android Web Socket (#2978)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/2978

Flipper Android WebSocket provider and socket implementation

Reviewed By: ldelgadoj

Differential Revision: D31683510

fbshipit-source-id: d553a7fdee9451da742e9ea3e6e5b6a2c9417579
2021-11-08 09:22:48 -08:00
Pascal Hartig
6279cc68b1 Upgrade to Gradle 7 (#2279)
Summary:
Depends on https://github.com/facebook/flipper/issues/2277. Fixes https://github.com/facebook/flipper/issues/2221.

The maven plugin is no longer exposed and implied by https://developer.android.com/studio/build/maven-publish-plugin.

Pull Request resolved: https://github.com/facebook/flipper/pull/2279

Test Plan: ./gradlew uploadArchives -PdryRun=true

Reviewed By: priteshrnandgaonkar

Differential Revision: D28473692

Pulled By: passy

fbshipit-source-id: 3d95122fecebfeac8bfa5173c5c633eee3f13311
2021-05-17 07:29:49 -07:00
Pascal Hartig
6af041454a Upgrade to FBJNI 0.2 (#1999)
Summary:
This should fix https://github.com/facebook/flipper/issues/1968

Pull Request resolved: https://github.com/facebook/flipper/pull/1999

Test Plan:
Built our sample app; built the sample app provided in the repo as part
of the issue; locally released the Flipper artifacts and built the RN
app against it.

Reviewed By: fabiomassimo

Differential Revision: D26817589

Pulled By: passy

fbshipit-source-id: c6db5f947c08e4236442b08306791e45b4d15ec3
2021-03-04 08:45:09 -08:00
Pascal Hartig
847f4d0151 Delete redundant gradle code (once more)
Reviewed By: fabiomassimo

Differential Revision: D26751726

fbshipit-source-id: 03b8601cdb0910f2ec7508d9bb1c09bcd6bcd301
2021-03-02 08:46:13 -08:00
Pascal Hartig
3d2a0e3eb2 Enable prefab for fbjni integration (#1941)
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
2021-02-24 06:20:12 -08:00
Pascal Hartig
3f16da4db0 Upgrade gradle plugin (#1936)
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
2021-02-19 03:29:50 -08:00
Pascal Hartig
b25de27b8a Move bolts dependencies to Fresco plugin (#1937)
Summary:
Fixes https://github.com/facebook/flipper/issues/1919

Somehow the diff author put the dependencies in the root `build.gradle`, which is unnecessary as this is only used by Fresco.

Pull Request resolved: https://github.com/facebook/flipper/pull/1937

Test Plan:
Built the sample app, checked that the Fresco stuff continues to work.
![Screenshot_1613565381](https://user-images.githubusercontent.com/9906/108205459-0366ef80-711d-11eb-8b3b-f804f02622af.png)

Reviewed By: mweststrate

Differential Revision: D26483701

Pulled By: passy

fbshipit-source-id: 88f056ed0897f2c00844e02721eb45d5b85c6908
2021-02-18 09:31:04 -08:00
Pascal Hartig
87d7bcf274 Remove JCenter specifics (#1914)
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
2021-02-10 07:16:32 -08:00
Amir Katz
eb475e7550 creating a flag to explicitly load flipper
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
2020-12-15 03:21:08 -08:00
Pascal Hartig
ddc9c3e243 Back out "Back out "[flipper][PR] Use interface SupportSQLiteDatabase in Android Databases Plugin""
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
2020-09-17 10:30:16 -07:00
Pascal Hartig
bb176577e9 Back out "Use interface SupportSQLiteDatabase in Android Databases Plugin"
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
2020-09-15 17:05:24 -07:00
Pascal Hartig
bb807243ae Revert "fbjni 0.0.4 (#1428)" (#1524)
Summary:
This reverts commit 97adea5423.

This is to address https://github.com/facebook/flipper/issues/1514.

Waiting for RN to upgrade fbjni on their end before un-reverting.

Pull Request resolved: https://github.com/facebook/flipper/pull/1524

Reviewed By: mweststrate

Differential Revision: D23678287

Pulled By: passy

fbshipit-source-id: a89f3f625690fc8f97d7e05f5cfdea729d1fe03d
2020-09-14 08:03:12 -07:00
a.artikov
7a7a88bfde Use interface SupportSQLiteDatabase in Android Databases Plugin (#1196)
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
2020-09-09 04:26:07 -07:00
Pascal Hartig
97adea5423 fbjni 0.0.4 (#1428)
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
2020-08-27 03:45:40 -07:00
Pascal Hartig
99a4884fad Bump Gradle plugin to 3.6.1 (#958)
Summary:
This is in line with the most recent stable Android Studio Release.
Pull Request resolved: https://github.com/facebook/flipper/pull/958

Test Plan:
Used it myself.

Open Source CI required a higher NDK, so let's first check what CI says to that internally now.

Reviewed By: jknoxville

Differential Revision: D20794634

Pulled By: passy

fbshipit-source-id: c32f934634b036ad3c1cad9fc49541e585d64329
2020-04-06 06:43:43 -07:00
Mathias Fleig Mortensen
57c573d973 Add disk cache support for Images plugin
Summary:
Tracks images in disk cache. It seems performant even with 500+ images in disk cache. Sidebar displays the local path for an image when that image is selected. Shows total size of images in disk cache. 'Clear Cache' clears the disk cache.

For now we unpack the async cache request in the plugin, should implement a `getSync()` method on `bufferedDiskCache` in the future. For some reason Flipper doesn't work with a blocking call (https://fburl.com/smj0s4li).

Reviewed By: defHLT

Differential Revision: D20001062

fbshipit-source-id: 1e7a7900e9f42d05e3bf30472e57cd643caa5aca
2020-03-27 06:32:46 -07:00
Sim Sun
4a2349c42d refactor(asan): remove asan checker
Summary: Remove asan checker, we can use `BuildConfig.IS_ASAN_BUILD` to check whether it's a asan build to instead of invoking a JNI api.

Differential Revision: D20088093

fbshipit-source-id: f26d367430a983fbe7b630919a4131fdf2e2d510
2020-02-25 21:48:28 -08:00
Zac Sweers
48d6ea4c30 Remove stetho (#762)
Summary:
## Summary

Resolves https://github.com/facebook/flipper/issues/607

This removes stetho dependencies directly in favor of just copying in the used classes. This removes the last non-androidx dependency from the project, and is useful as stetho appears to be unmaintained. The fresco stetho dependency appeared to be completely unused.

## Changelog

Remove stetho dependencies. It was unused other than a few utility methods, but came at the cost of preventing Flipper consumers from completely removing dependencies that hadn't updated to Androidx yet.
Pull Request resolved: https://github.com/facebook/flipper/pull/762

Test Plan: Existing tests still pass with no regressions. Functionally this should be no difference.

Reviewed By: jknoxville

Differential Revision: D19577969

Pulled By: passy

fbshipit-source-id: b277ddf97a9d2c846dd0b9227c02bb46c1ecd930
2020-01-28 05:24:30 -08:00
Andres Suarez
0675dd924d Tidy up Flipper license headers [1/2]
Reviewed By: passy

Differential Revision: D17863711

fbshipit-source-id: 259dc77826fb803ff1b88c88529d7f679d3b74d8
2019-10-11 13:46:45 -07:00
Pascal Hartig
975b52d26b Build with static libc++
Summary:
This avoids having to perform gymnastics like in
https://github.com/facebook/react-native/pull/26697

Reviewed By: jknoxville

Differential Revision: D17735954

fbshipit-source-id: 507548aab89309beeb228b104a24af8acd10ce9a
2019-10-03 04:39:20 -07:00
Chaiwat Ekkaewnumchai
053cfc09f3 Make LeakCanary a Separate Plugin
Summary: Pull Request resolved: https://github.com/facebook/flipper/pull/559

Reviewed By: passy

Differential Revision: D17546936

fbshipit-source-id: dce128a771b73e8b18dfc2b78ee99502c3f1ce86
2019-09-25 03:05:56 -07:00
Pascal Hartig
8c519abc7e Upgrade to fbjni 0.2.0 (#557)
Summary:
This is now published to Maven Central and doesn't require a
separate repository.
Pull Request resolved: https://github.com/facebook/flipper/pull/557

Test Plan: CI

Reviewed By: danielbuechele

Differential Revision: D17526448

Pulled By: passy

fbshipit-source-id: 169b5bc5f6568d40697e5e48a9873f8a64bd5e00
2019-09-23 08:14:08 -07:00
Pascal Hartig
2baadf9867 Make litho/sections a separate plugin
Summary:
Breaking Litho/Sections off. Doesn't really make sense to have
two deps for this especially since they're pretty tightly coupled.

This makes our core already quite slim.

Reviewed By: jknoxville

Differential Revision: D17420118

fbshipit-source-id: 9a03911f4af6410745b9aefd0e6a75bdf106660f
2019-09-19 03:02:51 -07:00
Pascal Hartig
c4a9b603e2 Make network a separate plugin
Summary: Per title.

Reviewed By: jknoxville

Differential Revision: D17419678

fbshipit-source-id: aee00f077b7ed955c60884853dc1128d27366ee8
2019-09-19 03:02:51 -07:00
Pascal Hartig
7ac82bec4e Make fresco a stand-alone gradle project (#548)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/548

First project to pull out of the "fat distribution" we currently have.
Still needs setup for Maven and registration in Bintray.

Reviewed By: jknoxville

Differential Revision: D17395660

fbshipit-source-id: 6244495a2e25d705dd930ef87c7e5e1f038eb921
2019-09-19 03:02:51 -07:00
Pascal Hartig
0298ae74d0 Disable openssl in libevent by default
Summary: It's getting really tedious to turn these off one by one.

Reviewed By: jknoxville

Differential Revision: D17366198

fbshipit-source-id: 25443d7a18c81cd18edea21d75cfa70e4fbf4171
2019-09-13 08:56:41 -07:00
Pascal Hartig
e6e070684c Fix x86_64 / upgrade libevent (#538)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/538

Upgrades libevent to the August release 2.1.11.

Some notable things:

- The CMake file they ship with is actually broken. It contains a reference to an "uninstall.cmake" script that they don't include in the archive.
- There is some git magic in the CMake script which throws very annoying warnings if you're not in a git repository and if you are, it's still super useless because it assumes it's the libevent repo.
- I've removed the uninstall reference and replaced version detection magic with hardcoded values. The result is the "CMakeLists.txt" in the overrides folder. For future upgraders: You'll have to either remove the override or apply similar steps to the next release.
- The `event-config.h` is simply one of the outputs I found under `android/build/libevent/x86/include/event2/event-config.h`. They seem to be stable across architectures so it's easier to just copy it over than to fix the CMake logic that should actually pick it up from the Android build path.
- The cmake target names have changed and have an underscore in them, now.
- Verified with an SDK 28 x86_64 that this does fix https://github.com/facebook/flipper/issues/482.

Fixes GH482.

Reviewed By: jknoxville

Differential Revision: D17164731

fbshipit-source-id: 642744118065bea2674dbb0e1af91a11598066cc
2019-09-04 04:44:50 -07:00
Pascal Hartig
4544c4fff1 Remove vendored copy of fbjni (#530)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/530

Use the pre-release of fbjni instead of our bundled copy. I hope this can be made a little less awkward, but it works for now.

Reviewed By: jknoxville

Differential Revision: D16988077

fbshipit-source-id: 936e414f9b2bf82ccb54b107228d79d01acdbf14
2019-09-03 06:06:15 -07:00
Pascal Hartig
2fac83420b Prepare for Litho annotation removal
Summary:
Without this, our build will break with the next Litho release
because the `DoNotStrip` annotation will no longer be exported
as part of `litho-annotations`.

Reviewed By: jknoxville

Differential Revision: D16828144

fbshipit-source-id: f9a78b331678882025732498f18a3443d148ef4d
2019-08-15 08:50:13 -07:00
Pascal Hartig
660fa71505 Reenable x86 builds (#476)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/476

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

Disabling the x86 builds altogether does more harm than good.

Reviewed By: jknoxville

Differential Revision: D16119936

fbshipit-source-id: cc276dcbd1d55585d8c108b76703aa260c9c9a09
2019-07-04 06:29:50 -07:00
Pritesh Nandgaonkar
7d8db465e1 Bump Folly dependency for Android (#463)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/463

Was made aware [here](https://github.com/facebook/flipper/issues/461) that
we currently don't build with NDK 20 because of Folly. The above issue exists only for x86 platform and not for other platform. I have updated the folly and RSocket. Although this diff doesn't solve the issue mentioned above for x86, but it updates the dependencies to the latest version. To mitigate temporarily, I have updated the gradle to not build for x86.

Reviewed By: passy

Differential Revision: D15713205

fbshipit-source-id: 79dd5825b0b876c87a1868fde8f3353a76012267
2019-06-12 03:40:19 -07:00
John Knox
f71d33586f Disable Databases plugin test until roboelectric is upgraded
Summary: This gradle flag is stopping the other tests from passing.

Reviewed By: quanturium

Differential Revision: D15558776

fbshipit-source-id: 54934c73271e1cbb041877fef0dfb2de21733424
2019-05-30 14:29:12 -07:00
John Knox
a630b50a8f Add databases plugin v0 (android) (#441)
Summary:
Adds a plugin for listing the databases, tables and contents of those tables in an android app.
Right now, works with sqlite, but it should be generic enough to work with other db types.

## Changelog

Add initial version of android databases plugin

Creating a PR, I may need to do some cleaning up, but this is to kick off that process.
Pull Request resolved: https://github.com/facebook/flipper/pull/441

Reviewed By: danielbuechele

Differential Revision: D15288831

Pulled By: jknoxville

fbshipit-source-id: 6379ad60d640ea6b0a9473acc03dd6ea81a3a8d4
2019-05-28 10:17:56 -07:00
Pascal Hartig
b41b64e507 Remove gradle rhino dep
Summary: Noticed that this is still spamming the warning logs during build.

Reviewed By: danielbuechele

Differential Revision: D15354006

fbshipit-source-id: f34b99267d946ccb9ae0704beebbd48d39e9723a
2019-05-15 11:05:18 -07:00
Pascal Hartig
f584eb05dd Another round of header updates
Summary: I hope that this takes care of all the android violations.

Reviewed By: danielbuechele

Differential Revision: D15199150

fbshipit-source-id: 0f5b4edc1bc9d38de0885f88bb2c3e43acfa09cd
2019-05-03 09:59:33 -07:00
Pascal Hartig
8ba4feba66 Add gradle license headers
Summary: Some more will follow.

Reviewed By: jknoxville

Differential Revision: D15146750

fbshipit-source-id: b78331b1fb00f357812e598165d6def62e2a89c8
2019-04-30 05:34:59 -07:00
Mihaela Ogrezeanu
5195bfc0e4 Show Section props in flipper
Summary:
as title.
Refactored the getPropsData from DebugComponentDescriptor and extracted it to separate class so we can use it for SectionComponentDescriptor as well.
Will follow up with adding state info

Reviewed By: passy

Differential Revision: D14386744

fbshipit-source-id: c6b9887aa9d0c8d2333e7e64fa0954e56b505e51
2019-03-20 09:13:21 -07:00
Pascal Hartig
fbe9e3a086 Prepare for Fresco stable release (#385)
Summary:
This unblocks our open source releases.

Pull Request resolved: https://github.com/facebook/flipper/pull/385

Reviewed By: danielbuechele

Differential Revision: D14299867

Pulled By: passy

fbshipit-source-id: d9ce29d0d0713cd54f6d8bed03e7a919f443f44b
2019-03-04 09:03:10 -08:00
Pascal Hartig
e69306b34d Objecthelper
Summary:
Split off objecthelper into a (future) public and an fb-only version. This also open-sources the very first bit which is pretty useless on its own, but will already compile as its neatly stand-alone.

Note that this blocks releases until we have a stable version of Fresco to depend on.

Reviewed By: oprisnik

Differential Revision: D14149645

fbshipit-source-id: 0020d7ceccf89999695414ce389106ca6325ab7e
2019-02-21 03:30:02 -08:00
Pascal Hartig
3478968d3f Add sectionsDebug dependency
Summary: Required to build new Sections plugin.

Reviewed By: mihaelao

Differential Revision: D13986716

fbshipit-source-id: 7ce07192c3e5258eb1eff9528d95ce40145e9b5c
2019-02-07 09:39:20 -08:00
Pascal Hartig
3b18303560 Revert D13302768: [flipper] Upgrade to cmake 3.10.2
Differential Revision:
D13302768

Original commit changeset: c38601659bde

fbshipit-source-id: d624e51a489cd2d85288f85e13e09638e2ebb4be
2018-12-06 04:45:54 -08:00
Pascal Hartig
03b5306459 Upgrade to cmake 3.10.2
Summary: This was recommended by my Android Studio 3.3 when starting up, so let's do this.

Reviewed By: jknoxville

Differential Revision: D13302768

fbshipit-source-id: c38601659bde4515d62b31efbd907b44304aafba
2018-12-05 15:47:22 -08:00
Zac Sweers
62b913d844 Remove guava dependency (#309)
Summary:
It's only used in `JavascriptSessionTest`, and seems fine to keep it in tests

Resolves #172
Pull Request resolved: https://github.com/facebook/flipper/pull/309

Reviewed By: passy

Differential Revision: D12840362

Pulled By: jknoxville

fbshipit-source-id: 4ead5a4bf0c08d792abcadef713f907930a3e4e7
2018-10-31 07:50:45 -07:00
Pascal Hartig
e58961e184 Use compileOnly dependency (#294)
Summary:
Fixes #293.
Pull Request resolved: https://github.com/facebook/flipper/pull/294

Reviewed By: danielbuechele

Differential Revision: D10367678

Pulled By: passy

fbshipit-source-id: 69ccdc470b20d5d43e1bb3c1eb4e52c2e01debb5
2018-10-15 03:11:37 -07:00
Pascal Hartig
84384e523f Rename remaining tests
Summary: Something here must have conflicted upon landing. Redoing this again.

Reviewed By: danielbuechele

Differential Revision: D10145804

fbshipit-source-id: 1176167c7e3880055ff5e7b3d7f5723416f6131f
2018-10-03 03:44:20 -07:00
Pascal Hartig
8456a13ee6 Fix unit test setup
Summary:
There were still some tests with the internal test runner which
would fail in open source and with Gradle.

Reviewed By: priteshrnandgaonkar

Differential Revision: D10145759

fbshipit-source-id: 99915548441e426b88b1fa6ace1e852775e2a770
2018-10-02 09:29:37 -07:00
Pascal Hartig
b756b5490f Set up unit test support in Gradle
Summary:
This works now:

```
./gradlew :android:testDebugUnitTest
BUILD SUCCESSFUL in 1s
39 actionable tasks: 39 up-to-date
```

Reviewed By: danielbuechele

Differential Revision: D10101985

fbshipit-source-id: e3d1f17b29652061498d50a9218a94aaebee67e2
2018-09-30 04:13:53 -07:00
Pascal Hartig
cf1c0748e1 Remove unnecessary plugin sourceSet
Summary: This is from before we adopted the gradle standard layout.

Reviewed By: danielbuechele

Differential Revision: D10101917

fbshipit-source-id: f45ab06cbf4d56a70df1cac6cb1fd234148d2634
2018-09-28 10:14:46 -07:00
Pascal Hartig
c7b0d419cb Rename libsonar* to libflipper*
Summary: Rename the native libraries.

Reviewed By: priteshrnandgaonkar

Differential Revision: D10009245

fbshipit-source-id: 987c4fdb1acc21abbbecfb3db8a672f4aa4e499d
2018-09-25 04:02:29 -07:00