summaryrefslogtreecommitdiff
path: root/compat.py
diff options
context:
space:
mode:
authorAnthon van der Neut <anthon@mnt.org>2017-08-09 14:17:45 +0200
committerAnthon van der Neut <anthon@mnt.org>2017-08-09 14:17:45 +0200
commit291b2e6757d22061acb8ee9a581dc04e3a791847 (patch)
tree3f805ec3551ba2e0baa5ce21b1ebadfd3136ccc5 /compat.py
parentb3b5301e1b0a21d81a2ec1501df9ef92abac5ce2 (diff)
downloadruamel.yaml-291b2e6757d22061acb8ee9a581dc04e3a791847.tar.gz
fix for indenting non-indented sequence after comment
- solves several expected to fail and fixes two incorrect tests (test_09-Sammy Sosa & test_before_nested_seq_from_scratch) - still swaps foo and bar on test_issue_25_03
Diffstat (limited to 'compat.py')
-rw-r--r--compat.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/compat.py b/compat.py
index 6b05d5a..5eddc59 100644
--- a/compat.py
+++ b/compat.py
@@ -125,6 +125,13 @@ DBG_NODE = 4
_debug = None # type: Union[None, int]
+if 'RUAMELDEBUG' in os.environ:
+ _debugx = os.environ.get('RUAMELDEBUG')
+ if _debugx is None:
+ _debug = 0
+ else:
+ _debug = int(_debugx)
+
if bool(_debug):
class ObjectCounter(object):