因此,我正在抓紧fanfiction.net以获得故事数据,并获得了字典。我将字典转储到我的json文件中,并确保它是有效的,然后当我尝试将JSON文件导入MongoDB时,它作为JSON输入的意外结尾返回。香港专业教育学院谷歌四处搜寻,没有人真的有这个答案。我将在尝试导入的数据的整个文件上附加一个链接,并且有多个需要导入的文件。还附带了我必须导入的原始JSON:
{
"id": "4391921",
"canon": "Supernatural",
"author_id": 3240,
"title": "Light of Day, Dark of Moon",
"lang": "English",
"published": 1215966904,
"chapter_names": [
"Light of Day, Dark of Moon"
],
"genres": [
"Drama",
"Family"
],
"canon_type": [
"TV Shows"
],
"rated": "Fiction T",
"num_words": 3441,
"num_reviews": 38,
"num_favs": 79,
"num_follows": 11,
"status": "Complete"
},
{
"id": "4391909",
"canon": "Supernatural",
"author_id": 3240,
"title": "A Year and a Day",
"lang": "English",
"published": 1215966494,
"chapter_names": [
"A Year and a Day"
],
"genres": [
"Drama",
"Hurt/Comfort"
],
"canon_type": [
"TV Shows"
],
"rated": "Fiction M",
"num_words": 32830,
"num_reviews": 10,
"num_favs": 46,
"num_follows": 3,
"status": "Complete"
},
https://github.com/ethanbreck/fanfiction-api-scraper/tree/master/data/user_write
答案 0 :(得分:0)
使用Compass导入时发生相同的错误。请改用Studio 3T !!那对我有用。