ODK Tables dev environment struggles

Hello all,

For the last couple of weeks I’ve been trying to set up my development environment correctly.
I’ve got a feeling the documentation about this is outdated.

For example I’m running into the following issues:

  • Gradle sync errors. I had to disable various items in the gradle files in order to get a proper sync.
  • Intent constants not being loaded within the app. When I build the project within Android Studio and deploy it on a device the constants are not loaded correctly, because of that the app doesn’t initialize properly.

Before I jump in detailed problems I want to make sure everything is setup correctly.
The README.md in the tables github repo hasn’t been updated for two years. Is it possible that this is outdated?


Hi @Teun_Betting!

In terms of documentation, the most up to date for setup would be here: https://docs.opendatakit.org/odk2/

Hopefully that helps and if not if you could explain a bit more about the problems you are having (e.g. what you are trying to sync, exactly, that is not syncing, what tool you are using when the problems arise, any error messages) those details will be super helpful.


Sorry. I might have been unclear. I’m trying to setup the dev environment so I can compile the source code of the ODK tables app. I’m using Android Studio.
Android Studio 3.3.1
Build #AI-182.5107.16.33.5264788, built on January 29, 2019
JRE: 1.8.0_152-release-1248-b01 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Windows 10 10.0.

Right now the following error is stopping me from syncing the gradle files within Android Studio.

ERROR: Failed to resolve: com.github.Todd-Davies:ProgressWheel:1.2
Show in Project Structure dialog
Affected Modules: tables_app

WARNING: API 'variant.getExternalNativeBuildTasks()' is obsolete and has been replaced with 'variant.getExternalNativeBuildProviders()'.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getExternalNativeBuildTasks(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
Affected Modules: tables_app

I’ve tried disabling the progresswheel. But that causes more problems because the app references the progresswheel.

@Teun_Betting thanks for clarifying! So I am not 100% sure what you are trying to do in terms of compiling the source code for tables (tables is something that generally runs on the tablet – that’s where you download it) still but it sounds like you are having a problem in Android Studio. One idea: do you need the full android studio or just SDK? See: https://docs.opendatakit.org/odk2/app-designer-prereqs/#android-sdk

In terms of building the project (survey?) this is something that is done using app designer and xlsx converter generally and then you push it to the device. Perhaps you can explain a bit more where you are within that process.

I believe @Teun_Betting is referring to building the Android APKs not bulding an “application” to run on the ODK X (aka ODK 2) rendering environment.

I just tried to recreate your issue with Android Studio 3.3.2 (latest release) and I did not have an error.

Steps I performed:

  1. Check out Tables from github
  2. Open “Android Studio”
  3. Select “Import Project”
  4. Created a configuration with the tasks “clean installSnapshotBasicDebug” 5) Clicked on run

Yes @W_Brunette you are correct.

I’ve updated Android Studio. And followed your steps.

  1. I still get the same error (Failed to resolve: com.github.Todd-Davies:ProgressWheel:1.2) during the gradle sync.
  2. I’ve tried to create the task “clean installSnapshotBasicDebug” just like you. But I’m not sure if I’ve configured it correctly. Please see the attached screenshot of my configuration.

Thanks for the help.

The build system is dependent on jitpack.io to work.

Investigating further, there appears to be a build issue that somehow appeared.

Try the development branch of ODK tables. It should be fixed in preparation for the next release.