gawel/irc3 — pull request #20 by singingwolfboy (2014-08-26 19:45:13+00:00)
Title: Use extended interpolation for parsing config file

See https://docs.python.org/3/library/configparser.html#interpolation-of-values.

I made this pull request because I noticed that when I wanted to customize the output location of the log file, I got funky errors on Python 3. Here's the relevant section of my configuration file:

```ini
[irc3.plugins.logger]
handler = irc3.plugins.logger.s3_handler
bucket = my-irc-log-bucket
filename = irclogs/{channel}-{date:%Y-%m-%d}.log
```

Which resulted in this error on Python 3:

```
Traceback (most recent call last):
File "/app/.heroku/python/bin/irc3", line 9, in
load_entry_point('irc3==0.5.2.dev0', 'console_scripts', 'irc3')()
File "/app/.heroku/python/lib/python3.4/site-packages/irc3/__init__.py", line 432, in run
cfg = utils.parse_config(*args[''])
File "/app/.heroku/python/lib/python3.4/site-packages/irc3/utils.py", line 142, in parse_config
for k, v in config.items(s):
File "/app/.heroku/python/lib/python3.4/configparser.py", line 836, in items
return [(option, value_getter(option)) for option in d.keys()]
File "/app/.heroku/python/lib/python3.4/configparser.py", line 836, in
return [(option, value_getter(option)) for option in d.keys()]
File "/app/.heroku/python/lib/python3.4/configparser.py", line 833, in
section, option, d[option], d)
File "/app/.heroku/python/lib/python3.4/configparser.py", line 374, in before_get
self._interpolate_some(parser, option, L, value, section, defaults, 1)
File "/app/.heroku/python/lib/python3.4/configparser.py", line 423, in _interpolate_some
"found: %r" % (rest,))
configparser.InterpolationSyntaxError: '%' must be followed by '%' or '(', found: '%Y-%m-%d}.log'
```