Unable to edit UI files due to invalid option in Gradle file

(wdb) #1

When I select Fire’s option to edit user interface files in Android Studio it’s starting up the application only I am unable to modify UI files in the visual editor as it says Preview is unavailable until after a successful project sync.

This was due to a compiler error which was:

ERROR: Could not find method jackOptions() for arguments [build_cqmsnz1jqa3c5b41ldrxjvgzq$_run_closure1$_closure3$_closure6@2289e8c0] on DefaultConfig_Decorated{name=main, dimension=null, minSdkVersion=DefaultApiVersion{mApiLevel=15, mCodename='null'}, targetSdkVersion=DefaultApiVersion{mApiLevel=27, mCodename='null'}, renderscriptTargetApi=null, renderscriptSupportModeEnabled=null, renderscriptSupportModeBlasEnabled=null, renderscriptNdkModeEnabled=null, versionCode=1, versionName=1.0, applicationId=org.me.XAndroid, testApplicationId=null, testInstrumentationRunner=null, testInstrumentationRunnerArguments={}, testHandleProfiling=null, testFunctionalTest=null, signingConfig=null, resConfig=null, mBuildConfigFields={}, mResValues={}, mProguardFiles=[], mConsumerProguardFiles=[], mManifestPlaceholders={}, mWearAppUnbundled=null} of type com.android.build.gradle.internal.dsl.DefaultConfig.

Open File` after removing the following bit the visual editor was working again:

        jackOptions {
            enabled true

Maybe worth looking into? I assume this file gets generated by Fire as it’s not available in my Android project directory.

I am using:
Elements compiler: Version (develop) built on talax, 20190411-060527. Commit 4e838c1.
Android Studio 3.3.2
Build #AI-182.5107.16.33.5314842, built on February 15, 2019
JRE: 1.8.0_152-release-1248-b01 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
macOS 10.14.4


(marc hoffman) #2

Can I get a test case project for this?


(marc hoffman) #3

nevermind. found it, and removed the option from the generated project for vNext (not 2395, which is
already built and will be out later today).


1 Like

(JeremyK) #4

I just came across this. Finally looking at Android :wink:
I just created a new default android app with [latest] Fire, and came across this (though I found it’s deprecated so just removing it is fine) and something else.
Initially it says it couldn’t sync, then removing jackoptions and trying again gives:

ERROR: The minSdk version should not be declared in the android manifest file. You can move the version from the manifest to the defaultConfig in the build.gradle file.
Remove minSdkVersion and sync project
Affected Modules: app

WARNING: Configuration ‘compile’ is obsolete and has been replaced with ‘implementation’ and ‘api’.
It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html
Affected Modules: app

First one is easily re-factored, second one doesn’t seem to cause any problems so I’m guessing it’s just something you can sort in the project template.


(marc hoffman) #5

i’ve dropped the value from the templates; it tersely shouldn’t be there anyways, as we have the project setting to set it (and that adds it back to the final manifest that goes into the .apk).

hmm, I’ll have that looked at, I assume that’s referring to the syntax of of the project we generate for sync specifically. Unfortunately I can’t test this myself right now, as my Android Studio complains about other (stupid and unrelated) stuff; it tells me I can’t build the project because I’m missing NDK images for mips64el-linux-android. Now why the hell I’d need those for a non-NDK Android SDK app to open in Android Studio — beats the heck me. :(.


(JeremyK) #6

Oh, I had some stuff like that, but just installed everything Android Studio asked for. Had quick play around there with the emulator before reverting to my preferred IDE :wink:

It’s quite nice on the dark side so far (3 hours in), just having a play around. Next I’ll be looking at shared projects, and how to make a DA project for android (I’m guessing I need Water for that like iOS).


(marc hoffman) #7

Yeah, thing is the mips64el-linux-android platform no longer is supported by there NDK. :frowning:


That should work in Fire as well. unless you want to connect tom a custom server; we dont have the wizard for that ported yet, so you’d have to do the “Connect to server” once in VS (after that, you can work in Fire or Water). on the list. Connecting to Relativity already works in Fire and Water, too.

Let me know how it goes!


(marc hoffman) #8

Got that sorted. but wow, this is some grade a ui design here:

how the f**k do people work with IntelliJ?


(marc hoffman) #9

And fixed.

1 Like

(JeremyK) #10

How are they installed then, as I’ve not got any DA templates in Fire so perhaps I’ve missed something? In fact, I don’t see any in water but I do in VS (having just gone through the tortuous process of installing elements and DA in windows and waiting what felt like an eternity for VS to run).

Yep, hence my comment about reverting to Fire.


(marc hoffman) #11

There’s no template, because the idea is that, in theory, any kind pf project can be a DA (or RO) client. You would use the “Connect to Server” menu: https://docs.remotingsdk.com/IDEs/Fire/ConnectToServer/



(JeremyK) #12

Ah, yes, of course I can just do that. It’s been a while, I’d forgotten about that. I keep thinking back to when the DA template creates the DataAccess class and suchlike which made it easy to pick up everything needed to get going (my old apps still have those!).


1 Like

(marc hoffman) #13

so does this :wink:

1 Like

(wdb) #14

Awesome, great that it got fixed!

1 Like