{"action":"created","issue":{"url":"https://api.github.com/repos/scopatz/xonsh/issues/61","labels_url":"https://api.github.com/repos/scopatz/xonsh/issues/61/labels{/name}","comments_url":"https://api.github.com/repos/scopatz/xonsh/issues/61/comments","events_url":"https://api.github.com/repos/scopatz/xonsh/issues/61/events","html_url":"https://github.com/scopatz/xonsh/issues/61","id":62065874,"number":61,"title":"Crash on parsing list nested in dict","user":{"login":"mbollmann","id":11348502,"avatar_url":"https://avatars.githubusercontent.com/u/11348502?v=3","gravatar_id":"","url":"https://api.github.com/users/mbollmann","html_url":"https://github.com/mbollmann","followers_url":"https://api.github.com/users/mbollmann/followers","following_url":"https://api.github.com/users/mbollmann/following{/other_user}","gists_url":"https://api.github.com/users/mbollmann/gists{/gist_id}","starred_url":"https://api.github.com/users/mbollmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbollmann/subscriptions","organizations_url":"https://api.github.com/users/mbollmann/orgs","repos_url":"https://api.github.com/users/mbollmann/repos","events_url":"https://api.github.com/users/mbollmann/events{/privacy}","received_events_url":"https://api.github.com/users/mbollmann/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/scopatz/xonsh/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/scopatz/xonsh/milestones/1","html_url":"https://github.com/scopatz/xonsh/milestones/v0.2","labels_url":"https://api.github.com/repos/scopatz/xonsh/milestones/1/labels","id":1013181,"number":1,"title":"v0.2","description":"","creator":{"login":"scopatz","id":320553,"avatar_url":"https://avatars.githubusercontent.com/u/320553?v=3","gravatar_id":"","url":"https://api.github.com/users/scopatz","html_url":"https://github.com/scopatz","followers_url":"https://api.github.com/users/scopatz/followers","following_url":"https://api.github.com/users/scopatz/following{/other_user}","gists_url":"https://api.github.com/users/scopatz/gists{/gist_id}","starred_url":"https://api.github.com/users/scopatz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scopatz/subscriptions","organizations_url":"https://api.github.com/users/scopatz/orgs","repos_url":"https://api.github.com/users/scopatz/repos","events_url":"https://api.github.com/users/scopatz/events{/privacy}","received_events_url":"https://api.github.com/users/scopatz/received_events","type":"User","site_admin":false},"open_issues":26,"closed_issues":79,"state":"open","created_at":"2015-03-09T18:29:10Z","updated_at":"2015-03-21T18:38:10Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2015-03-16T12:34:15Z","updated_at":"2015-03-21T18:38:10Z","closed_at":"2015-03-21T18:38:10Z","body":"When parsing a line containing a dict that has a list (or tuple) as a value, xonsh crashes.\r\n\r\n```\r\nbollmann@underberg ~/repositories/xonsh master >>> {'foo': ['a', 'b']}\r\nTraceback (most recent call last):\r\n  File \"/usr/local/bin/xonsh\", line 12, in <module>\r\n    exec(compile(open(__file__).read(), __file__, 'exec'))\r\n  File \"/home/bollmann/repositories/xonsh/scripts/xonsh\", line 3, in <module>\r\n    main()\r\n  File \"/home/bollmann/repositories/xonsh/xonsh/main.py\", line 25, in main\r\n    shell.cmdloop()\r\n  File \"/home/bollmann/repositories/xonsh/xonsh/shell.py\", line 152, in cmdloop\r\n    super(Shell, self).cmdloop(intro=intro)\r\n  File \"/usr/lib/python3.4/cmd.py\", line 138, in cmdloop\r\n    stop = self.onecmd(line)\r\n  File \"/usr/lib/python3.4/cmd.py\", line 211, in onecmd\r\n    return self.default(line)\r\n  File \"/home/bollmann/repositories/xonsh/xonsh/shell.py\", line 105, in default\r\n    code = self.push(line)\r\n  File \"/home/bollmann/repositories/xonsh/xonsh/shell.py\", line 126, in push\r\n    locs=self.ctx)\r\n  File \"/home/bollmann/repositories/xonsh/xonsh/execer.py\", line 87, in compile\r\n    code = compile(tree, self.filename, mode)\r\nValueError: Dict doesn't have the same number of keys as values\r\nbollmann@underberg ~/repositories/xonsh (master) $ \r\n```\r\n\r\nOther nested structures seem to work fine. Putting the list in a variable first and then constructing the dict also works fine.\r\n\r\n```\r\nbollmann@underberg ~/repositories/xonsh master >>> x = ['a', 'b']\r\nbollmann@underberg ~/repositories/xonsh master >>> {'foo': x}\r\n{'foo': ['a', 'b']}\r\nbollmann@underberg ~/repositories/xonsh master >>> {'a': {'b': 'c', 'd': 'e'}}\r\n{'a': {'b': 'c', 'd': 'e'}}\r\nbollmann@underberg ~/repositories/xonsh master >>> [{'a': 'b', 'c': 'd'}]\r\n[{'a': 'b', 'c': 'd'}]\r\nbollmann@underberg ~/repositories/xonsh master >>> [{'a': 'b'}, {'c': 'd'}]\r\n[{'a': 'b'}, {'c': 'd'}]\r\nbollmann@underberg ~/repositories/xonsh master >>> {'a': {'b': 'c', 'd': 'e'}}\r\n{'a': {'b': 'c', 'd': 'e'}}\r\n```"},"comment":{"url":"https://api.github.com/repos/scopatz/xonsh/issues/comments/84415969","html_url":"https://github.com/scopatz/xonsh/issues/61#issuecomment-84415969","issue_url":"https://api.github.com/repos/scopatz/xonsh/issues/61","id":84415969,"user":{"login":"mbollmann","id":11348502,"avatar_url":"https://avatars.githubusercontent.com/u/11348502?v=3","gravatar_id":"","url":"https://api.github.com/users/mbollmann","html_url":"https://github.com/mbollmann","followers_url":"https://api.github.com/users/mbollmann/followers","following_url":"https://api.github.com/users/mbollmann/following{/other_user}","gists_url":"https://api.github.com/users/mbollmann/gists{/gist_id}","starred_url":"https://api.github.com/users/mbollmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbollmann/subscriptions","organizations_url":"https://api.github.com/users/mbollmann/orgs","repos_url":"https://api.github.com/users/mbollmann/repos","events_url":"https://api.github.com/users/mbollmann/events{/privacy}","received_events_url":"https://api.github.com/users/mbollmann/received_events","type":"User","site_admin":false},"created_at":"2015-03-21T18:38:09Z","updated_at":"2015-03-21T18:38:09Z","body":"Nevermind, just saw there is a separate issue for that problem.\r\n\r\nThe specific bug described here is fixed. Closing."}}