-
All of a sudden today, the code I cribbed from the examples for comets is failing on the
code. I'm getting an error: ParserError: Error tokenizing data. C error: Expected 12 fields in line 488, saw 13 I'm also seeing warnings from mpc.py: but until today this hadn't been happening. Is anything seeing this happen, and if so, could you provide insight? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hi The MPC comet file seems to be corrupted from time to time. It takes a few days before they correct the issues. I found another reliable source for the orbital elements, which are updated regularly: For some comets I make a direct query to MPC ephemeris service to obtain the orbital element line.
I think it should also be possible to send a list of comets to the query, since the ephmeris service accepts multiple comets each in a new line. Clear skies |
Beta Was this translation helpful? Give feedback.
-
Thanks for sharing the warning, I hadn't heard about the Pandas plan for this breaking change. I've adjusted Skyfield's code and will try to get a release out soon! Here's the commit I just made: 05760c6 |
Beta Was this translation helpful? Give feedback.
-
I found the problem. The latest data files has commas in the last column in some rows: e.g., " 98, 1083". Ideally the code should filter them out somehow when it goes to create the CSV to load into pandas. |
Beta Was this translation helpful? Give feedback.
I found the problem. The latest data files has commas in the last column in some rows: e.g., " 98, 1083".
Remove the commas from the data file and the code is happy.
Ideally the code should filter them out somehow when it goes to create the CSV to load into pandas.