{"action":"created","issue":{"url":"https://api.github.com/repos/mypaint/mypaint/issues/196","labels_url":"https://api.github.com/repos/mypaint/mypaint/issues/196/labels{/name}","comments_url":"https://api.github.com/repos/mypaint/mypaint/issues/196/comments","events_url":"https://api.github.com/repos/mypaint/mypaint/issues/196/events","html_url":"https://github.com/mypaint/mypaint/pull/196","id":57266062,"number":196,"title":"fix for ora files without a default selected layer","user":{"login":"vurentjie","id":639806,"avatar_url":"https://avatars.githubusercontent.com/u/639806?v=3","gravatar_id":"","url":"https://api.github.com/users/vurentjie","html_url":"https://github.com/vurentjie","followers_url":"https://api.github.com/users/vurentjie/followers","following_url":"https://api.github.com/users/vurentjie/following{/other_user}","gists_url":"https://api.github.com/users/vurentjie/gists{/gist_id}","starred_url":"https://api.github.com/users/vurentjie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vurentjie/subscriptions","organizations_url":"https://api.github.com/users/vurentjie/orgs","repos_url":"https://api.github.com/users/vurentjie/repos","events_url":"https://api.github.com/users/vurentjie/events{/privacy}","received_events_url":"https://api.github.com/users/vurentjie/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-02-11T01:43:57Z","updated_at":"2015-02-11T02:14:09Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mypaint/mypaint/pulls/196","html_url":"https://github.com/mypaint/mypaint/pull/196","diff_url":"https://github.com/mypaint/mypaint/pull/196.diff","patch_url":"https://github.com/mypaint/mypaint/pull/196.patch"},"body":"i picked up an issue if i save ora files in krita, there is no default selected layer,\r\nthen when re-opening in mypaint and trying to select the layer it breaks, \r\n\r\nTraceback (most recent call last):\r\n  File \"/usr/local/share/mypaint/gui/layerswindow.py\", line 469, in _view_button_press_cb\r\n    docmodel.select_layer(path=click_layerpath)\r\n  File \"/usr/local/share/mypaint/lib/document.py\", line 380, in select_layer\r\n    self.do(command.SelectLayer(self, path=sel_path))\r\n  File \"/usr/local/share/mypaint/lib/command.py\", line 715, in __init__\r\n    self.prev_path = layers.canonpath(path=layers.get_current_path())\r\n  File \"/usr/local/share/mypaint/lib/layer.py\", line 2642, in canonpath\r\n    (path,))\r\nValueError: path=() is root: must be descendent\r\n"},"comment":{"url":"https://api.github.com/repos/mypaint/mypaint/issues/comments/73823935","html_url":"https://github.com/mypaint/mypaint/pull/196#issuecomment-73823935","issue_url":"https://api.github.com/repos/mypaint/mypaint/issues/196","id":73823935,"user":{"login":"achadwick","id":61299,"avatar_url":"https://avatars.githubusercontent.com/u/61299?v=3","gravatar_id":"","url":"https://api.github.com/users/achadwick","html_url":"https://github.com/achadwick","followers_url":"https://api.github.com/users/achadwick/followers","following_url":"https://api.github.com/users/achadwick/following{/other_user}","gists_url":"https://api.github.com/users/achadwick/gists{/gist_id}","starred_url":"https://api.github.com/users/achadwick/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/achadwick/subscriptions","organizations_url":"https://api.github.com/users/achadwick/orgs","repos_url":"https://api.github.com/users/achadwick/repos","events_url":"https://api.github.com/users/achadwick/events{/privacy}","received_events_url":"https://api.github.com/users/achadwick/received_events","type":"User","site_admin":false},"created_at":"2015-02-11T02:14:09Z","updated_at":"2015-02-11T02:14:09Z","body":"I'm not sure we should address this in the undo stack entry, since MyPaint needs a layer always selected, i.e. current for painting. If necessary, we should force it upon loading the file non-undoably - and I thought that's what the code does atm."}}