-
Notifications
You must be signed in to change notification settings - Fork 15
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
interact
method on spawn_bash
session doesn't echoes input
#10
Comments
related: #3 |
A research showed - reading changes a terminal line settings: Here use With read before interactstty^Mspeed 38400 baud; line = 0;
-brkint -imaxbel
-echo Without presiding readEXPECT_PROMPT>stty
speed 38400 baud; line = 0;
-brkint -imaxbel |
Here's a termios flags differences
|
There was an idea that it may be an issue of spawned program. As it may change termios settings at any point. Spawning Code which reproduces an issuefn main() {
use expectrl::Session;
let mut bash = Session::spawn("python").expect("Error while spawning bash");
bash.expect(">>> ").unwrap();
let status = bash.interact().expect("Failed to start interact");
println!("Quiting status {:?}", status);
} |
If we would read only preamble but don't So the actual issue is in reading exactly PROMPT. Why? |
It seems like bash cab override tty mode at any time. I am trying to create a powershell repl and Here I am typing a random chars
|
My guess for some reason when we do an expect of initial prompt something is changed so type ENTER
causes a production of CTRL-M(^M) where without it it causes \r\n
The text was updated successfully, but these errors were encountered: