radical-cybertools / radical.saga

A Light-Weight Access Layer for Distributed Computing Infrastructure and Reference Implementation of the SAGA Python Language Bindings.
http://radical-cybertools.github.io/saga-python/
Other
83 stars 34 forks source link

SFTP Remote - Local copy doesn't work #272

Closed oleweidner closed 10 years ago

oleweidner commented 10 years ago
d = saga.filesystem.Directory('sftp://stampede.tacc.utexas.edu/')
d.copy(remote_file, local_file)

# remote file: /home1/00988/tg802352/mysim//task-0/stdout
# local file: file://localhost//Users/oweidner/Work/Projects/BigJob/EMILIO/task-0.out

results in

BadParameter: copy from /home1/00988/tg802352/mysim//task-0/stdout to file://localhost//Users/oweidner/Work/Projects/BigJob/EMILIO/task-0.out is not supported (/tmp/saga-pilot2/lib/python2.7/site-packages/saga_python-0.9.12-py2.7.egg/saga/adaptors/shell/shell_file.py +448 (copy)  :  % (src, tgt)))
andre-merzky commented 10 years ago

This doesn't seem to use devel (line numbers don't match up). I am not saying that this is not a real error, but I touched that part of code recently, so please confirm with devel.

Thanks, Andre.

oleweidner commented 10 years ago

It turns out that the double-"/" in /home1/00988/tg802352/mysim//task-0/stdout causes the problem. I have added an issue code snippet for reproduction:

https://github.com/saga-project/saga-python/blob/devel/tests/issues/issue_272.py

andre-merzky commented 10 years ago

Ah, cool, thanks - that will make for an easy fix (path normalization...)

andre-merzky commented 10 years ago

This is now fixed in the devel branch of radical.utils -- URL path should always be normalized once the utils are released again.

oleweidner commented 10 years ago

This works now. However, I had to merge radical.utils devel -> master and make and push a new release. Not an ideal workflow for small fixes like this...

andre-merzky commented 10 years ago

What is the alternative?

A.