randomdrake / nasa-apod-desktop

Automatically downloads and sets the NASA picture of the day (APOD) as your desktop in Ubuntu.
Apache License 2.0
148 stars 62 forks source link

Video posts to APoD fail miserably. #7

Closed Pythor closed 12 years ago

Pythor commented 12 years ago

I understand that a video isn't an image, and can't normally be set as a desktop background. However, on days when APoD showcases a video, the script fails with a python error, where it should fail somewhat gracefully with a message to the user.

Today's (8/13/12) page is an example: http://apod.nasa.gov/apod/ap120813.html

The script yeilds this error when run:

Traceback (most recent call last): File "./apod.py", line 172, in filename = get_image(site_contents) File "./apod.py", line 94, in get_image if 'http' in reg.group(1): AttributeError: 'NoneType' object has no attribute 'group'