{"action":"created","issue":{"url":"https://api.github.com/repos/rime/librime/issues/96","repository_url":"https://api.github.com/repos/rime/librime","labels_url":"https://api.github.com/repos/rime/librime/issues/96/labels{/name}","comments_url":"https://api.github.com/repos/rime/librime/issues/96/comments","events_url":"https://api.github.com/repos/rime/librime/issues/96/events","html_url":"https://github.com/rime/librime/issues/96","id":173729712,"number":96,"title":"在特定条件下echo_translator会导致rime崩溃","user":{"login":"xiaoqun2016","id":16501929,"avatar_url":"https://avatars.githubusercontent.com/u/16501929?v=3","gravatar_id":"","url":"https://api.github.com/users/xiaoqun2016","html_url":"https://github.com/xiaoqun2016","followers_url":"https://api.github.com/users/xiaoqun2016/followers","following_url":"https://api.github.com/users/xiaoqun2016/following{/other_user}","gists_url":"https://api.github.com/users/xiaoqun2016/gists{/gist_id}","starred_url":"https://api.github.com/users/xiaoqun2016/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xiaoqun2016/subscriptions","organizations_url":"https://api.github.com/users/xiaoqun2016/orgs","repos_url":"https://api.github.com/users/xiaoqun2016/repos","events_url":"https://api.github.com/users/xiaoqun2016/events{/privacy}","received_events_url":"https://api.github.com/users/xiaoqun2016/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"lotem","id":151157,"avatar_url":"https://avatars.githubusercontent.com/u/151157?v=3","gravatar_id":"","url":"https://api.github.com/users/lotem","html_url":"https://github.com/lotem","followers_url":"https://api.github.com/users/lotem/followers","following_url":"https://api.github.com/users/lotem/following{/other_user}","gists_url":"https://api.github.com/users/lotem/gists{/gist_id}","starred_url":"https://api.github.com/users/lotem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lotem/subscriptions","organizations_url":"https://api.github.com/users/lotem/orgs","repos_url":"https://api.github.com/users/lotem/repos","events_url":"https://api.github.com/users/lotem/events{/privacy}","received_events_url":"https://api.github.com/users/lotem/received_events","type":"User","site_admin":false},"assignees":[{"login":"lotem","id":151157,"avatar_url":"https://avatars.githubusercontent.com/u/151157?v=3","gravatar_id":"","url":"https://api.github.com/users/lotem","html_url":"https://github.com/lotem","followers_url":"https://api.github.com/users/lotem/followers","following_url":"https://api.github.com/users/lotem/following{/other_user}","gists_url":"https://api.github.com/users/lotem/gists{/gist_id}","starred_url":"https://api.github.com/users/lotem/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lotem/subscriptions","organizations_url":"https://api.github.com/users/lotem/orgs","repos_url":"https://api.github.com/users/lotem/repos","events_url":"https://api.github.com/users/lotem/events{/privacy}","received_events_url":"https://api.github.com/users/lotem/received_events","type":"User","site_admin":false}],"milestone":null,"comments":3,"created_at":"2016-08-29T09:08:10Z","updated_at":"2016-08-29T13:16:02Z","closed_at":null,"body":"当  \r\n➀启用`echo_translator`  \r\n➁启用`simplifier`   （状态为1）\r\n➂候选唯一  \r\n\r\n这三个条件同时满足时，rime就会崩溃。  \r\n\r\n以下是从实际方案中提取的最小重现条件。  \r\n\r\n```yaml\r\n# xxx.schema.yaml\r\n\r\nschema:\r\n  schema_id: xxx\r\n  name: \"echo_问题\"\r\n  version: 1\r\n  author:\r\n  description: \r\n  dependencies:\r\n\r\n \r\nswitches:\r\n  - name: simplification\r\n    states: [关, 开]       #开关状态为0时不会崩溃\r\n    reset: 1      \r\n\r\nengine:\r\n  processors:\r\n#    - ascii_composer\r\n#    - recognizer\r\n#    - key_binder\r\n    - speller\r\n#    - punctuator\r\n#    - selector\r\n#    - navigator\r\n    - express_editor\r\n  segmentors:\r\n#    - ascii_segmentor\r\n#    - matcher\r\n    - abc_segmentor\r\n#    - punct_segmentor\r\n#    - fallback_segmentor\r\n  translators:\r\n    - echo_translator   #注释掉输入回显也不会崩溃\r\n    - table_translator\r\n  filters:\r\n    - simplifier      #\r\n\r\nspeller:\r\n  alphabet: \"zyxwvutsrqponmlkjihgfedcba\"\r\n\r\ntranslator:\r\n  dictionary: xxx\r\n  enable_completion: false\r\n  enable_sentence: false\r\n```\r\n\r\n词典  \r\n```yaml\r\n# xxx.dict.yaml\r\n\r\n---\r\nname: xxx\r\nversion: 1\r\nsort: original\r\ncolumns:\r\n  - text\r\n  - code\r\n...\r\n\r\n# table begins\r\n一\ta\r\n二\tb\r\n這\tb\r\n#复制词典时，请将词与编码间的空格转为tab\r\n```\r\n\r\n输入a时，候选唯一，会导致输入法崩溃。输入b或者其它空码时，都没有问题。将`simplification`开关置为0时也没有问题。     \r\n在Trime和Prime中都可以重现。"},"comment":{"url":"https://api.github.com/repos/rime/librime/issues/comments/243120501","html_url":"https://github.com/rime/librime/issues/96#issuecomment-243120501","issue_url":"https://api.github.com/repos/rime/librime/issues/96","id":243120501,"user":{"login":"jakwings","id":1451509,"avatar_url":"https://avatars.githubusercontent.com/u/1451509?v=3","gravatar_id":"","url":"https://api.github.com/users/jakwings","html_url":"https://github.com/jakwings","followers_url":"https://api.github.com/users/jakwings/followers","following_url":"https://api.github.com/users/jakwings/following{/other_user}","gists_url":"https://api.github.com/users/jakwings/gists{/gist_id}","starred_url":"https://api.github.com/users/jakwings/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jakwings/subscriptions","organizations_url":"https://api.github.com/users/jakwings/orgs","repos_url":"https://api.github.com/users/jakwings/repos","events_url":"https://api.github.com/users/jakwings/events{/privacy}","received_events_url":"https://api.github.com/users/jakwings/received_events","type":"User","site_admin":false},"created_at":"2016-08-29T13:16:01Z","updated_at":"2016-08-29T13:16:01Z","body":"源碼還不太熟悉。在候選項排序時，方案配置中 translator 的順序好像無太大關係，echo_translator 好像會自動清空自己的候選項。\r\n\r\n不開 simplifier，實測 echo_translator 放前、放後效果一樣，無候選項。\r\n開 simplifier，實測 echo_translator 放後面也會在唯一候選時出現 a。"}}
{"actor":{"display_login":"jakwings"}}