From 95beaaa7e629f1bfecb36a9da2ff2d0842b714be Mon Sep 17 00:00:00 2001 From: g1879 Date: Fri, 4 Dec 2020 18:04:15 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8RawConfigParser=E4=BB=A3=E6=9B=BFConfi?= =?UTF-8?q?gParser=EF=BC=8C=E9=81=BF=E5=85=8D=E9=85=8D=E7=BD=AE=E7=9A=84co?= =?UTF-8?q?okies=E4=B8=AD=E7=9A=84=E7=89=B9=E6=AE=8A=E5=AD=97=E7=AC=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DrissionPage/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DrissionPage/config.py b/DrissionPage/config.py index 3d331c1..b7ea249 100644 --- a/DrissionPage/config.py +++ b/DrissionPage/config.py @@ -5,7 +5,7 @@ @Contact : g1879@qq.com @File : config.py """ -from configparser import ConfigParser, NoSectionError, NoOptionError +from configparser import RawConfigParser, NoSectionError, NoOptionError from http.cookiejar import Cookie from pathlib import Path from typing import Any, Union @@ -23,7 +23,7 @@ class OptionsManager(object): :param path: ini文件的路径,默认读取模块文件夹下的 """ self.ini_path = path or str(Path(__file__).parent / 'configs.ini') - self._conf = ConfigParser() + self._conf = RawConfigParser() self._conf.read(self.ini_path, encoding='utf-8') self._paths = None