Bug #602
uncaught exception if crontab with empty lines exists before creating first cron
| Status: | Closed | Start date: | ||
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | % Done: | 0% |
||
| Category: | - | |||
| Target version: | 0.25.0 | |||
| Affected Puppet version: | 0.25.4 | Branch: | ||
| Keywords: | ||||
| Votes: | 0 |
Description
The first time you add a cron definition, if root’s crontab has some blank lines, puppet throws an exception: err: Got an uncaught exception of type ArgumentError: Field ‘command’ is required and doesn’t adds the cron.
I think it can be solved changing the regular expression at line 23 of puppet/provider/cron/crontab.rb from:
text_line :blank, :match => %r{^\s+}
to:
text_line :blank, :match => %r{^\s*$}
History
Updated by Luke Kanies almost 5 years ago
- Status changed from 1 to 2
Updated by Luke Kanies almost 5 years ago
- Status changed from 2 to Closed
- 7 set to fixed
Fixed in r2440