Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit a3381a5

Browse filesBrowse files
committed
Merge pull request #305 from plotly/to-string-bug
Dataframes have a `to_string` method!
2 parents 3311acb + 1e807d1 commit a3381a5
Copy full SHA for a3381a5

File tree

Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-2
lines changed

‎plotly/graph_objs/graph_objs.py

Copy file name to clipboardExpand all lines: plotly/graph_objs/graph_objs.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -700,13 +700,13 @@ def to_string(self, level=0, indent=4, eol='\n',
700700
eol=eol,
701701
indent=' ' * indent * (level+1),
702702
key=key)
703-
try:
703+
if isinstance(self[key], PlotlyBase):
704704
string += self[key].to_string(level=level+1,
705705
indent=indent,
706706
eol=eol,
707707
pretty=pretty,
708708
max_chars=max_chars)
709-
except AttributeError:
709+
else:
710710
if pretty: # curtail representation if too many chars
711711
max_len = (max_chars -
712712
indent*(level + 1) -

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.