spring-projects / spring-projects/spring-security-samples

spring-security-samples/servlet/spring-boot/java/oauth2/login doesn't run

Open
#202 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
1.8k
Forks
797
Avg merge
3m
Merged PRs (30d)
5

Description

To reproduce:
gh repo clone spring-projects/spring-security-samples
cd spring-security-samples/
cd servlet/spring-boot/java/oauth2/login/
./gradlew bootRun

Gives the following error:

hosermage@LAPTOP-1RPE37PF:~/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login$ ./gradlew bootRun

FAILURE: Build failed with an exception.

* Where:
Build file '/home/hosermage/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login/build.gradle' line: 2

* What went wrong:
Could not compile build file '/home/hosermage/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login/build.gradle'.
> startup failed:
  build file '/home/hosermage/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login/build.gradle': 2: only alias(libs.plugins.someAlias) plugin identifiers where `libs` is a valid version catalog

  For more information on the plugins {} block, please refer to https://docs.gradle.org/8.3/userguide/plugins.html#sec:plugins_block in the Gradle documentation.

   @ line 2, column 2.
        alias(libs.plugins.org.springframework.boot)
      ^

  build file '/home/hosermage/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login/build.gradle': 3: only alias(libs.plugins.someAlias) plugin identifiers where `libs` is a valid version catalog

  For more information on the plugins {} block, please refer to https://docs.gradle.org/8.3/userguide/plugins.html#sec:plugins_block in the Gradle documentation.

   @ line 3, column 2.
        alias(libs.plugins.io.spring.dependency.management)
      ^

  2 errors


* 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 530ms
hosermage@LAPTOP-1RPE37PF:~/projects/spring-security-samples/servlet/spring-boot/java/oauth2/login$

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in servlet/spring-boot/java/oauth2/login/build.gradle, especially the plugins block reported at lines 2-3, and reproduce with ./gradlew bootRun from that directory. Compare the plugin declarations with the Gradle 8.3 error and verify that the sample builds and starts successfully with bootRun.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring-boot
Domain
build-system
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.