Skip to content

Terminal hangs or prints repetitive characters when using Japanese IME #14349

Closed

Description


Important

📌 plan of record: move the console tsf implementation to the Terminal codebase


Windows Terminal version

1.15.2875.0

Windows build number

10.0.22621.755

Other Software

WSL2 Ubuntu 22.04.1 LTS (version 2204.1.23.0)

Steps to reproduce

Input some Japanese characters using Microsoft IME at the right side edge of the terminal window.

Expected Behavior

Characters are converted correctly.

Actual Behavior

Sometimes repetitive characters are inputted, sometimes the terminal hangs or crashes.

2022-11-06-12-46-12.mp4
2022-11-06-13-03-10.mp4

Activity

  1. added
    Issue-BugIt either shouldn't be doing this or needs an investigation.
    Needs-TriageIt's a new issue that the core contributor team needs to triage at the next triage meeting
    on Nov 6, 2022
  2. hnakamur commented on Nov 6, 2022

    @hnakamur
    Author

    The same problem occurs with PowerShell version 5.1.22621.608.

    2022-11-06-13-35-41.mp4
  3. lhecker commented on Nov 7, 2022

    @lhecker
    Member

    Input some Japanese characters using Microsoft IME at the right side edge of the terminal window.

    Just to be sure: You're saying this never happens if you are not at the right side edge? Because if that's true, then that would narrow down the issue quite a lot and make fixing it much easier.

  4. added
    Area-InputRelated to input processing (key presses, mouse, etc.)
    and removed
    Needs-TriageIt's a new issue that the core contributor team needs to triage at the next triage meeting
    on Nov 7, 2022
  5. hnakamur commented on Nov 8, 2022

    @hnakamur
    Author

    I tested this again and found out this also happens when I am not at the right side edge.

    Steps to reproduce:
    Input some Japanese texts and delete them and repeat that.

    2022-11-08-12-36-32.mp4
  6. hnakamur commented on Nov 18, 2022

    @hnakamur
    Author
  7. dogatana commented on Feb 1, 2023

    @dogatana

    Unfortunately, 1.16 still has this issue.
    As a workaround, I'm using 1.14 now, but sometimes it's updated to 1.15 automatically.
    And I cannot re-install 1.14 onto 1.15 with the following message.

    アプリをインストールできませんでした。エラー メッセージ: API Logging data because access was denied for file: \?\C:\Program Files\WindowsApps\Microsoft.WindowsTerminal_1.14.2281.0_x64__8wekyb3d8bbwe\CascadiaCode.ttf, user SID: S-1-5-18 からのエラー 0x0 が発生したため、AppX 展開操作に失敗しました (0x80070005)

    Although this is a Japanese message, I hope you can get information from this. 😅

    Every time this happens, I need to uninstall 1.15, install 1.14 and recover setting.json.

    I checked the settings, but I cloud not found the setting about auto-update.
    Any suggestions are most welcome.

  8. dogatana commented on Feb 2, 2023

    @dogatana

    1.17 has this too.
    I should use the following workaround.

    https://superuser.com/questions/1676001/windows-stop-killing-my-terminals-for-an-update

  9. 12 remaining items

  10. hnakamur commented on Sep 7, 2023

    @hnakamur
    Author

    I suppose the support for the old IME would be nice, but I am fine without it.

    I was using 「日本語を入力して」"nihongowonyuuryokusite" to reproduce the issue.

  11. lhecker commented on Sep 7, 2023

    @lhecker
    Member

    I was using 「日本語を入力して」"nihongowonyuuryokusite" to reproduce the issue.

    Thanks! But I still can't get it to reproduce the issue. 🥲 I just genuinely can't figure this out.
    And I noticed I haven't said this before: I'm sorry that it took so long for us to try and address this bug.

    I suppose the support for the old IME would be nice, but I am fine without it.

    One of my main tasks has been to improve the Internationalization of this project for a while now and I don't intend to give up just yet. 🙂 I was hoping to unify conhost's IME with the one in Windows Terminal at some point. conhost's IME implementation has two benefits: It uses TSF directly (without the WinRT CoreTextEditContext wrapper; less code = less bugs), and it writes the text during composition directly into the terminal viewport, so when you finish the composition it doesn't look quite as weird as it does now:

    image
    vs.
    image

    (I prefer the latter a lot.)

    I'm just not sure when I can get to that. There's a lot of remaining Internationalization bugs in this project after all... But there's a good chance that using TSF directly without the WinRT wrapper will allow us to properly support the legacy IME and fix all those weird edge cases.
    (Korean and Vietnamese in particular have a very difficult IME. By fixing those 2 IMEs, I broke the Japanese legacy IME. 😟 The conhost TSF/IME implementation never had those issues to begin with, thanks to its tight TSF integration.)


    Mike Griese (@zadjii-msft) Should we close this bug, or repurpose it to track the Japanese legacy IME being broken? I think the latter might be good. This issue would get fixed properly if we ever manage to integrate the conhost TSF implementation into WT.

  12. cleet2b commented on Sep 20, 2023

    @cleet2b

    When using tab to cycle through items I noticed that when the text would hit the right side of the terminal it would start bugging out for consecutive uses of tab. It seems to print previous lines again although this is purely visual.

    japanese.text.bug.mp4

    Win Terminal version: 1.17.11461.0

  13. added
    Issue-TaskIt's a feature request, but it doesn't really need a major design.
    and removed
    Issue-BugIt either shouldn't be doing this or needs an investigation.
    on Feb 7, 2024
  14. added a commit that references this issue on Apr 18, 2024
    4e7b63c
  15. lhecker commented on Apr 18, 2024

    @lhecker
    Member

    We just published a major update to our IME implementation in the nightly Canary branch. It was rewritten from the ground up and has tons of improvements! If you're interested in trying it out, you can get it here: https://aka.ms/terminal-canary-installer
    If you already have the Canary build installed, you can use this link to force an update.

    If you encounter any issues or have any suggestions, or if you simply like/dislike the changes, please let us know! Thank you for bearing with us. 😊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Area-InputRelated to input processing (key presses, mouse, etc.)Help WantedWe encourage anyone to jump in on these.In-PRThis issue has a related PRIssue-TaskIt's a feature request, but it doesn't really need a major design.Needs-Tag-FixDoesn't match tag requirementsProduct-TerminalThe new Windows Terminal.

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions