There's an assertion in StringTree.py.__set(), assert self.content != str(content), which often triggers. Not sure what the idea behind the assertion was, disable it.
monkeytype run jw-acc.py --log-level debug db import --format mdb-json-dir dbs
monkeytype list-modules | grep ^jw | while read m; do
monkeytype apply $m
done
As opposed to the C++ variant, StringTree.value() doesn't take a path argument, but only returns the value of the node it's called on. Change this. Returns None if the path is not found.
StringTree.__getitem__() returned the node, now return its value child instead. That's nicer and closer to the expected behaviour, as it supports StringTree usage as a key-value store for configuration or so. It breaks the existing API, but I think I have fixed the only pace where it was used: jw-grammar/grammar.py.
Add support for adding children of type StringTree. If a StringTree argument is passed to .add(), this should do the right thing. It makes use of the newly added .__add_children() method and involves quite a bit of hairy case distinctions.
parse() and read() up to present automatically set the root content of a StringTree object to "root". This can now be optionally defined by the "root_content" keyword argument.
syntax, i.e. non-assignments, without equal sign. Half-baked, but still better than before. Also support some more Python 3, i.e. dict.items() instead of iteritems()