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

Quarkus CLI failes to resolve extension catalog on created app as expected checksum is empty string #32266

Closed
michalvavrik opened this issue Mar 30, 2023 · 12 comments · Fixed by quarkusio/registry.quarkus.io#184
Labels
area/devtools Issues/PR related to maven, gradle, platform and cli tooling/plugins kind/bug Something isn't working

Comments

@michalvavrik
Copy link
Member

Describe the bug

I created app and meant to list extensions, but that's not possible with the 999-SNAPSHOT.

Expected behavior

I can list extensions.

Actual behavior

Command fails.

[ERROR] ❗  Unable to list extensions: Failed to resolve extension catalog

and warning

12:55:53,816 INFO  Looking for the newly published extensions in registry.quarkus.io
12:56:00,708 INFO  2023-03-30 12:55:59,612 WARN  [org.ecl.aet.int.imp.WarnChecksumPolicy] (main) Could not validate integrity of download from https://registry.quarkus.io/maven/io/quarkus/registry/quarkus-platforms/1.0-SNAPSHOT/quarkus-platforms-1.0-SNAPSHOT-999-SNAPSHOT.json: org.eclipse.aether.transfer.ChecksumFailureException: Checksum validation failed, expected '' (REMOTE_EXTERNAL) but is actually 'da39a3ee5e6b4b0d3255bfef95601890afd80709'
12:56:00,712 INFO  	at org.eclipse.aether.connector.basic.ChecksumValidator.validateExternalChecksums(ChecksumValidator.java:179)
12:56:00,713 INFO  	at org.eclipse.aether.connector.basic.ChecksumValidator.validate(ChecksumValidator.java:109)
12:56:00,716 INFO  	at org.eclipse.aether.connector.basic.BasicRepositoryConnector$GetTaskRunner.runTask(BasicRepositoryConnector.java:484)
12:56:00,717 INFO  	at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:414)
12:56:00,717 INFO  	at org.eclipse.aether.connector.basic.BasicRepositoryConnector.get(BasicRepositoryConnector.java:260)
12:56:00,717 INFO  	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:516)
12:56:00,718 INFO  	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:433)
12:56:00,719 INFO  	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:261)
12:56:00,719 INFO  	at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:242)
12:56:00,720 INFO  	at org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:277)
12:56:00,721 INFO  	at io.quarkus.bootstrap.resolver.maven.MavenArtifactResolver.resolveInternal(MavenArtifactResolver.java:164)
12:56:00,722 INFO  	at io.quarkus.bootstrap.resolver.maven.MavenArtifactResolver.resolve(MavenArtifactResolver.java:154)
12:56:00,722 INFO  	at io.quarkus.registry.client.maven.MavenRegistryArtifactResolverWithCleanup.resolveAndCleanupOldTimestampedVersions(MavenRegistryArtifactResolverWithCleanup.java:76)
12:56:00,726 INFO  	at io.quarkus.registry.client.maven.MavenRegistryArtifactResolverWithCleanup.resolveArtifact(MavenRegistryArtifactResolverWithCleanup.java:37)
12:56:00,726 INFO  	at io.quarkus.registry.client.maven.MavenPlatformsResolver.resolvePlatforms(MavenPlatformsResolver.java:41)
12:56:00,727 INFO  	at io.quarkus.registry.client.RegistryClientDispatcher.resolvePlatforms(RegistryClientDispatcher.java:38)
12:56:00,727 INFO  	at io.quarkus.registry.RegistryExtensionResolver.resolvePlatformCatalog(RegistryExtensionResolver.java:86)
12:56:00,727 INFO  	at io.quarkus.registry.ExtensionCatalogResolver.collectPlatformExtensions(ExtensionCatalogResolver.java:775)
12:56:00,727 INFO  	at io.quarkus.registry.ExtensionCatalogResolver.resolveExtensionCatalog(ExtensionCatalogResolver.java:479)
12:56:00,728 INFO  	at io.quarkus.registry.ExtensionCatalogResolver.resolveExtensionCatalog(ExtensionCatalogResolver.java:715)
12:56:00,728 INFO  	at io.quarkus.devtools.project.buildfile.MavenProjectBuildFile.getProject(MavenProjectBuildFile.java:105)
12:56:00,728 INFO  	at io.quarkus.devtools.project.buildfile.MavenProjectBuildFile.getProject(MavenProjectBuildFile.java:76)
12:56:00,728 INFO  	at io.quarkus.devtools.project.buildfile.MavenProjectBuildFile.getProject(MavenProjectBuildFile.java:65)
12:56:00,729 INFO  	at io.quarkus.cli.build.MavenRunner.quarkusProject(MavenRunner.java:90)
12:56:00,729 INFO  	at io.quarkus.cli.build.MavenRunner.listExtensions(MavenRunner.java:112)
12:56:00,729 INFO  	at io.quarkus.cli.ProjectExtensionsList.call(ProjectExtensionsList.java:82)
12:56:00,729 INFO  	at io.quarkus.cli.ProjectExtensionsList.call(ProjectExtensionsList.java:21)
12:56:00,730 INFO  	at picocli.CommandLine.executeUserObject(CommandLine.java:2041)
12:56:00,730 INFO  	at picocli.CommandLine.access$1500(CommandLine.java:148)
12:56:00,730 INFO  	at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2461)
12:56:00,730 INFO  	at picocli.CommandLine$RunLast.handle(CommandLine.java:2453)
12:56:00,731 INFO  	at picocli.CommandLine$RunLast.handle(CommandLine.java:2415)
12:56:00,731 INFO  	at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2273)
12:56:00,731 INFO  	at picocli.CommandLine$RunLast.execute(CommandLine.java:2417)
12:56:00,731 INFO  	at picocli.CommandLine.execute(CommandLine.java:2170)
12:56:00,732 INFO  	at io.quarkus.cli.QuarkusCli.run(QuarkusCli.java:108)
12:56:00,732 INFO  	at io.quarkus.cli.QuarkusCli_ClientProxy.run(Unknown Source)
12:56:00,732 INFO  	at io.quarkus.runtime.ApplicationLifecycleManager.run(ApplicationLifecycleManager.java:132)
12:56:00,732 INFO  	at io.quarkus.runtime.Quarkus.run(Quarkus.java:71)
12:56:00,732 INFO  	at io.quarkus.runtime.Quarkus.run(Quarkus.java:44)
12:56:00,733 INFO  	at io.quarkus.cli.Main.main(Main.java:9)

