Closed emkaser closed 3 weeks ago
Solution: rename any NARA_Risk Level columns to NARA_Risk_Level before selecting that column to ensure it is always consistent.
@emkaser, I can't replicate this error on risk_update.py. Line 70 must be prior to a major code edit, because it lands in a docstring. I couldn't find a place where it would go wrong, since it doesn't use the NARA columns from the full risk csv but instead goes back to the NARA CSV. Do you have any more information on where that is happening?
@amhanson9 This was my mistake, I wrote down the wrong script name! I was encountering the issue on line 70 in format_list.py. It was the same issue as above, where the column name was failing to match on "NARA_Risk Level." Apologies for the confusion.
These scripts are breaking when pandas cannot find a column name pulled from older risk CSVs. The newer CSVs created by risk_update.py have the column name 'NARA_Risk_Level'. May need to include error handling to accommodate both variations.
Line 70 in risk_update.py Line 232 and 239 in collection_summary.py