Skip to content

win11中文版,python3.8.8,不修改 build_graph.py代码,报以下错误: #3

@jchzend

Description

@jchzend

Traceback (most recent call last):
File "build_graph.py", line 129, in
handler.create_graphnodes()
File "build_graph.py", line 66, in create_graphnodes
company = self.load_data(self.company_path)
File "build_graph.py", line 52, in load_data
for line in f:
UnicodeDecodeError: 'gbk' codec can't decode byte 0xac in position 70: illegal multibyte sequence

将51行代码: with open(filepath, 'r') as f:
改为: with open(filepath, 'r', encoding="utf-8") as f:
后不报错,(我的环境缺py2neo,运行代码前先pip 安装py2neo==4.3.0;不写版本号,安装的是最新版本,最新的不行 ),后来看了一下代码发现要neo4j,然后我的java版本是1.8,太低,要Java11,然后我放弃啦

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions