在Windows上使用带有Python 3.4的ImageScanner模块

时间:2016-01-14 13:26:52

标签: python image-scanner

我在imagescanner module之后的Windows上安装了steps。我已经连接到wifi上的扫描仪。当我尝试这段代码时:

from imagescanner import ImageScanner
iscanner = ImageScanner()
scanners = iscanner.list_scanners()
print(scanners[0])

发生错误消息:

C:\Python3.4\python.exe C:/Users/PB/PycharmProjects/ImageScanner/deneme.py
Traceback (most recent call last):
File "C:/Users/PB/PycharmProjects/ImageScanner/deneme.py", line 4, in    <module>
from imagescanner import ImageScanner
File "C:\Python3.4\lib\site-packages\imagescanner-0.9-py3.4.egg\imagescanner\__init__.py", line 2, in <module>
from imagescanner.core._imagescanner import ImageScanner
File "C:\Python3.4\lib\site-packages\imagescanner-0.9-py3.4.egg\imagescanner\core\_imagescanner.py", line 61
except Exception, exc:
                ^
SyntaxError: invalid syntax

Process finished with exit code 1

1 个答案:

答案 0 :(得分:0)

据我所知,imagescanner与Python 3不兼容。

您可以尝试修复它。 SyntaxError引用异常的旧语法(&#34;类,变量&#34;变为&#34;类变量&#34;在较新版本中)。但我不确定你能找到的其他问题。