{"action":"created","issue":{"url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/61","repository_url":"https://api.github.com/repos/Calysto/matlab_kernel","labels_url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/61/labels{/name}","comments_url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/61/comments","events_url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/61/events","html_url":"https://github.com/Calysto/matlab_kernel/pull/61","id":172573995,"number":61,"title":"BUGFIX: Matlab completion now works with structs","user":{"login":"brunobeltran","id":1475390,"avatar_url":"https://avatars.githubusercontent.com/u/1475390?v=3","gravatar_id":"","url":"https://api.github.com/users/brunobeltran","html_url":"https://github.com/brunobeltran","followers_url":"https://api.github.com/users/brunobeltran/followers","following_url":"https://api.github.com/users/brunobeltran/following{/other_user}","gists_url":"https://api.github.com/users/brunobeltran/gists{/gist_id}","starred_url":"https://api.github.com/users/brunobeltran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brunobeltran/subscriptions","organizations_url":"https://api.github.com/users/brunobeltran/orgs","repos_url":"https://api.github.com/users/brunobeltran/repos","events_url":"https://api.github.com/users/brunobeltran/events{/privacy}","received_events_url":"https://api.github.com/users/brunobeltran/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-08-22T22:53:36Z","updated_at":"2016-08-23T13:03:54Z","closed_at":"2016-08-23T12:25:50Z","pull_request":{"url":"https://api.github.com/repos/Calysto/matlab_kernel/pulls/61","html_url":"https://github.com/Calysto/matlab_kernel/pull/61","diff_url":"https://github.com/Calysto/matlab_kernel/pull/61.diff","patch_url":"https://github.com/Calysto/matlab_kernel/pull/61.patch"},"body":"This patch should fix #52.\r\n\r\nThe problem was that the MetaKernel framework expects `do_matlab_complete('some_struct.long')` to return `'some_struct.long_fieldname'`, but mtFindAllTabCompletions returns `'long_fieldname'` instead.\r\n\r\nThis was fixed by asking do_matlab_complete.m to manually re-add the prefix. Matlab's isstruct function is used to make sure that the prefix that's being added back is actually a struct, instead of trying to use regular expressions to find the prefix, since that prevents corner cases where filenames that are valid Matlab identifiers are confused for structs that don't exist.\r\n\r\nIn practice, this means autocompletion will work correctly on `test.p[TAB]` whether `test.py` is a script in the current directory, a field `py` of the struct `test`, or both.\r\n\r\nAlso corrected some tab/spaces inconsistencies in the relevant files, and did some more name mangling to make sure that `evalin(base, ...` doesn't cause any problems if the user has a variable named e.g. `completions_output`. "},"comment":{"url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/comments/241723057","html_url":"https://github.com/Calysto/matlab_kernel/pull/61#issuecomment-241723057","issue_url":"https://api.github.com/repos/Calysto/matlab_kernel/issues/61","id":241723057,"user":{"login":"Foucl","id":3074124,"avatar_url":"https://avatars.githubusercontent.com/u/3074124?v=3","gravatar_id":"","url":"https://api.github.com/users/Foucl","html_url":"https://github.com/Foucl","followers_url":"https://api.github.com/users/Foucl/followers","following_url":"https://api.github.com/users/Foucl/following{/other_user}","gists_url":"https://api.github.com/users/Foucl/gists{/gist_id}","starred_url":"https://api.github.com/users/Foucl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Foucl/subscriptions","organizations_url":"https://api.github.com/users/Foucl/orgs","repos_url":"https://api.github.com/users/Foucl/repos","events_url":"https://api.github.com/users/Foucl/events{/privacy}","received_events_url":"https://api.github.com/users/Foucl/received_events","type":"User","site_admin":false},"created_at":"2016-08-23T13:03:54Z","updated_at":"2016-08-23T13:03:54Z","body":"thank you so much! (even though I know feel guilty for making you feel guilty ;-))"}}
{"actor":{"display_login":"Foucl"}}