Comment #4 on issue 1666 by pekka.klarck: Use Python pprint module inside Log keywords
http://code.google.com/p/robotframework/issues/detail?id=1666

It's obviously true that using Log Dictionary/List is problematic if you don't know the type of the object you are logging. As you pointed out, they don't handle nested structures that well either.

The problem that pprint adds extra quotes around strings still remains. We cannot simple remove the quotes because pprint also escapes possible internal quotes and we needed to unescape them.

Some possibilities we could consider instead of using pprint in Log by default:

1) Make pprint optional by adding new argument controlling it (e.g. `pretty=False`). We already have similar `repr` argument (issue 1584).

2) Use pprint automatically when `repr=True`.

3) Add new keyword for this usage. A benefit would be that it could accept same `indent`, `width`, and `depth` arguments as pprint itself. Not sure how often they would be useful, though.


--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--

--- You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to robotframework-commit+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to