{"action":"created","issue":{"url":"https://api.github.com/repos/bpython/bpython/issues/610","repository_url":"https://api.github.com/repos/bpython/bpython","labels_url":"https://api.github.com/repos/bpython/bpython/issues/610/labels{/name}","comments_url":"https://api.github.com/repos/bpython/bpython/issues/610/comments","events_url":"https://api.github.com/repos/bpython/bpython/issues/610/events","html_url":"https://github.com/bpython/bpython/issues/610","id":148746457,"number":610,"title":"REPL crashes while typing","user":{"login":"eshyong","id":2742232,"avatar_url":"https://avatars.githubusercontent.com/u/2742232?v=3","gravatar_id":"","url":"https://api.github.com/users/eshyong","html_url":"https://github.com/eshyong","followers_url":"https://api.github.com/users/eshyong/followers","following_url":"https://api.github.com/users/eshyong/following{/other_user}","gists_url":"https://api.github.com/users/eshyong/gists{/gist_id}","starred_url":"https://api.github.com/users/eshyong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eshyong/subscriptions","organizations_url":"https://api.github.com/users/eshyong/orgs","repos_url":"https://api.github.com/users/eshyong/repos","events_url":"https://api.github.com/users/eshyong/events{/privacy}","received_events_url":"https://api.github.com/users/eshyong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-04-15T19:21:00Z","updated_at":"2016-04-18T05:04:44Z","closed_at":null,"body":"I was using bpython today to work on some kaggle competition problems when it suddenly crashed in the middle of typing. Here's a stack trace:\r\n\r\n```\r\n>>> num_men_survived = np.sum(data_array[men_only_stats, 1]. <- exception occurs here\r\nTraceback (most recent call last):\r\n  File \"/usr/local/bin/bpython\", line 9, in <module>\r\n    load_entry_point('bpython==0.14.2', 'console_scripts', 'bpython')()\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsies.py\", line 79, in main\r\n    interactive=(not exec_args))\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsies.py\", line 177, in mainloop\r\n    process_event(e)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsies.py\", line 135, in process_event\r\n    repl.process_event(e)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsiesfrontend/repl.py\", line 488, in process_event\r\n    return self.process_key_event(e)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsiesfrontend/repl.py\", line 629, in process_key_event\r\n    self.add_normal_character(e)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsiesfrontend/repl.py\", line 848, in add_normal_character\r\n    self.cursor_offset += 1\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsiesfrontend/repl.py\", line 1345, in _set_cursor_offset\r\n    self.update_completion()\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/curtsiesfrontend/repl.py\", line 878, in update_completion\r\n    self.list_win_visible = BpythonRepl.complete(self, tab)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/repl.py\", line 608, in complete\r\n    self.current_line, matches, completer)\r\n  File \"/usr/local/lib/python3.4/site-packages/bpython/repl.py\", line 278, in update\r\n    self.orig_cursor_offset, self.orig_line)\r\nTypeError: 'NoneType' object is not iterable\r\n```\r\n\r\nThis is bpython version 0.14.2 running on Python 3.4.2, on OSX El Capitan 10.11.3.\r\n\r\nUnfortunately, that's the only context I currently have. If anyone has suggestions on where to start digging, I'd be happy to report back once I've gathered more info!"},"comment":{"url":"https://api.github.com/repos/bpython/bpython/issues/comments/211202691","html_url":"https://github.com/bpython/bpython/issues/610#issuecomment-211202691","issue_url":"https://api.github.com/repos/bpython/bpython/issues/610","id":211202691,"user":{"login":"eshyong","id":2742232,"avatar_url":"https://avatars.githubusercontent.com/u/2742232?v=3","gravatar_id":"","url":"https://api.github.com/users/eshyong","html_url":"https://github.com/eshyong","followers_url":"https://api.github.com/users/eshyong/followers","following_url":"https://api.github.com/users/eshyong/following{/other_user}","gists_url":"https://api.github.com/users/eshyong/gists{/gist_id}","starred_url":"https://api.github.com/users/eshyong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eshyong/subscriptions","organizations_url":"https://api.github.com/users/eshyong/orgs","repos_url":"https://api.github.com/users/eshyong/repos","events_url":"https://api.github.com/users/eshyong/events{/privacy}","received_events_url":"https://api.github.com/users/eshyong/received_events","type":"User","site_admin":false},"created_at":"2016-04-18T05:04:44Z","updated_at":"2016-04-18T05:04:44Z","body":"Gotcha, will update bpython. I'll let you know if I still see it after that. Thanks!"}}