I feel like this should cause issues for non-sudo invocation as well - have you tested that out? Either way, agree quoting is probably useful here; we quote a few other similar places IIRC so there's likely precedent.
Not sure why I said non sudo invocations would cause issues here, clearly the non sudo situation is handled natively by SFTP. Derp.
Wrote up an integration test proving this & applied the above fix. We may want to make this even more robust in the future for things like tilde escaping, but this suffices for now. Will merge into 1.7.x and 1.8.x momentarily.
sftp.py (line 109):
The issue here is that if
use_sudo=Truethen mkdir will break if path contains spaces. I changed it to:
Now it works OK. Untested but solved my issue, may cause problems for others.
The text was updated successfully, but these errors were encountered: