{"action":"created","issue":{"url":"https://api.github.com/repos/PyCQA/redbaron/issues/105","repository_url":"https://api.github.com/repos/PyCQA/redbaron","labels_url":"https://api.github.com/repos/PyCQA/redbaron/issues/105/labels{/name}","comments_url":"https://api.github.com/repos/PyCQA/redbaron/issues/105/comments","events_url":"https://api.github.com/repos/PyCQA/redbaron/issues/105/events","html_url":"https://github.com/PyCQA/redbaron/issues/105","id":157884263,"number":105,"title":"[Question, feature request?] After modifying the tree, how to print elements back ?","user":{"login":"vindarel","id":3721004,"avatar_url":"https://avatars.githubusercontent.com/u/3721004?v=3","gravatar_id":"","url":"https://api.github.com/users/vindarel","html_url":"https://github.com/vindarel","followers_url":"https://api.github.com/users/vindarel/followers","following_url":"https://api.github.com/users/vindarel/following{/other_user}","gists_url":"https://api.github.com/users/vindarel/gists{/gist_id}","starred_url":"https://api.github.com/users/vindarel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vindarel/subscriptions","organizations_url":"https://api.github.com/users/vindarel/orgs","repos_url":"https://api.github.com/users/vindarel/repos","events_url":"https://api.github.com/users/vindarel/events{/privacy}","received_events_url":"https://api.github.com/users/vindarel/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-06-01T11:30:04Z","updated_at":"2016-06-07T12:26:25Z","closed_at":null,"body":"Hi,\r\nSo I'm using RedBaron to help me edit code, that's pretty exciting. My difficulty now is to re-write the tree I modified, sometimes just nodes. It doesn't seem to be a method on redbaron objects for that.\r\n\r\nFor instance, let's take the code\r\n\r\n    def foo(self, key=[], second): pass\r\n\r\nI parse it, I sort the arguments and I want to print them back. It's easy with simple arguments that have no value, but with \"key=[]\" I don't find its textual representation, I find its \"first_formatting\" that is a python list.\r\n\r\n    {'first_formatting': [], 'type': 'def_argument', 'target': {'type': 'name', 'value': 'key'}, 'value': {'type': 'name', 'value': 'val'}, 'second_formatting': []}\r\n\r\nSo I could treat this \"[]\" as a special case and return the string \"[]\", but how will I handle a list with something in it, or a crazy argument with nested lists ?\r\n\r\nHope I was clear;\r\nthanks !"},"comment":{"url":"https://api.github.com/repos/PyCQA/redbaron/issues/comments/224264636","html_url":"https://github.com/PyCQA/redbaron/issues/105#issuecomment-224264636","issue_url":"https://api.github.com/repos/PyCQA/redbaron/issues/105","id":224264636,"user":{"login":"vindarel","id":3721004,"avatar_url":"https://avatars.githubusercontent.com/u/3721004?v=3","gravatar_id":"","url":"https://api.github.com/users/vindarel","html_url":"https://github.com/vindarel","followers_url":"https://api.github.com/users/vindarel/followers","following_url":"https://api.github.com/users/vindarel/following{/other_user}","gists_url":"https://api.github.com/users/vindarel/gists{/gist_id}","starred_url":"https://api.github.com/users/vindarel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vindarel/subscriptions","organizations_url":"https://api.github.com/users/vindarel/orgs","repos_url":"https://api.github.com/users/vindarel/repos","events_url":"https://api.github.com/users/vindarel/events{/privacy}","received_events_url":"https://api.github.com/users/vindarel/received_events","type":"User","site_admin":false},"created_at":"2016-06-07T12:26:25Z","updated_at":"2016-06-07T12:26:25Z","body":"FYI, that's [what I wanted to do](https://gitlab.com/vindarel/redbaron4emacs). Already much handy for me. Will try to build upon it."}}
{"actor":{"display_login":"vindarel"}}