Message315148
The documentation for ConfigParser.items(section, raw=False, vars=None) says the following:
> Changed in version 3.2: Items present in vars no longer appear in the result. The previous behaviour mixed actual parser options with variables provided for interpolation.
https://docs.python.org/3/library/configparser.html#configparser.ConfigParser.items
However, this does not seem to be the case. The keys from vars are present in the output. Tested on 3.6.5.
This example shows the issue:
import configparser
config = configparser.ConfigParser()
config.add_section('example')
config.set('example', 'name', 'timster %(suffix)s')
data = config.items('example', vars={'suffix': 'user'})
print(data)
Expected output:
[('name', 'timster user')]
Actual output:
[('name', 'timster user'), ('suffix', 'user')] |
|
Date |
User |
Action |
Args |
2018-04-09 20:04:26 | timster | set | recipients:
+ timster |
2018-04-09 20:04:26 | timster | set | messageid: <1523304266.46.0.682650639539.issue33251@psf.upfronthosting.co.za> |
2018-04-09 20:04:26 | timster | link | issue33251 messages |
2018-04-09 20:04:26 | timster | create | |
|