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

Error while using maven-gpg-plugin after setting GPG data #554

Closed
2 of 5 tasks
Lycoon opened this issue Nov 15, 2023 · 7 comments
Closed
2 of 5 tasks

Error while using maven-gpg-plugin after setting GPG data #554

Lycoon opened this issue Nov 15, 2023 · 7 comments
Assignees
Labels
documentation Improvements or additions to documentation external Unexpected behavior was caused by external problems

Comments

@Lycoon
Copy link

Lycoon commented Nov 15, 2023

Description:
I set my GPG private key and passphrase through setup-java action, the problem is, the maven-gpg-plugin seems to fail at retrieving them from settings.xml prompting the following message: gpg: Sorry, no terminal at all requested - can't get input.

Task version:
actions/setup-java@v3

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Repro steps:
I am currently trying to make it work on this repo.
The GitHub Actions workflow file can be found here and the pom.xml file at the root of the repository.

@Lycoon Lycoon added bug Something isn't working needs triage labels Nov 15, 2023
@IvanZosimov
Copy link
Contributor

Hi, @Lycoon 👋 Thanks for the issue, we will take a look and get back to you as soon as we have updates.

@IvanZosimov IvanZosimov self-assigned this Nov 16, 2023
@IvanZosimov
Copy link
Contributor

@Lycoon, I've checked out and tested your solution. It seems that setup-java works correctly as gpg key is imported and settings.xml is created correctly. I suspect that the problem is inside your pom.xml file or in the mvn deploy command itself. I see that you use Profile named sign and the settings inside it seems OK to me, but does maven use it? Could you, please, enable debug logging for maven and share the logs with us?

@Lycoon
Copy link
Author

Lycoon commented Nov 16, 2023

Sure, you will find the logs with debug logging enabled just here.
Plus Maven seems to use the profile as it loads the maven-gpg-plugin which is exclusively present inside.

@IvanZosimov
Copy link
Contributor

@Lycoon, Thank you! Could you, please, try to update version of the maven-gpg-plugin to 1.6?

@Lycoon
Copy link
Author

Lycoon commented Nov 17, 2023

Thank you so much, it works now! 🎉
Maybe adding a little disclaimer about not using maven-gpg-plugin prior to 1.6 could save precious time to the next person facing the same issue ;)

@IvanZosimov IvanZosimov added external Unexpected behavior was caused by external problems documentation Improvements or additions to documentation and removed bug Something isn't working labels Nov 20, 2023
@IvanZosimov
Copy link
Contributor

@Lycoon, thanks for suggestion, I marked the issue with documentation label. As soon as we add additional information about this plugin to the action's documentation, I'll close this issue by myself.

@IvanZosimov
Copy link
Contributor

Hi, @Lycoon 👋 In this PR we added suggested changes to action's documentation. Thank you one more time 💌 !

I'm closing this issue now, If you have any additional questions feel free to reach out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation external Unexpected behavior was caused by external problems
Projects
None yet
Development

No branches or pull requests

2 participants