How to Reproduce?

cat <<EOF > ./quarkus-dev-cli
#!/bin/bash
java -jar /home/mvavrik/.m2/repository/io/quarkus/quarkus-cli/999-SNAPSHOT/quarkus-cli-999-SNAPSHOT-runner.jar "\$@"
EOF
chmod +x ./quarkus-dev-cli
./quarkus-dev-cli create app app --platform-bom=io.quarkus:quarkus-bom:999-SNAPSHOT
cd app
./../quarkus-dev-cli extension list --id

Output of uname -a or ver

Linux

Output of java -version

openjdk 17.0.4 2022-07-19

GraalVM version (if different from Java)

OpenJDK Runtime Environment GraalVM CE 22.3

Quarkus version or git rev

999-SNAPSHOT

Build tool (ie. output of mvnw --version or gradlew --version)

Apache Maven 3.8.6

Additional information

No response

@michalvavrik michalvavrik added the kind/bug Something isn't working label Mar 30, 2023
@quarkus-bot quarkus-bot bot added the area/cli Related to quarkus cli (not maven/gradle/etc.) label Mar 30, 2023
@quarkus-bot
Copy link

quarkus-bot bot commented Mar 30, 2023

/cc @ebullient (cli), @maxandersen (cli)

@michalvavrik
Copy link
Member Author

/cc @aloubyansky

@michalvavrik michalvavrik added area/devtools Issues/PR related to maven, gradle, platform and cli tooling/plugins and removed area/cli Related to quarkus cli (not maven/gradle/etc.) labels Mar 30, 2023
@rsvoboda
Copy link
Member

@aloubyansky
Copy link
Member

The URL is OK. It is using 999-SNAPSHOT as a target Quarkus version. @gastaldi this looks like a registry issue, could you have a look, please?
https://registry.quarkus.io/maven/io/quarkus/registry/quarkus-platforms/1.0-SNAPSHOT/quarkus-platforms-1.0-SNAPSHOT-999-SNAPSHOT.json results in an empty file, as well as the sha1 checksum for it. It should simply return 404 in case the version isn't recognized.

@gastaldi

This comment was marked as outdated.

@gastaldi

This comment was marked as off-topic.

@gastaldi
Copy link
Contributor

@aloubyansky the current behavior is to return HTTP/1.1 204 No Content when the Platform exists but the requested version does not. I'll change it to return 404 instead in this case

@aloubyansky
Copy link
Member

@gastaldi didn't the registry change in some way recently? I thought it was working before?

@aloubyansky
Copy link
Member

No, it's not the registry. 2.16.2.Final CLI works, so it's a change in the Maven resolver version.

@gastaldi
Copy link
Contributor

The change was deployed in registry.quarkus.io and I don't see the issue happening. Can you confirm @michalvavrik?

@aloubyansky
Copy link
Member

Thanks @gastaldi!

@michalvavrik
Copy link
Member Author

@gastaldi fixed, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/devtools Issues/PR related to maven, gradle, platform and cli tooling/plugins kind/bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants