Skip to content
Snippets Groups Projects
Commit beac9556 authored by alekum's avatar alekum
Browse files

Merge branch 'repr_recursion_fix'

Conflicts:
	.gitignore
parents 9b064db1 30348230
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -118,7 +118,11 @@ class Path(object):
parent = parent.node_list
 
if isinstance(parent, NodeList):
pos = parent.index(node.node_list if isinstance(node, ProxyList) else node)
if isinstance(node, ProxyList):
item = node.node_list
else:
item = node
pos = parent.index(item)
return pos
 
if isinstance(node, NodeList):
Loading
Loading
@@ -1643,9 +1647,9 @@ class LineProxyList(ProxyList):
{"type": "endl", "formatting": [], "value": "\n", "indent": " "})
 
def _synchronise(self):
log("Before synchronise, self.data = '%s' + '%s'", self.first_blank_lines, self.data)
log("Before synchronise, self.data = '%s' + '%s'", self.first_blank_lines, self.node_list)
super(LineProxyList, self)._synchronise()
log("After synchronise, self.data = '%s' + '%s'", self.first_blank_lines, self.data)
log("After synchronise, self.data = '%s' + '%s'", self.first_blank_lines, self.node_list)
 
def _build_inner_list(self, node_list):
result = []
Loading
Loading
Loading
Loading
@@ -8,8 +8,8 @@ import pytest
import redbaron
from redbaron import RedBaron
 
redbaron.DEBUG = True
# (alekum): switch off debug mode, to reproduce a bug with __repr__ implicit recursion
redbaron.DEBUG = False
 
def assert_with_indent(left, right):
# Replace is not strictly necessary but shows indents
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment