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

OSC sequences in prompt get front loaded #11220

Closed
Tyriar opened this issue Sep 13, 2021 · 3 comments
Closed

OSC sequences in prompt get front loaded #11220

Tyriar opened this issue Sep 13, 2021 · 3 comments
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@Tyriar
Copy link
Member

Tyriar commented Sep 13, 2021

Windows Terminal version (or Windows build number)

19042.1165

Other Software

VS Code
Version: 1.61.0-insider (user setup)
Commit: ec40cbe164c59f3d13b6eff5fc7b0231ec0ab7aa
Date: 2021-09-13T05:15:14.689Z
Electron: 13.1.8
Chrome: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.19042

Steps to reproduce

Redefine the prompt to inject OSC sequences, for example:

pwsh:

function Prompt() {
  return "`e]133;before`u{7}middle`e]133;after`u{7}"
}

wsl.exe:

export PS1='\x1b]133;before\x07middle\x1b]133;after\x07

When this gets run through conpty all the OSC sequences seem to get front loaded, not put in the order that they are defined.

Expected Behavior

I expect the terminal to receive the following:

�[?25l�[12;7H�]133;before�middle�]133;after�
�[?25h

Actual Behavior

�[?25l�[12;7H�]133;before��]133;after�
middle�[?25h
@msftbot msftbot bot added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Sep 13, 2021
@j4james
Copy link
Collaborator

j4james commented Sep 14, 2021

This sounds like a variant of #8698.

Edit: Although, now that I think about, this particular case is probably not completely fixable without a pure pass-through mode (i.e. #1173).

@zadjii-msft
Copy link
Member

Yea, this is /dup #8698, which should get fixed by passthrough, once we get the details all sorted out.

@msftbot
Copy link
Contributor

msftbot bot commented Sep 14, 2021

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@msftbot msftbot bot closed this as completed Sep 14, 2021
@msftbot msftbot bot added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Sep 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

3 participants