mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Merge pull request #6852 from tk0miya/6848_config_overrides
Fix #6848: config.py shouldn't pop extensions from overrides
This commit is contained in:
commit
b6f205e975
1
CHANGES
1
CHANGES
@ -76,6 +76,7 @@ Bugs fixed
|
||||
* #6824: HTML search: If a search term is partially matched in the title and
|
||||
fully matched in a text paragraph on the same page, the search does not
|
||||
include this match.
|
||||
* #6848: config.py shouldn't pop extensions from overrides
|
||||
|
||||
Testing
|
||||
--------
|
||||
|
@ -177,16 +177,16 @@ class Config:
|
||||
else:
|
||||
config, overrides = args[:2]
|
||||
|
||||
self.overrides = overrides
|
||||
self.overrides = dict(overrides)
|
||||
self.values = Config.config_values.copy()
|
||||
self._raw_config = config
|
||||
self.setup = config.get('setup', None) # type: Callable
|
||||
|
||||
if 'extensions' in overrides:
|
||||
if isinstance(overrides['extensions'], str):
|
||||
config['extensions'] = overrides.pop('extensions').split(',')
|
||||
if 'extensions' in self.overrides:
|
||||
if isinstance(self.overrides['extensions'], str):
|
||||
config['extensions'] = self.overrides.pop('extensions').split(',')
|
||||
else:
|
||||
config['extensions'] = overrides.pop('extensions')
|
||||
config['extensions'] = self.overrides.pop('extensions')
|
||||
self.extensions = config.get('extensions', []) # type: List[str]
|
||||
|
||||
@classmethod
|
||||
|
Loading…
Reference in New Issue
Block a user