Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request] Support Gradle configuration cache #202

Open
runningcode opened this issue Jun 20, 2024 · 0 comments
Open

[Feature request] Support Gradle configuration cache #202

runningcode opened this issue Jun 20, 2024 · 0 comments

Comments

@runningcode
Copy link

runningcode commented Jun 20, 2024

This plugin does not support the Gradle configuration cache.

Here is an example of calling external processes (like git) in a Configuration Cache compatible way: https://docs.gradle.org/current/userguide/configuration_cache.html#config_cache:requirements:external_processes

To reproduce, checkout https://github.com/home-assistant/android and run ./gradlew assembleDebug --configuration-cache
Using Gradle 8.8 and 0.18.3 of the reckon settings plugin.

This is the stacktrace:

org.gradle.api.InvalidUserCodeException: Starting an external process '/opt/homebrew/bin/git --version' during configuration time is unsupported.
	at org.gradle.internal.classpath.Instrumented.start(Instrumented.java:319)
	at org.eclipse.jgit.util.FS.readPipe(FS.java:1383)
	at org.eclipse.jgit.util.FS.readPipe(FS.java:1345)
	at org.eclipse.jgit.util.FS.discoverGitSystemConfig(FS.java:1534)
	at org.eclipse.jgit.util.FS.getGitSystemConfig(FS.java:1631)
	at org.eclipse.jgit.util.SystemReader$Default.openSystemConfig(SystemReader.java:106)
	at org.eclipse.jgit.util.SystemReader.getSystemConfig(SystemReader.java:386)
	at org.eclipse.jgit.util.SystemReader.getUserConfig(SystemReader.java:334)
	at org.eclipse.jgit.internal.storage.file.FileRepository.<init>(FileRepository.java:162)
	at org.eclipse.jgit.storage.file.FileRepositoryBuilder.build(FileRepositoryBuilder.java:55)
	at org.ajoberstar.reckon.gradle.ReckonExtension.openRepo(ReckonExtension.java:195)
	at org.ajoberstar.reckon.gradle.ReckonExtension.reckonVersion(ReckonExtension.java:170)
	at org.gradle.api.internal.provider.AbstractMinimalProvider.get(AbstractMinimalProvider.java:100)
	at org.ajoberstar.reckon.gradle.ReckonSettingsPlugin$DelayedVersion.toString(ReckonSettingsPlugin.java:75)
	at org.gradle.kotlin.dsl.execution.Interpreter$ProgramHost.applyPluginsTo(Interpreter.kt:385)
	at Program.execute(Unknown Source)
	at java.base/java.lang.Thread.run(Thread.java:1583)

Below is a screenshot of the configuration cache report.

image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant