这是我的代码, 可以正常运行.import os
imp = open('import.txt','w')
pro = open('prototype.txt','r')
nextline =0
for eachline in pro:
newline = eachline.split()
print (newline)
if '00440245' in eachline:
imp.write(newline[0]+',')
nextline = 1
if nextline==1 and not '00440245' in eachline:
imp.write(newline[0]+' '+newline[1]+' '+newline[2]+','+newline[3][0:2]+','+newline[3]+',LUT'+'\n')
nextline=0
pro.close()
imp.close()
环境变量已经改好了,
下面是使用prinstaller之后的报错
C:\>pyinstaller -f -w c:\prototype.py
Traceback (most recent call last):
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\pyinstaller.py",
line 14, in <module>
from PyInstaller.__main__ import run
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\PyInstaller\__ma
in__.py", line 21, in <module>
import PyInstaller.building.build_main
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\PyInstaller\buil
ding\build_main.py", line 32, in <module>
from ..depend import bindepend
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\PyInstaller\depe
nd\bindepend.py", line 38, in <module>
from ..utils.win32.winmanifest import RT_MANIFEST
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\PyInstaller\util
s\win32\winmanifest.py", line 97, in <module>
from PyInstaller.utils.win32 import winresource
File "C:\Python34\pyinstaller\pyinstaller-pyinstaller-8477437\PyInstaller\util
s\win32\winresource.py", line 20, in <module>
import pywintypes
ImportError: No module named 'pywintypes'
苦恼ing |