Traceback most recent call last File Dwampwwwinvest批量获取财务数据py line 9 in module stocks = row1 for row in csvreaderf1 File Dwampwwwinvest批量获取财务数据py line 9 in listcomp stocks = row1 for row in cs
This error occurs because the list comprehension is trying to access an index that does not exist in the list.
In this specific case, it seems that the CSV file being read does not have any data in it or is not in the expected format, causing the list comprehension to fail when trying to access the second column (index 1) of each row.
To fix this error, you should check the CSV file and ensure that it has data in the expected format before trying to read it using the csv.reader function.
原文地址: https://www.cveoy.top/t/topic/bdWX 著作权归作者所有。请勿转载和采集!