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

Sync error: Remote dir might not exist or you don't have permission on this path! #43

Open
cfsilence opened this issue Apr 4, 2017 · 5 comments

Comments

@cfsilence
Copy link

When using SFTP to sync a project, everything works fine except for my build.gradle file in the project root which throws the error:

11:22 AM Sync error: Remote dir /home/pi/Projects/pi-spark might not exist or you don't have permission on this path!

Any ideas?

@cfsilence
Copy link
Author

cfsilence commented Apr 4, 2017

The fix for this, for the SFTPFileSynchronizer, is to wrap the contents of the for loop on line 129 with a check to make sure there is a directory to create (if there isn't, then the file is in the root of the project).

Here's the changed for loop:

https://gist.github.com/cfsilence/5e700a89fe8646a20fe3f490ddc20d0c

@cfsilence
Copy link
Author

I've confirmed my fix in a local version, please update the plugin (and the other protocols) so others can avoid this nasty bug too!

@fioan89
Copy link
Owner

fioan89 commented Apr 5, 2017

I'll have to do a proper debug but it might be that the real issue is in Utils.splitPath which doesnt return a proper list of paths to create.

@cfsilence
Copy link
Author

Cool. My workaround is getting me by far now, but at least the issue is on your radar. Thanks for developing this plugin, it's pretty great.

@shanmugara
Copy link

I just hit the same bug. I will try your workaround @cfsilence. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants