Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kernel panics when encountering unicode characters in custom prompt. #19

Open
joelle-o-world opened this issue Jul 13, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@joelle-o-world
Copy link

Description

From looking at the readme it seems like supporting an extended character set is beyond the current scope of this project at the moment. So I feel a bit cheeky making this request. I would love it to work because I'm trying to use thokr as part of practice learning languages.

The program halts when it encounters an extended character (when the user is expected to type that character, before they have done so).

To Reproduce

Enter this command:

thokr -p "ich heiße Thokr"

and type ich hei

Expected behavior

The kernel panics with the following output:



                                                                               ich heithread 'main' panicked at 'byte index 8 is not a char boundary; it is inside 'ß' (bytes 7..9) of `ich heiße Thokr`', /Users/joelle/.cargo/registry/src/index.crates.io-6f17d22bba15001f/thokr-0.4.1/src/ui.rs:92:21
                                                                                                                             note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
                              ⏎                      

Screenshots

Screenshot 2023-07-13 at 13 42 20

Environment

  • OS: Mac OS 12.5
  • Terminal Emulator: Kitty (with Fish)
  • Font: JetBrains mono nerd font
  • Crate version: thokr 0.4.1

Additional context

@joelle-o-world joelle-o-world added the bug Something isn't working label Jul 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant