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

vscode metals not updating as download fails with ssl errors #1430

Closed
fwaris opened this issue Oct 5, 2023 · 7 comments
Closed

vscode metals not updating as download fails with ssl errors #1430

fwaris opened this issue Oct 5, 2023 · 7 comments

Comments

@fwaris
Copy link

fwaris commented Oct 5, 2023

Describe the bug
metals not updating due ssl certificate issues

Screenshots

Java home: C:\Program Files\Microsoft\jdk-17.0.8.101-hotspot
Metals version: 1.0.1
Downloading https://repo1.maven.org/maven2/org/scalameta/metals_2.13/1.0.1/metals_2.13-1.0.1.pom
[...]
Downloading https://oss.sonatype.org/content/repositories/snapshots/org/scalameta/metals_2.13/1.0.1/metals_2.13-1.0.1.pom.sha1
Resolution error: Error downloading org.scalameta:metals_2.13:1.0.1
not found: C:\Users\fwaris1.ivy2\local\org.scalameta\metals_2.13\1.0.1\ivys\ivy.xml
download error: Caught javax.net.ssl.SSLHandshakeException (PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target) while downloading https://repo1.maven.org/maven2/org/scalameta/metals_2.13/1.0.1/metals_2.13-1.0.1.pom
download error: Caught javax.net.ssl.SSLHandshakeException (PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target) while downloading https://dl.bintray.com/scalacenter/releases/org/scalameta/metals_2.13/1.0.1/metals_2.13-1.0.1.pom

Installation:

  • Operating system: Windows
  • VSCode version: latest as of 10/5
  • VSCode extension version:
  • Metals version: (found in VSCode settings, under metals.serverVersion)

Additional context

I have update java version to latest

@tgodzik
Copy link
Contributor

tgodzik commented Oct 6, 2023

Thanks for reporting! To sure what might exactly be wrong, but you could try adding -noverify to metals.serverProperties as a workaround. A similar issue happened here coursier/coursier#1977

@fwaris
Copy link
Author

fwaris commented Oct 13, 2023

I think the issue is with our networking. The update does not work under a vpn connection but works outside of it

@fwaris fwaris closed this as completed Oct 13, 2023
@wpopielarski
Copy link

@tgodzik unfortunately the trick with -noverify is not working for metals extension in vscode behind vpn.

@tgodzik
Copy link
Contributor

tgodzik commented May 20, 2024

We've had similar issue in Scala CLI more recently. Maybe something in VirtusLab/scala-cli#2191 might help?

@fwaris
Copy link
Author

fwaris commented May 20, 2024 via email

@wpopielarski
Copy link

so to install metals 1.3.1 and bloop 1.5.17 in viscose I did steps:

  1. decrease metals extension version to 1.27 to allow crousier to load newest artifacts (to skip that certificate annoying problem, I had set -noverify but not sure if any impact of it)
  2. install metals 1.3.1
  3. restore version of extension back to 1.34.0
  4. so in this point I faced problem with starting of bloop server so in step
  5. restart Mac
  6. coffee after 4 hours of investigation

@tgodzik
Copy link
Contributor

tgodzik commented May 21, 2024

You can use sbt BSP as alternative. What logs do you see when it doesn't start?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants