We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Using cuicui_chirp 0.12.0 on Windows, with the following chirp file with CRLF line endings:
fn spacer() { Spacer(height(10px) width(10%) bg(coral)) } Menu(screen_root row) { spacer!() }
yields the following error:
2024-01-10T15:33:30.663376Z ERROR cuicui_chirp::loader::internal: × Invalid chirp file: (0) Tried to call !, but this template doesn't exist., Error: × Tried to call !, but this template doesn't exist. ╭─[ui/main_menu.chirp:2:1] 2 │ Spacer(height(10px) width(10%) bg(coral)) 3 │ } 4 │ Menu(screen_root row) { · ─ 5 │ spacer!() 6 │ } ╰────
Adding a trace logging line to cuicui_chirp parser/interpret.rs line 200-202
let (mut name, span) = tpl.name().read_spanned(inp); trace!("{inp:?} {:?}", std::str::from_utf8(name)); name = &name[..name.len() - 1];
shows the following trace logging:
2024-01-10T15:33:30.662934Z TRACE cuicui_chirp::parser::interpret: "fn spacer() {\r\n Spacer(height(10px) width(10%) bg(coral))\r\n}\r\nMenu(screen_root row) {\r\n spacer!()\r\n}" Ok("\r")
which led me to the following workaround:
Switch the .chirp file to use LF line endings, at which point it loads as expected.
The text was updated successfully, but these errors were encountered:
Thanks for the super detailed bug report!
With your help, I think I could figure out where the issue is:
cuicui_layout/chirp/src/parser/lex.rs
Line 232 in d234bc7
Need to add a \r in there eh.
\r
Sorry, something went wrong.
Yeah, I think that would do it :)
I will push an update Monday with the fix.
No branches or pull requests
Using cuicui_chirp 0.12.0 on Windows, with the following chirp file with CRLF line endings:
yields the following error:
Adding a trace logging line to cuicui_chirp parser/interpret.rs line 200-202
shows the following trace logging:
which led me to the following workaround:
Workaround
Switch the .chirp file to use LF line endings, at which point it loads as expected.
The text was updated successfully, but these errors were encountered: