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

Problems with npm run build-server on Windows #86

Closed
ralfhandl opened this issue Nov 9, 2018 · 4 comments
Closed

Problems with npm run build-server on Windows #86

ralfhandl opened this issue Nov 9, 2018 · 4 comments
Assignees
Labels
bug Something isn't working build
Milestone

Comments

@ralfhandl
Copy link

ralfhandl commented Nov 9, 2018

When trying to build vscode-xml on Windows 10 Enterprise 1803 I run into a few issues:

  1. npm install ends with warnings
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
  1. npm run build-server ends with an error:
Couldn't find "C:\Temp\vscode-xml-build-test\lsp4xml\.mvn\wrapper\maven-wrapper.jar", downloading it ...
Downloading from: "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.4.2/maven-wrapper-0.4.2.jar"
Exception calling "DownloadFile" with "2" argument(s): "The request was aborted: Could not create SSL/TLS secure
channel."
At line:1 char:1
+ (New-Object Net.WebClient).DownloadFile('https://repo.maven.apache.or ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : WebException

Finished downloading "C:\Temp\vscode-xml-build-test\lsp4xml\.mvn\wrapper\maven-wrapper.jar"
Error: Could not find or load main class org.apache.maven.wrapper.MavenWrapperMain
  1. After manually downloading the maven-wrapper.jar I ran into another maven-related error so I decided to look over at https://github.com/angelozerr/lsp4xml where I found the hint to
  • Run ./mvnw clean verify (OSX, Linux) or mvnw.cmd clean verify (Windows)
    Doing that gave me another bunch of errors:
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for lsp4xml 0.0.3-SNAPSHOT:
[INFO]
[INFO] lsp4xml ............................................ SUCCESS [  0.109 s]
[INFO] org.eclipse.lsp4xml ................................ SUCCESS [ 20.310 s]
[INFO] lsp4xml-extensions ................................. SUCCESS [  0.016 s]
[INFO] org.eclipse.lsp4xml.extensions.emmet ............... FAILURE [ 25.260 s]
[INFO] org.eclipse.lsp4xml.extensions.web ................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  45.833 s
[INFO] Finished at: 2018-11-09T11:06:25+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project org.eclipse.lsp4xml.extensions.emmet: There are test failures.
  1. Ignoring these errors I headed back to vscode-xml and re-ran npm run build-server which then succeeded.

So apparently just some steps are missing in CONTRIBUTING.md:

  • cd ../lsp4xml
  • Run ./mvnw clean verify (OSX, Linux) or mvnw.cmd clean verify (Windows)
  • cd ../vscode-xml

Plus the advice to ignore certain warnings or errors 😃

@fbricon fbricon added bug Something isn't working build labels Nov 15, 2018
@fbricon fbricon added this to the 0.3.0 milestone Nov 15, 2018
@fbricon fbricon added the to do label Nov 15, 2018
@snjeza
Copy link
Contributor

snjeza commented Nov 16, 2018

  1. npm install ends with warnings

It isn't a problem.

  1. npm run build-server ends with an error:

mvnw.cmd can't download maven-wrapper.jar because some Windows versions have TLS 1.2 disabled.
See https://docs.microsoft.com/en-us/windows/desktop/SecAuthN/protocols-in-tls-ssl--schannel-ssp-
TLS 1.0 and TLS 1.1 are disabled on the https://repo.maven.apache.org/ server - https://www.ssllabs.com/ssltest/analyze.html?d=repo.maven.apache.org

The Java LS (https://github.com/eclipse/eclipse.jdt.ls) has the same issue.
The problem can't be reproduced on Linux.

We can do the following:

a) enable TLS 1.2 on Windows as described at https://success.outsystems.com/Support/Enterprise_Customers/Maintenance_and_Operations/(.NET)_Enable_SSL_Protocols_for_your_Integrations_-_TLS_1.1_and_TLS_1.2

or

b) add maven-wrapper.jar to the lsp4xml and eclipse.jdt.ls repository

  1. After manually downloading the maven-wrapper.jar

All the projects including org.eclipse.lsp4xml.extensions.emmet build on both, Linux and Windows.

@fbricon
Copy link
Collaborator

fbricon commented Nov 16, 2018

Thanks @snjeza. I've added the maven wrapper to the lsp4xml git repo. @ralfhandl please try again.

@fbricon
Copy link
Collaborator

fbricon commented Dec 5, 2018

@snjeza can you confirm this works now on windows?

@fbricon fbricon added in progress and removed to do labels Dec 5, 2018
@snjeza
Copy link
Contributor

snjeza commented Dec 5, 2018

@snjeza can you confirm this works now on windows?

I confirm. There is the same issue in vscode-java.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working build
Projects
None yet
Development

No branches or pull requests

3 participants