hop icon indicating copy to clipboard operation
hop copied to clipboard

[Bug]: The HOP cli commands fail on Windows when HOP folder variables contain blanks

Open pfabrici opened this issue 11 months ago • 1 comments

Apache Hop version?

2.7

Java version?

OpenJDK 11

Operating system

Windows

What happened?

When one of the HOP_*FOLDER[S] environment variables contain a blank, the cli tools hop-encrypt.bat, hop-gui.bat, hop-import.bat etc. will fail on Windows. This occurs for example when the user wants to move the config or audit folder to his home folder which path contains a blank ( e.g. "c:\users\name surname" )

Reproduce:

  • create a folder, e.g. "c:\my hop folder"
  • set environment variable HOP_CONFIG_FOLDER=c:\my hop folder
  • start hop-gui.bat

Error message:


Java identified as "C:\work\tools\jdk-11.0.18+10\bin\java"

HOP_OPTIONS=-Xmx2048m -DHOP_AUDIT_FOLDER=C:\Users\Peter Fabricius\hop\audit -DHOP_CONFIG_FOLDER=c:\my hop folder -DHOP_PLATFORM_OS=Windows -DHOP_PLATFORM_RUNTIME=GUI -DHOP_AUTO_CREATE_CONFIG=Y

Command to start Hop will be:
"C:\work\tools\jdk-11.0.18+10\bin\java" -classpath lib\core\*;lib\beam\*;lib\swt\win64\* -Djava.library.path=lib\core;lib\beam -Xmx2048m -DHOP_AUDIT_FOLDER=C:\Users\Peter Fabricius\hop\audit -DHOP_CONFIG_FOLDER=c:\my hop folder -DHOP_PLATFORM_OS=Windows -DHOP_PLATFORM_RUNTIME=GUI -DHOP_AUTO_CREATE_CONFIG=Y org.apache.hop.ui.hopgui.HopGui

===[Starting Hop]=========================================================
Fehler: Hauptklasse Fabricius\hop\audit konnte nicht gefunden oder geladen werden
Ursache: java.lang.ClassNotFoundException: Fabricius\hop\audit
Drücken Sie eine beliebige Taste . .```




### Issue Priority

Priority: 3

### Issue Component

Component: CLI

pfabrici avatar Feb 29 '24 09:02 pfabrici