Commit Graph

63 Commits

Author SHA1 Message Date
Pascal Hartig
74c9f8ea33 Upgrade gradle and gradle plugin (#1327)
Summary:
Android Studio is on 4.0 now, we need the plugin for proper support.
Pull Request resolved: https://github.com/facebook/flipper/pull/1327

Test Plan: Synced and build with it.

Reviewed By: nikoant

Differential Revision: D22356268

Pulled By: passy

fbshipit-source-id: 63c7b727e9a0eaaea7beed1f9819c1e2d15a0ff4
2020-07-02 11:15:09 -07:00
Joshua Selbo
e6b7c9a346 Migrate Sonar Android tests (#1045)
Summary: Pull Request resolved: https://github.com/facebook/flipper/pull/1045

Reviewed By: passy

Differential Revision: D21181354

fbshipit-source-id: ddc329f8bafd5890b7428642d32f7f62e1d499ad
2020-04-23 15:19:32 -07:00
Pascal Hartig
7fdcbdcd59 Bump SoLoader to 0.9.0
Summary: Released the new version today: https://github.com/facebook/SoLoader/releases/tag/v0.9.0

Reviewed By: jknoxville

Differential Revision: D21061477

fbshipit-source-id: c19147f6a28641cd2f23536a56750b27cc195435
2020-04-16 03:16:19 -07:00
Pascal Hartig
59ac58466c Update Android deps (#999)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/999

Pritesh reminded me of this. Just some of the basics,
the plugin itself for simpler dep updates, Kotlin,
NDK (as the one referenced wasn't even installed on my laptop anymore),
Litho.

Reviewed By: jknoxville

Differential Revision: D20946199

fbshipit-source-id: 85ee57ef239ab219af3f07d90c121f3ab8b5f9b9
2020-04-16 01:51:31 -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
Pascal Hartig
9f899c7026 Upgrade to SoLoader 0.8.2
Summary: No changes that should impact us in any way.

Reviewed By: priteshrnandgaonkar

Differential Revision: D19856578

fbshipit-source-id: 35113b4b9e56b6c0b09681ac5649705cf840f60c
2020-02-13 12:06:53 -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
Pascal Hartig
0dd7c277d4 Bump gradle download library
Summary:
https://github.com/michel-kraemer/gradle-download-task#migrating-from-version-3x-to-4x

Major release but we're not affected by any of the changes, could use some of those in CI though.

Reviewed By: jknoxville

Differential Revision: D18394402

fbshipit-source-id: 89773776a11ad0c0d5ff8eb8875eb06546e43072
2019-11-08 04:34:59 -08:00
Pascal Hartig
96049d43a5 Bump gradle plugin
Summary: To match latest stable Android Studio.

Reviewed By: jknoxville

Differential Revision: D18347347

fbshipit-source-id: fd1d4111b34bc8a00f0c0ee5cfe4636fb20f8d41
2019-11-06 11:03:48 -08:00
Andres Suarez
54ebb44dda Tidy up Flipper license headers [2/2]
Reviewed By: passy

Differential Revision: D17863710

fbshipit-source-id: 5b249bdd1c06d3a526b250b035b797d0c8e796eb
2019-10-11 13:46:45 -07:00
Pascal Hartig
9af2030b43 Bump SoLoader dependency
Summary: 0.8.0 is required for compatibility of our sample app with new fbjni.

Reviewed By: jknoxville

Differential Revision: D17547812

fbshipit-source-id: 5ad98fe5629cd63be8a253c881e20e8df4d0df74
2019-09-24 15:21:02 -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
96d5e3ceff Bump gradle version
Summary: Android Studio asked me to.

Reviewed By: danielbuechele

Differential Revision: D17501199

fbshipit-source-id: 4e57fad00c2b92ff04909d21474f3869d9adedc1
2019-09-23 06:18:14 -07:00
Pascal Hartig
a884f1a4ac Bump Android SDK to 29 (#547)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/547

Only affecting the Gradle/Open Source build.

Reviewed By: danielbuechele

Differential Revision: D17394866

fbshipit-source-id: 0bb77847173018a27b7552407b1d5dce10f52d0d
2019-09-16 08:13:54 -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
6168b3c604 Upgrade to Fresco 2.0.0
Summary: Need a Fresco release including the previous diff first.

Reviewed By: danielbuechele

Differential Revision: D15762090

fbshipit-source-id: ec30778ffc1cd3e48dcfc4d514a9ba13fb26fd75
2019-06-13 10:18:20 -07:00
Pascal Hartig
afe7c8bf25 Upgrade to Fresco 1.14.2
Summary: Includes the LeakTracker interface change. Restores the temporarily deleted tracker, wires it back up. Requires Fresco 0.14.2 being released which has yet to happen.

Reviewed By: oprisnik

Differential Revision: D15655667

fbshipit-source-id: ab4361be35101efe7564dfdd7a69cba93135eb7e
2019-06-06 08:02:46 -07:00
Pascal Hartig
7dc3525846 Bump fresco to 0.14.1
Summary: Required for the next diff as we make use of the new CloseableReference interface.

Reviewed By: oprisnik

Differential Revision: D15558423

fbshipit-source-id: 98ce5bf3f01a6f0e7ca568544709656c41093505
2019-05-31 15:43:45 -07:00
Pascal Hartig
fd88e1d01c Bump Gradle plugin to 3.4.1
Summary:
This matches the latest stable Android Studio version which will loudly
complain unless you accept this modification.

Reviewed By: danielbuechele

Differential Revision: D15520117

fbshipit-source-id: 81301722d85cbcb07fc1b17b6ce7418d03103874
2019-05-29 03:34:20 -07:00
Pritesh Nandgaonkar
914cbf6ccd Request all metadata for Images plugin before export
Summary:
Fresco plugin on the desktop side used to ask for all the image list along with the metadata when it was mounted. The mobile side never sent the image list and other information if not requested from it. That means, although Fresco plugin is a background plugin, there weren't any messages sent from the mobile side. Thus there was no trace available for Images plugin when the trace was exported. This diff, adds a hook which gets called before the export, where we request all the metadata from the mobile SDK.

BUG:

{F159305887}

Reviewed By: passy

Differential Revision: D15407962

fbshipit-source-id: 0012de2ab29d0f62e92d00f4926b04b1e394b62a
2019-05-23 05:48:04 -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
3339944ff4 Tutorial app
Summary:
A very basic app with a scrolling list backed by a static data source. It also covers two bases that we hadn't before: Sections and Kotlin; the latter being the better choice for a modern Android tutorial anyway.

Missing right now: BUCK support (likely not going to come anytime soon due to the kapt limitations), the actual Flipper plugin integration (that's up next).

Reviewed By: jknoxville

Differential Revision: D15166195

fbshipit-source-id: 3cfaa1d243548279cabc4f244c13363f1bcaa36c
2019-05-01 09:39:52 -07:00
Pascal Hartig
3771026eeb Bump gradle plugin (#424)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/424

New Android Studio, new plugin version.

Reviewed By: jknoxville

Differential Revision: D15146831

fbshipit-source-id: 12d624c8bc36e7bc8c1ddf69adbcc154d66dc077
2019-04-30 13:13:00 -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
Pascal Hartig
9389a8e919 Bump some more dependencies (#414)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/414

Some more minor upgrades.

Reviewed By: jknoxville

Differential Revision: D14933687

fbshipit-source-id: 35bfcbb2ab3e552e430d8a2e3e30fb3568fab6c9
2019-04-15 09:57:59 -07:00
Pascal Hartig
59881f1888 Bump okhttp
Summary:
Requires some compile options as it uses newer Java features.
Post here: https://github.com/square/okhttp/issues/4597#issuecomment-461204144

Reviewed By: jknoxville

Differential Revision: D14933502

fbshipit-source-id: 265c43f2d9ae61fa9f6f42516fc6eb899af7f072
2019-04-15 06:55:21 -07:00
Pascal Hartig
3de3ef27d1 Bump versions plugin
Summary:
Updating some deps and starting with the thing
that helps identify outdated things.

Reviewed By: jknoxville

Differential Revision: D14933477

fbshipit-source-id: 3a0f84abf97f9327ecab72388e114a1fb533504b
2019-04-15 06:55:21 -07:00
Pascal Hartig
56d597985d Bump Android plugin
Summary: Latest Android Studio is complaining otherwise.

Reviewed By: jknoxville

Differential Revision: D14639287

fbshipit-source-id: 81814e10d7de5f293295892c9c6dd19ebf525ed7
2019-03-27 13:48:54 -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
6a8abb3be6 Prevent release
Summary:
Move the snapshot repository into the SNAPSHOT block.
This will mean that trying to build a release version will now
fail because it can't resolve the dependency like this:

```

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine the dependencies of task ':android:compileReleaseAidl'.
> Could not resolve all task dependencies for configuration ':android:releaseCompileClasspath'.
   > Could not find com.github.facebook:fresco:0ff379c262.
     Searched in the following locations:
       - file:/opt/android-sdk/extras/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - file:/opt/android-sdk/extras/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - file:/opt/android-sdk/extras/google/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - file:/opt/android-sdk/extras/google/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - file:/opt/android-sdk/extras/android/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - file:/opt/android-sdk/extras/android/m2repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - https://dl.google.com/dl/android/maven2/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - https://dl.google.com/dl/android/maven2/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - file:/home/realpassy/.m2/repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - file:/home/realpassy/.m2/repository/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - https://repo.maven.apache.org/maven2/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - https://repo.maven.apache.org/maven2/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
       - https://jcenter.bintray.com/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.pom
       - https://jcenter.bintray.com/com/github/facebook/fresco/0ff379c262/fresco-0ff379c262.jar
     Required by:
         project :android

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.1.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 2s
```

Reviewed By: priteshrnandgaonkar

Differential Revision: D14279359

fbshipit-source-id: 6b86a0232d7a4ded8c94bd3a0e0dd08116f13719
2019-03-01 04:42:34 -08:00
Aziz Murtazaev
0279fc919f Move android module's support lib references to AndroidX
Summary: SupportLib v28 -> AndroidX v1

Reviewed By: passy

Differential Revision: D14150032

fbshipit-source-id: f9c0d15a4f281fea78500e78275eb260e484e674
2019-02-21 09:26:07 -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
0d185108a7 Bump to target SDK 28
Summary:
We need this to continue to build with Fresco and
in preparation of AndroidX.

Reviewed By: muraziz

Differential Revision: D14149811

fbshipit-source-id: dd227f85ead23b8412706905f8723b3c153b28b7
2019-02-20 13:54:29 -08:00
Pascal Hartig
ab6ebf665e Bump android gradle plugin (#372)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/372

Some prep for AndroidX upgrade.

Reviewed By: danielbuechele

Differential Revision: D14101014

fbshipit-source-id: 15571528340ea149be77985b3d194d832f253597
2019-02-15 08:54:10 -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
921414d3e3 SoLoader v0.6.0
Summary: Bumping the version.

Reviewed By: danielbuechele

Differential Revision: D13860124

fbshipit-source-id: 33bf81706e33186e039b781d6fc149b3e47d95be
2019-01-29 09:13:12 -08:00
Pascal Hartig
25c6323b9e Move last plugin to plugin dsl
Summary:
Last one that's available through the DSL. The Android
plugin still isn't.

Reviewed By: jknoxville

Differential Revision: D13176791

fbshipit-source-id: 6684812bb4fee1dcd9db1503e660fb019160224e
2018-11-23 07:49:58 -08:00
Pascal Hartig
cadda77d74 Move versions plugin to plugin DSL (#331)
Summary:
Doesn't change how it works, but using the new recommended mechanism for loading plugins.
Pull Request resolved: https://github.com/facebook/flipper/pull/331

Reviewed By: jknoxville

Differential Revision: D13167476

Pulled By: passy

fbshipit-source-id: ac0ae925f5780136ce5c1fcb666faa79c19e049c
2018-11-23 06:18:44 -08:00
Pritesh Nandgaonkar
e02420ac78 Make android project compile with new gradle and build tools
Summary:
If this is not done. I get
```
Could not find aapt2-proto.jar (com.android.tools.build:aapt2-proto:0.3.1).
Searched in the following locations:
    https://jcenter.bintray.com/com/android/tools/build/aapt2-proto/0.3.1/aapt2-proto-0.3.1.jar
```
I follwed the suggestion given on [stack overflow](https://stackoverflow.com/questions/52944598/could-not-find-aapt2-proto-jar)

Reviewed By: jknoxville

Differential Revision: D12839581

fbshipit-source-id: aa02620c7e4c52899b2c2c4805fd8a6f168d946a
2018-11-15 06:37:55 -08:00
Pascal Hartig
a7fd546f0e Add basic integration test
Summary:
Just a quick startup test that can save you the time of manually
opening the app.

I don't have any plans of hooking this up in Circle, but it's
still kinda useful to have.

Reviewed By: jknoxville

Differential Revision: D12901590

fbshipit-source-id: a16a1814574d9f27770dcf98c6b238517c589930
2018-11-02 07:09:51 -07:00
Pascal Hartig
66790e12e6 Bump build tools
Summary: This is actually the new minimum required version for the gradle plugin we use.

Reviewed By: jknoxville

Differential Revision: D10505346

fbshipit-source-id: ce331851b74997369325f27f050efae07e4bf00c
2018-10-23 04:44:52 -07:00
Pascal Hartig
c5a94d871c Bump gradle tools
Summary: Otherwise latest Android Studio complains.

Reviewed By: jknoxville

Differential Revision: D10464342

fbshipit-source-id: 4351574f2bd8ca5742ed057f3441571575e0940c
2018-10-20 05:11:14 -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
John Knox
7dd4a83c9a Update gradle version
Summary: Pull Request resolved: https://github.com/facebook/flipper/pull/269

Reviewed By: passy

Differential Revision: D9861391

Pulled By: jknoxville

fbshipit-source-id: 2d40054049b1405607baf99d20680df1dc41acb0
2018-09-17 08:59:34 -07:00
Pascal Hartig
cded1ceead Switch to Litho snapshot releases
Summary:
This allows breaking changes in Litho to be landed.
I'm also adding some helpers to determine if Flipper itself
is currently in a release or snapshot release train.

N.B. We don't publish snapshot releases for Flipper
right now, but will in the future where this will come in
handy.

Reviewed By: jknoxville

Differential Revision: D9359035

fbshipit-source-id: d21b607eca5d57caf4cc34234f6ba3cb0d8f307d
2018-08-16 06:56:30 -07:00
Pascal Hartig
ef2659fd34 Remove Kotlin setup
Summary: We don't use it, so we shouldn't download it.

Reviewed By: jknoxville

Differential Revision: D9262618

fbshipit-source-id: 56aef9abc788cc75790e1f70da6cc2a513e5f18b
2018-08-12 07:56:44 -07:00
Pascal Hartig
dedd953c28 Move leakcanary to open source and add build files
Summary:
Made sure it builds with both buck and Gradle.

Follow-up to D8865149.

Reviewed By: danielbuechele

Differential Revision: D9178885

fbshipit-source-id: 46efaa532efdc1d59ce76e04be6680e233084881
2018-08-06 03:14:20 -07:00