log: Make the log_exception support a per instance logger.
Previously, the logger to use was always passed to the decorator
directly, thus it must be known at class-definition time. Now, the
decorator supports not being passed a logger, in which case it will
assume the decorated function is a method on an object that has a "log"
attribute.
These convenience functions allow for accessing configuration values
either allowing them to be unset (and return None) or mandatory (and
throw an appropriate exception). By default, ConfigParser throws an
exception with a less appropriate exception.
config: Allow specifying configuration values with no default.
By specifying a default of None, a config value will have no default. We
could just leave out the value alltogether, but this way even values
without a default are "documented" (this will be extended later).
Since instances of this class are really actions, not handlers that can
handle multiple actions, the name Action seems more appropriate (note
that the class itself could be seen as a handler, just not its
instances).
config: Restructure config loading to allow defaults.
Handlers now load their own configuration files, so they can pass
default configuration values. This also allows for more complicated
configuration loading in handlers by overriding the load_config method.
config: Check action config filenames more strictly.
Previously, the filename was split at the first dot, now it can only
contain just one dot. Also fix the error message to actually include the
faulty filename.