question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Minor Planet Center “CometEls.txt” has a broken row with asterisks for the year

See original GitHub issue

I am refering to comet_neowise_chart.py I am using Python 3.9.1 and line 34: comet = sun + mpc.comet_orbit(row, ts, GM_SUN) fails because the perihelion year is a string.

May I suggest adding the following fix, it just converts the perihelion_year from a string to an int.

    comets = (comets.sort_values('reference')
              .groupby('designation', as_index=False).last()
              .set_index('designation', drop=False))
    comets['perihelion_year'] = comets['perihelion_year'].astype(int)

Once this is done everything is Ok. By the way there are no issues using Python 3.9 so I think you can update this dot point Supports Python 2.6–2.7 and Python 3.3–3.5. in Skyfield to Supports Python 2.6–2.7 and Python 3.3–3.9.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
brandon-rhodescommented, Dec 17, 2020

Thank you for following up on that, on behalf of the rest of us! I’m glad to hear it’s not a permanent change to the file format.

1reaction
ajpmacleancommented, Dec 17, 2020

I just received notification that this is fixed. I also verified it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

MPO Canopus and PhotoRed Reference Guide
The file contains elements in the same format as the CometEls.txt file that can be downloaded from the MPCORB page on the Minor...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found