Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Spaces cause failures when using put and use_sudo #955
sftp.py (line 109):
def mkdir(self, path, use_sudo): from fabric.api import sudo, hide if use_sudo: with hide('everything'): sudo('mkdir %s' % path)
The issue here is that if
def mkdir(self, path, use_sudo): from fabric.api import sudo, hide if use_sudo: with hide('everything'): sudo('mkdir "%s"' % path)
Now it works OK. Untested but solved my issue, may cause problems for others.
referenced this issue
Jan 22, 2014
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.