Getting Help
- Troubleshooting
- SwiftUI Previews in Xcode 16 cause Android app to build and launch
- App crash on return from background
- Premature license expiration
- Xcode 15 build error: Internal inconsistency error (didStartTask): targetID (174) not found in _activeTargets
- Build error: Inconsistent JVM-target compatibility detected for tasks âcompileDebugJavaWithJavacâ (17) and âcompileDebugKotlinâ (22)
- Skip doctor reports: macOS architecture: wrong architecture 1, Rosetta must not be enabled for process on (Intel)
- Android Studio Error: Minimum supported Gradle version is 8.7. Current version is 8.5.
- Wrong line highlighted in builds
The Troubleshooting section below has tips for dealing with common Skip tooling issues.
The best way to get help and connect with fellow Skip users is to join the community Slack, where you can find real-time support and the community expertise to help you succeed with your project. You can also use the Skip discussion forums to send feedback, ask questions, or search for solutions to issues. For bug reports, use the issue tracker.
You can always contact the Skip team directly at support@skip.tools.
Please include the output of the skip checkup
command in any communication related to technical issues.
Troubleshooting
Skipâs architecture relies on recent advances in the plugin system used by Xcode 15 and Swift Package Manager 5.9. When unexpected issues arise, often the best first step is to clean your Xcode build (Product
â Clean Build Folder
) and reset packages (File
â Packages
â Reset Package Caches
). Restarting Xcode is sometimes warranted, and trashing the local DerivedData
folder as well as your app directoryâs .build
folder might even be needed.
Specific known error conditions are listed below. Search the documentation, issues, and discussions for more information and to report problems.
SwiftUI Previews in Xcode 16 cause Android app to build and launch
In Xcode 16, using a SwiftUI preview will have the surprising side-effect of compiling and launching the Android version. This issue is discussed at https://github.com/orgs/skiptools/discussions/263. The only workaround for now is âEditor > Canvas > Use Legacy Previews Executionâ.
App crash on return from background
Apps created with Skip prior to version 1.1.8 may occasionally crash when being restored from the background. To fix this, add the following line to setContent
in the onCreate
function in Main.kt
:
setContent {
val saveableStateHolder = rememberSaveableStateHolder()
saveableStateHolder.SaveableStateProvider(true) {
PresentationRootView(ComposeContext())
// vvv Add the line below vvv
androidx.compose.runtime.SideEffect { saveableStateHolder.removeState(true) }
}
}
Premature license expiration
An error with the Skip license key checking surfaced on October 1st, 2024, which caused the following error to be issued when building a Skip project:
The skip.tools license was created with a version of the software that expired on 2024-10-01 00:00:00 +0000 and must be re-generated
We fixed the problem in Skip 1.1.6. You can upgrade from Xcode using File/Packages/Update to Latest Package Versions
, or by setting 1.1.6 as the version in your Package.swift
.
Xcode 15 build error: Internal inconsistency error (didStartTask): targetID (174) not found in _activeTargets
Xcode sometimes reports error messages like the following:
Internal inconsistency error (didStartTask): targetID (174) not found in _activeTargets.
Internal inconsistency error (didEndTask): '12' missing from _activeTasks.
When these errors occur, the build appears to complete successfully although changes are not applied. Unfortunately, this is an Xcode bug. We have found the following workarounds:
- Update to Xcode 16+. The bug primarily affects Xcode 15, and it seems to be fixed or greatly reduced on Xcode 16+.
- Continue to retry the build. Eventually Xcode may complete successfully, although the errors often continue to become more frequent until you are forced to apply one of the other solutions below.
- Building a different target and then re-building your app target may clear the error.
- Restart Xcode.
- Clean and rebuild.
You can read more about this Xcode error on the Swift.org forums. This is reported as being fixed in Xcode 16.
Build error: Inconsistent JVM-target compatibility detected for tasks âcompileDebugJavaWithJavacâ (17) and âcompileDebugKotlinâ (22)
The same JVM target must be used across the entire Gradle project, which includes both your own app as well as any and all Skip dependencies. This is some automatically in Skip frameworks using the compileOptions
sourceCompatibility
and targetCompatibility
, but now it also needs to be added to a kotlinOptions
block by setting the jvmTarget
target in the appâs Android/app/build.gradle.kts
file like so:
android {
compileOptions {
sourceCompatibility = JavaVersion.toVersion(libs.versions.jvm.get())
targetCompatibility = JavaVersion.toVersion(libs.versions.jvm.get())
}
kotlinOptions {
jvmTarget = libs.versions.jvm.get().toString() // this line added
}
}
Skip doctor reports: macOS architecture: wrong architecture 1, Rosetta must not be enabled for process on (Intel)
When running skip doctor
or skip checkup
, it may fail with the error:
macOS architecture: wrong architecture 1, Rosetta must not be enabled for process on (Intel)
Rosetta, the Intel emulation layer for ARM-based macOS machines, is incompatible with the Kotlin/Gradle build process that Skip uses to build the Android app.
This error likely indicates that the Homebrew Intel version is installed, but the current machineâs architecture is ARM (e.g., an M-series Mac). This is most often caused by a migration from an Intel Mac to an ARM Mac without subsequently reinstalling Homebrew. You can verify this is the case by running brew doctor
, or checking whether it is installed in /usr/local/homebrew
(the default Intel folder) rather than /opt/homebrew
(the default ARM folder). The solution to this issue is to re-install Homebrew from https://brew.sh/#install, and then re-install skip, and try to run skip checkup
again.
Another possibility is that the Terminal process itself is running under Rosetta for some reason (often because it had been manually enabled to work around some issue in the past). The solution is to right-click the Terminal icon in the macOS dock and select Options
/ Show in Finder
, and then with Terminal.app
selected, select Finderâs File
/ Get Info
menu. In the resulting dialog window, ensure that the âOpen using Rosettaâ checkbox is un-selected. After deselecting the checkbox, restart the Terminal.app
app and re-try skip checkup
.
Android Studio Error: Minimum supported Gradle version is 8.7. Current version is 8.5.
When opening a Skip project in Android Studio, you may encounter an error like:
Minimum supported Gradle version is 8.7. Current version is 8.5. If using the gradle wrapper, try editing the distributionUrl in gradle-wrapper.properties to gradle-8.7-all.zip
This means that the version of Android Studio that is installed ships with an older version of Gradle that is incompatible with the latest version of the
You can direct Android Studio to instead use the Homebrew-installed gradle version by opening Settings
/ Build, Execution, Deployment
/ Build Tools
/ Gradle
and set "Distribution"
to "Local installation"
and set the directory to:
- Arm Mac:
/opt/homebrew/opt/gradle/libexec
- Intel Mac:
/usr/local/opt/gradle/libexec
Wrong line highlighted in builds
Skip may highlight the wrong line in build errors. When Skip surfaces the wrong line number, it is typically only one line off.