why can't download file from linux server into local window disk c:?

Thomas Rachel nutznetz-0c1b6768-bfa9-48d5-a470-7603bd3aa915 at spamschutz.glglgl.de
Mon Dec 8 14:36:35 EST 2014


Am 09.12.2014 09:14 schrieb pengsir:

> My vps ip is x.y.z.w ,i want to download /etc/passwd from linux server
> into my local window disk c: .

> localpath = 'c:'

[...]

>      with open(localpath, 'wb') as fl:
> PermissionError: [Errno 13] Permission denied: 'c:'

That's completely clear: you are not allowed to create a file named 
'c:'. You should replace it with a full path name, such as

localpath = 'c:\\passwd'

or such.


Thomas




More information about the Python-list mailing list