{"action":"closed","issue":{"url":"https://api.github.com/repos/sherpa/sherpa/issues/393","repository_url":"https://api.github.com/repos/sherpa/sherpa","labels_url":"https://api.github.com/repos/sherpa/sherpa/issues/393/labels{/name}","comments_url":"https://api.github.com/repos/sherpa/sherpa/issues/393/comments","events_url":"https://api.github.com/repos/sherpa/sherpa/issues/393/events","html_url":"https://github.com/sherpa/sherpa/issues/393","id":255617224,"number":393,"title":"set_xlog/ylog fail with Python 3","user":{"login":"DougBurke","id":224638,"avatar_url":"https://avatars3.githubusercontent.com/u/224638?v=4","gravatar_id":"","url":"https://api.github.com/users/DougBurke","html_url":"https://github.com/DougBurke","followers_url":"https://api.github.com/users/DougBurke/followers","following_url":"https://api.github.com/users/DougBurke/following{/other_user}","gists_url":"https://api.github.com/users/DougBurke/gists{/gist_id}","starred_url":"https://api.github.com/users/DougBurke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DougBurke/subscriptions","organizations_url":"https://api.github.com/users/DougBurke/orgs","repos_url":"https://api.github.com/users/DougBurke/repos","events_url":"https://api.github.com/users/DougBurke/events{/privacy}","received_events_url":"https://api.github.com/users/DougBurke/received_events","type":"User","site_admin":false},"labels":[{"id":452275942,"url":"https://api.github.com/repos/sherpa/sherpa/labels/dep:python3","name":"dep:python3","color":"fef2c0","default":false},{"id":208812641,"url":"https://api.github.com/repos/sherpa/sherpa/labels/priority:high","name":"priority:high","color":"fad8c7","default":false},{"id":208809664,"url":"https://api.github.com/repos/sherpa/sherpa/labels/type:bug","name":"type:bug","color":"e11d21","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-09-06T14:08:43Z","updated_at":"2017-11-29T19:05:22Z","closed_at":"2017-11-29T19:05:22Z","author_association":"CONTRIBUTOR","body":"The `sherpa.astro.ui.set_xlog` and `set_ylog` commands fail with Python 3.5 but not with Python 2.7. The following is using the CIAO 4.9 version of Sherpa but I expect the same behavior with the master branch. I have not audited the code to see if there are other functions which fail in a similar manner - such as `set_xlinear` - but I expect them to.\r\n\r\nA) Python 2.7\r\n\r\n```\r\nsherpa-1> get_data_plot_prefs()['xlog']\r\n          False\r\nsherpa-2> get_data_plot_prefs()['ylog']\r\n          False\r\nsherpa-3> set_xlog()\r\nsherpa-4> set_ylog()\r\nsherpa-5> get_data_plot_prefs()['xlog']\r\n          True\r\nsherpa-6> get_data_plot_prefs()['ylog']\r\n          True\r\nsherpa-7> sys.version\r\n          '2.7.11 (default, Apr 27 2016, 13:22:12) \\n[GCC 4.4.7 20120313 (Red Hat 4.4.7-16)]'\r\nsherpa-8> sherpa._version.get_versions()\r\n           {'full': '10736c4d70fcd3e7d686670e1594103a1819098e', 'version': 'ciao4.9'}\r\n```\r\n\r\nB) Python 3.5\r\n\r\n```\r\nsherpa-1> get_data_plot_prefs()['xlog']\r\n          False\r\nsherpa-2> get_data_plot_prefs()['ylog']\r\n          False\r\nsherpa-3> set_xlog()\r\nTypeError: 'dict_keys' object is not subscriptable\r\nsherpa-4> set_ylog()\r\nTypeError: 'dict_keys' object is not subscriptable\r\nsherpa-5> get_data_plot_prefs()['xlog']\r\n          False\r\nsherpa-6> get_data_plot_prefs()['ylog']\r\n          False\r\nsherpa-7> sys.version\r\n          '3.5.1 (default, Apr  6 2016, 12:14:18) \\n[GCC 4.4.7 20120313 (Red Hat 4.4.7-16)]'\r\nsherpa-8> sherpa._version.get_versions()\r\n          {'full': '10736c4d70fcd3e7d686670e1594103a1819098e', 'version': 'ciao4.9'}\r\n```\r\n\r\n"}}
{"actor":{"display_login":"olaurino"}}