reycn/china-drug-trials-crawler

Something error with the crawler, please help!

Closed this issue · 1 comments

fieri commented

Start running...
Handling: No.1 / CTR20211247
Searching: CTR20211247
Fetching 763b0fefe81b45629690ec79ab012059
main.py:26: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead.
df = df.append(dictionary, ignore_index=True)
Traceback (most recent call last):
File "main.py", line 38, in
asyncio.get_event_loop().run_until_complete(run())
File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "main.py", line 27, in run
df = sort_df(df)
File "/mnt/c/Users/focus/Desktop/china-drug-trials-crawler-master/lib/df.py", line 23, in sort_df
df = df[head]
File "/home/focus/.local/lib/python3.8/site-packages/pandas/core/frame.py", line 3511, in getitem
indexer = self.columns._get_indexer_strict(key, "columns")[1]
File "/home/focus/.local/lib/python3.8/site-packages/pandas/core/indexes/base.py", line 5782, in _get_indexer_strict
self._raise_if_missing(keyarr, indexer, axis_name)
File "/home/focus/.local/lib/python3.8/site-packages/pandas/core/indexes/base.py", line 5842, in _raise_if_missing
raise KeyError(f"None of [{key}] are in the [{axis_name}]")
KeyError: "None of [Index(['ID', '实验数据ID', '实验数据获取时间', '登记号1', '试验状态', '申请人联系人', '首次公示信息日期',\n '申请人名称', '登记号2', '相关登记号', '药物名称', '药物类型', '临床申请受理号', '适应症', '试验专业题目',\n '试验通俗题目', '试验方案编号', '方案最新版本号', '版本日期', '方案是否为联合用药', '申请人名称', '联系人姓名',\n '联系人座机', '联系人手机号', '联系人Email', '联系人邮政地址', '联系人邮编', '试验目的', '试验分类',\n '试验分期', '设计类型', '随机化', '盲法', '试验范围', '受试者年龄', '受试者性别', '健康受试者',\n '受试者入选标准', '受试者排除标准', '试验药', '对照药', '主要终点指标及评价时间', '次要终点指标及评价时间',\n '数据安全监查委员会DMC', '为受试者购买试验伤害保险', '主要研究者信息', '各参加机构信息', '伦理委员会信息', '试验状态',\n '试验人数', '受试者招募及试验完成日期', ' 临床试验结果摘要'],\n dtype='object')] are in the [columns]"

reycn commented

网站可能更新;抱歉不作技术支持。
An update of the original website might cause this issue. Sorry for not providing any technical help.