fabriceb/GCalCron2 — Issue #1: Crashes when processing a job that's scheduled for the past
Author: ndbroadbent
Created: 2012-01-08 12:46:50+00:00
State: open

First, thanks so much for creating this! You have done an awesome job, and it works almost perfectly! However, I managed to find a small bug:

* Set a calendar event for *8:30 pm*, with the line:

```bash
-10: DISPLAY=:0 notify-send "Computer will be shutting down in 10 minutes"
```

* Run `python gcalcron2.py` at *8:25 pm*.

The script crashes like this:

Traceback (most recent call last):
File "/home/ndbroadbent/src/python/GCalCron2/gcalcron2.py", line 297, in
g.sync_gcal_to_cron()
File "/home/ndbroadbent/src/python/GCalCron2/gcalcron2.py", line 246, in sync_gcal_to_cron
job_id = re.compile('job (\d+) at').search(output).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

Thanks again for your sharing your work!
I can't wait to use this for my home automation schedule, as well as Wake-on-Lan & shutdown for my PCs.