-
Notifications
You must be signed in to change notification settings - Fork 92
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
Regression: webDAV-functionality broken on Windows #228
Comments
@jbachelet / @tobiaslohr Could you please look into this as you did / merged the change that caused the issue? Was this just an oversight or was there a specific reasoning behind using path.join here? |
@KennethRobbeFrucon Agree! This is a bug and from what I can see, there was not a specific reason |
@jordanebachelet any input you can give, before we revert this particular change? |
@tobiaslohr Apologize for the issue, I was only able to test it on mac, where it works fine. |
@jbachelet Thanks. Do you have bandwidth to do this? |
@jbachelet @tobiaslohr will https://nodejs.org/api/url.html#url_new_url_input_base work instead?
|
Provided a fix in #233, please review and approve |
#228 fix regression, properly concatenate URL path
The following line was updated in version 2.7.0, but this breaks all webDAV-functionalities on Windows:
sfcc-ci/lib/webdav.js
Line 26 in 613bf74
It uses path.join to join two path segments. However, path.join() is meant to interact with file paths, while this is an URI. This results in a path with backslashes on Windows, which isn't a valid URI. This can be seen by running the unit tests on Windows. All tests for lib/webdav.js fail due to these types of errors:
AssertionError: expected '\\on\\demandware.servlet\\webdav\\Sites\\cartridges\\mycode.zip' to equal '/on/demandware.servlet/webdav/Sites/cartridges/mycode.zip'
In the past, the path was just concatenated:
sfcc-ci/lib/webdav.js
Line 26 in 074cc74
The text was updated successfully, but these errors were encountered: