改这一行for line in open(name,encoding=‘utf-8’).readlines():
再运行出现:F:\Programs\Mdx\Converter
λ MdxConverter.py 1.mdx 2.txt 4.html
Traceback (most recent call last):
File “F:\Programs\Mdx\Converter\MdxConverter-master\MdxConverter.py”, line 3, in
import mdict_query
ModuleNotFoundError: No module named ‘mdict_query’
F:\Programs\Mdx\Converter
λ MdxConverter.py 1.mdx 2.txt 4.html
Traceback (most recent call last):
File “F:\Programs\Mdx\Converter\MdxConverter-master\MdxConverter.py”, line 3, in
import mdict_query
File “F:\Programs\Mdx\Converter\MdxConverter-master\mdict_query.py”, line 13, in
from .readmdict import MDD, MDX
ImportError: attempted relative import with no known parent package