{"action":"created","issue":{"url":"https://api.github.com/repos/pydata/pandas/issues/10087","labels_url":"https://api.github.com/repos/pydata/pandas/issues/10087/labels{/name}","comments_url":"https://api.github.com/repos/pydata/pandas/issues/10087/comments","events_url":"https://api.github.com/repos/pydata/pandas/issues/10087/events","html_url":"https://github.com/pydata/pandas/issues/10087","id":74525823,"number":10087,"title":"BUG: categorical doesn't handle display.width of None in Python 3 ","user":{"login":"rosnfeld","id":5356340,"avatar_url":"https://avatars.githubusercontent.com/u/5356340?v=3","gravatar_id":"","url":"https://api.github.com/users/rosnfeld","html_url":"https://github.com/rosnfeld","followers_url":"https://api.github.com/users/rosnfeld/followers","following_url":"https://api.github.com/users/rosnfeld/following{/other_user}","gists_url":"https://api.github.com/users/rosnfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/rosnfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rosnfeld/subscriptions","organizations_url":"https://api.github.com/users/rosnfeld/orgs","repos_url":"https://api.github.com/users/rosnfeld/repos","events_url":"https://api.github.com/users/rosnfeld/events{/privacy}","received_events_url":"https://api.github.com/users/rosnfeld/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pydata/pandas/labels/2/3%20Compat","name":"2/3 Compat","color":"c7eef8"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Bug","name":"Bug","color":"e10c02"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Difficulty%20Novice","name":"Difficulty Novice","color":"fbca04"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Effort%20Low","name":"Effort Low","color":"006b75"},{"url":"https://api.github.com/repos/pydata/pandas/labels/Output-Formatting","name":"Output-Formatting","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/pydata/pandas/milestones/32","html_url":"https://github.com/pydata/pandas/milestones/Next%20Major%20Release","labels_url":"https://api.github.com/repos/pydata/pandas/milestones/32/labels","id":933188,"number":32,"title":"Next Major Release","description":"after 0.16.1 of course","creator":{"login":"jreback","id":953992,"avatar_url":"https://avatars.githubusercontent.com/u/953992?v=3","gravatar_id":"","url":"https://api.github.com/users/jreback","html_url":"https://github.com/jreback","followers_url":"https://api.github.com/users/jreback/followers","following_url":"https://api.github.com/users/jreback/following{/other_user}","gists_url":"https://api.github.com/users/jreback/gists{/gist_id}","starred_url":"https://api.github.com/users/jreback/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jreback/subscriptions","organizations_url":"https://api.github.com/users/jreback/orgs","repos_url":"https://api.github.com/users/jreback/repos","events_url":"https://api.github.com/users/jreback/events{/privacy}","received_events_url":"https://api.github.com/users/jreback/received_events","type":"User","site_admin":false},"open_issues":805,"closed_issues":39,"state":"open","created_at":"2015-01-13T10:53:19Z","updated_at":"2015-05-09T16:20:05Z","due_on":"2015-06-30T04:00:00Z","closed_at":null},"comments":2,"created_at":"2015-05-08T23:13:05Z","updated_at":"2015-05-09T16:42:04Z","closed_at":null,"body":"Categorical Series have a special repr that looks at display.width, which can be None if following the Options and Settings docs. Unlike Python 2, in Python 3 an integer vs None comparison throws an exception.\r\n\r\n(on current master, and has been true for several releases now)\r\n\r\n```python\r\nPython 3.4.0 (default, Apr 11 2014, 13:05:11) \r\n[GCC 4.8.2] on linux\r\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\r\n>>> import pandas as pd\r\n>>> pd.core.config.set_option('display.width', None)\r\n>>> import numpy as np\r\n>>> x = pd.Series(np.random.randn(100))\r\n>>> pd.cut(x, 10)\r\nTraceback (most recent call last):\r\n  File \"<stdin>\", line 1, in <module>\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/base.py\", line 67, in __repr__\r\n    return str(self)\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/base.py\", line 46, in __str__\r\n    return self.__unicode__()\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/series.py\", line 897, in __unicode__\r\n    max_rows=max_rows)\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/series.py\", line 962, in to_string\r\n    name=name, max_rows=max_rows)\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/series.py\", line 992, in _get_repr\r\n    result = formatter.to_string()\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/format.py\", line 222, in to_string\r\n    footer = self._get_footer()\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/format.py\", line 196, in _get_footer\r\n    level_info = self.tr_series.values._repr_categories_info()\r\n  File \"/home/andrew/git/pandas-rosnfeld-py3/pandas/core/categorical.py\", line 1323, in _repr_categories_info\r\n    if max_width != 0 and cur_col_len + sep_len + len(val) > max_width:\r\nTypeError: unorderable types: int() > NoneType()\r\n```"},"comment":{"url":"https://api.github.com/repos/pydata/pandas/issues/comments/100515234","html_url":"https://github.com/pydata/pandas/issues/10087#issuecomment-100515234","issue_url":"https://api.github.com/repos/pydata/pandas/issues/10087","id":100515234,"user":{"login":"rosnfeld","id":5356340,"avatar_url":"https://avatars.githubusercontent.com/u/5356340?v=3","gravatar_id":"","url":"https://api.github.com/users/rosnfeld","html_url":"https://github.com/rosnfeld","followers_url":"https://api.github.com/users/rosnfeld/followers","following_url":"https://api.github.com/users/rosnfeld/following{/other_user}","gists_url":"https://api.github.com/users/rosnfeld/gists{/gist_id}","starred_url":"https://api.github.com/users/rosnfeld/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rosnfeld/subscriptions","organizations_url":"https://api.github.com/users/rosnfeld/orgs","repos_url":"https://api.github.com/users/rosnfeld/repos","events_url":"https://api.github.com/users/rosnfeld/events{/privacy}","received_events_url":"https://api.github.com/users/rosnfeld/received_events","type":"User","site_admin":false},"created_at":"2015-05-09T16:42:04Z","updated_at":"2015-05-09T16:42:04Z","body":"Sure, I'll try and get to it soon."}}