Skip to content

Commit

Permalink
Fix diff mode not effective (#761)
Browse files Browse the repository at this point in the history
  • Loading branch information
yumiguan authored May 31, 2023
1 parent 003f60b commit 766d1c6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions lyrebird/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from packaging import version
import jinja2
from lyrebird import log as nlog
from lyrebird.mock import context

logger = nlog.get_logger()

Expand Down Expand Up @@ -73,6 +74,11 @@ def override_config_field(self, update_conf: dict):
if forbidden_modify_fields:
raise ConfigException(f'Config field cannot be modified: {forbidden_modify_fields}')

# TODO handle bug diff mode not effect
# Remove bellow code next version
if 'mock.mode' in update_conf:
context.application.is_diff_mode = update_conf['mock.mode']

logger.debug(f'Need update config fields: {update_conf}')
self.config.update(update_conf)
logger.debug(f'Update done. config: {self.config}')
Expand Down
2 changes: 1 addition & 1 deletion lyrebird/version.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
IVERSION = (2, 14, 0)
IVERSION = (2, 14, 1)
VERSION = ".".join(str(i) for i in IVERSION)
LYREBIRD = "Lyrebird " + VERSION

0 comments on commit 766d1c6

Please sign in to comment.