Skip to content

Git hooks cannot execute hooks that delegate to Gradle / Java #13142

@rocketraman

Description

@rocketraman

Version

0.19.6

Operating System

Linux

Distribution Method

rpm (Linux)

Describe the issue

I have a git post-commit hook that delegates to Gradle.

I get the following error when enabling hooks in Butler and committing:

stdout:
Starting a Gradle Daemon


stderr:
WARNING: A restricted method in java.lang.System has been called
WARNING: java.lang.System::load has been called by net.rubygrapefruit.platform.internal.NativeLibraryLoader in an unnamed module (file:/home/raman/.gradle/wrapper/dists/gradle-8.14.1-all/ai1r9v1zgfsr225kjzlvo0rag/gradle-8.14.1/lib/native-platform-0.22-milestone-28.jar)
WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
WARNING: Restricted methods will be blocked in a future release unless native access is enabled


FAILURE: Build failed with an exception.

* What went wrong:
25.0.2

* 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.

BUILD FAILED in 2s
 (Exit Code 1)

If you don't want git hooks to run, disable "Run Git hooks" in project settings.

How to reproduce (Optional)

No response

Expected behavior (Optional)

No response

Relevant log output (Optional)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfeedback requestedFeedback was requested to help resolve the issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions