This may only pertain to displaying output in the echo area.
The output filter function that gets called when new output arrives may be called multiple times for each output. We already filter out prompts, trailing newlines, and empty strings, but desired output might also be split into multiple calls, and only the last will be displayed in the echo area. That will look incorrect.
Determine if there is any way to modify comint's behavior. If not, then we may need to buffer the output.
Proposal: Each time output is received, use comint's fns to find the output between the last input and the current prompt.
This may only pertain to displaying output in the echo area.
The output filter function that gets called when new output arrives may be called multiple times for each output. We already filter out prompts, trailing newlines, and empty strings, but desired output might also be split into multiple calls, and only the last will be displayed in the echo area. That will look incorrect.
Determine if there is any way to modify comint's behavior. If not, then we may need to buffer the output.
Proposal: Each time output is received, use comint's fns to find the output between the last input and the current prompt.