From 4b624f4ea00c012d99c3436b8b944d8945f35949 Mon Sep 17 00:00:00 2001 From: Miranda Mundt Date: Tue, 21 Nov 2023 10:14:24 -0700 Subject: [PATCH] Apply black --- pyomo/common/config.py | 4 +++- pyomo/common/formatting.py | 3 +-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pyomo/common/config.py b/pyomo/common/config.py index b79f2cfad25..d85df9f8286 100644 --- a/pyomo/common/config.py +++ b/pyomo/common/config.py @@ -1102,7 +1102,9 @@ def _value2string(prefix, value, obj): try: _data = value._data if value is obj else value if getattr(builtins, _data.__class__.__name__, None) is not None: - _str += _dump(_data, default_flow_style=True, allow_unicode=True).rstrip() + _str += _dump( + _data, default_flow_style=True, allow_unicode=True + ).rstrip() if _str.endswith("..."): _str = _str[:-3].rstrip() else: diff --git a/pyomo/common/formatting.py b/pyomo/common/formatting.py index f17fa247ad0..f76d16880df 100644 --- a/pyomo/common/formatting.py +++ b/pyomo/common/formatting.py @@ -257,8 +257,7 @@ def writelines(self, sequence): r'|(?:\[\s*[A-Za-z0-9\.]+\s*\] +)' # [PASS]|[FAIL]|[ OK ] ) _verbatim_line_start = re.compile( - r'(\| )' - r'|(\+((-{3,})|(={3,}))\+)' # line blocks # grid table + r'(\| )' r'|(\+((-{3,})|(={3,}))\+)' # line blocks # grid table ) _verbatim_line = re.compile( r'(={3,}[ =]+)' # simple tables, ======== sections