Debian Codegraph @

debian/patches/fix-settings-file-reading-method-in-sett.patch

raw
1 From: Gabriele Mongiano <[email protected]>
2 Date: Fri, 8 Nov 2024 15:22:15 +0100
3 Subject: Fix settings file reading method in Settings.py
4
5 - Updated method from `readfp` to `read_file` for compatibility with Python 3.
6 - No change in functionality; improves code compliance with current Python standards.
7
8 (this is upstream PR 350)
9 ---
10 afew/Settings.py | 2 +-
11 1 file changed, 1 insertion(+), 1 deletion(-)
12
13 --- a/afew/Settings.py
14 +++ b/afew/Settings.py
15 @@ -18,7 +18,7 @@
16 # preserve the capitalization of the keys.
17 settings.optionxform = str
18
19 -settings.readfp(open(os.path.join(os.path.dirname(__file__), 'defaults', 'afew.config')))
20 +settings.read_file(open(os.path.join(os.path.dirname(__file__), 'defaults', 'afew.config')))
21 settings.read(os.path.join(user_config_dir, 'config'))
22
23 # All the values for keys listed here are interpreted as ;-delimited lists