Python path as a string

Python path as a string

filename has a method called abspath that returns an object with the absolute path. You can cast that to a string.

...
folder_path = path(~/folder/)
filename = path.joinpath(foo)
f = sftp.open(str(filename), r)

Python path as a string

Leave a Reply

Your email address will not be published. Required fields are marked *