ftplib import error

Discussions on extending SharpCap using the built in Python scripting functionality
Post Reply
smgvbest
Posts: 6
Joined: Mon May 29, 2017 6:11 pm

ftplib import error

#1

Post by smgvbest »

when I try to import ftplib i get the following error in ssl.py
>>> import ftplib
File "C:\Program Files (x86)\SharpCap 3.0\PythonLib.zip\ssl.py", line 1
# Wrapper module for _ssl, providing some additional facilities

^
SyntaxError: unexpected token '»'

>>>

looking at ssl.py in the zip archieve thier are indeed 3 hex characters in front of the #
this is the first line in hex.
00000000h: EF BB BF 23 20 57 72 61 70 70 65 72 20 6D 6F 64 ; # Wrapper mod
the EF BB BF are the problem characters. I removed them in a hex editor to fix it.

I don't know if this was a problem on my install or if everyone has it???
pgn
Posts: 17
Joined: Wed Mar 08, 2017 9:46 am

Re: ftplib import error

#2

Post by pgn »

Same for me.
User avatar
admin
Site Admin
Posts: 13177
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: ftplib import error

#3

Post by admin »

Hi,

thanks for this - looks like that file contained a UTF8 signature header as the first few bytes for some reason. Have removed it and the next version will contain the fix.

cheers,

Robin
smgvbest
Posts: 6
Joined: Mon May 29, 2017 6:11 pm

Re: ftplib import error

#4

Post by smgvbest »

Cool, thank you.


removed a comment as I see you replied elsewhere
Post Reply