Skip to content

jbang fails to resovle guice #1556

@iocanel

Description

@iocanel

Describe the bug
Creating a jbang qcli command that contains quarkus-cli as a dependency result in the command failing to run with:

Caused by: org.eclipse.aether.transfer.ArtifactNotFoundException: Could not find artifact com.google.inject:guice:no_aop:jar:4.2.2 in central (https://repo.maven.apache.org/maven2)
	at org.eclipse.aether.connector.basic.ArtifactTransportListener.transferFailed(ArtifactTransportListener.java:48)
	at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:401)
	at org.eclipse.aether.util.concurrency.RunnableErrorForwarder.lambda$wrap$0(RunnableErrorForwarder.java:73)
	at org.eclipse.aether.connector.basic.BasicRepositoryConnector$DirectExecutor.execute(BasicRepositoryConnector.java:669)
	at org.eclipse.aether.connector.basic.BasicRepositoryConnector.get(BasicRepositoryConnector.java:290)
	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:520)
	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:408)
	... 38 more
[jbang] If you believe this a bug in jbang, open an issue at https://github.com/jbangdev/jbang/issues

The dependency does exist on central: https://repo1.maven.org/maven2/com/google/inject/guice/4.2.2/

To Reproduce
Steps to reproduce the behavior:

  1. jbang init --template=qcli Reproduce.java
  2. open Reproduce.java
  3. Add //DEPS io.quarkus:quarkus-cli:${quarkus.version:2.11.2.Final}@jar
  4. exit the editor
  5. jbang --verbose Reproduce.java

Expected behavior
The command should run

JBang version
0.102.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions