Copy & Paste from any shell into MS Teams chat results in red background #8928

Closed
opened 2026-01-31 01:41:37 +00:00 by claunia · 8 comments
Owner

Originally created by @knuth-konrad on GitHub (Jun 9, 2020).

Originally assigned to: @zadjii-msft on GitHub.

Environment

Microsoft Windows [Version 10.0.18363.836]

Any other software?
MS Teams. And it's unique to MS Teams AFAIK. But both Terminal and Teams behave like expected when interacting with other software.

Steps to reproduce

  • Open any shell in terminal (tested with Ubuntu 18.04, PowerShell, cmd)
  • Mark any text in the shell (I'm using the mouse)
  • Copy marked text to clipboard (I've remapped Copy to CTRL+INS and Paste to SHIFT+INS, if that matters)
  • Paste the clipboard contents in a Teams chat

Expected behavior

Copy & Paste from other plain text sources (of which I think the Terminal is one, mat least when it comes to C&P) results in black text on white background (using the light theme for Teams). I'd expect the same colors when pasting text from the Terminal.

C&P from PowerShell or cmd not launched thru Terminal results in the expected behavior.

Actual behavior

Text pasted from a Terminal shell results in MS Teams adding a red background:

  • Ubunbtu
    image
  • PowerShell
    image
  • CMD
    image

I don't know which application to blame, as both seem to show the expected results when interacting with other applications. It's these two interacting with each other.

Originally created by @knuth-konrad on GitHub (Jun 9, 2020). Originally assigned to: @zadjii-msft on GitHub. <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> <!-- This bug tracker is monitored by Windows Terminal development team and other technical folks. **Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**. Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue. If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link. Please use this form and describe your issue, concisely but precisely, with as much detail as possible. --> # Environment Microsoft Windows [Version 10.0.18363.836] Any other software? MS Teams. And it's unique to MS Teams AFAIK. But both Terminal and Teams behave like expected when interacting with other software. # Steps to reproduce - Open any shell in terminal _(tested with Ubuntu 18.04, PowerShell, cmd)_ - Mark any text in the shell _(I'm using the mouse)_ - Copy marked text to clipboard _(I've remapped Copy to CTRL+INS and Paste to SHIFT+INS, if that matters)_ - Paste the clipboard contents in a Teams chat # Expected behavior Copy & Paste from other plain text sources _(of which I think the Terminal is one, mat least when it comes to C&P)_ results in black text on white background _(using the light theme for Teams)_. I'd expect the same colors when pasting text from the Terminal. C&P from PowerShell or cmd **not** launched thru Terminal results in the expected behavior. # Actual behavior Text pasted from a Terminal shell results in MS Teams adding a red background: - Ubunbtu ![image](https://user-images.githubusercontent.com/23211410/84137370-e6860280-aa4c-11ea-956c-d1b71bc9ba63.png) - PowerShell ![image](https://user-images.githubusercontent.com/23211410/84137443-00bfe080-aa4d-11ea-8861-4eca067a052f.png) - CMD ![image](https://user-images.githubusercontent.com/23211410/84137715-58f6e280-aa4d-11ea-99c1-5456c40198b1.png) I don't know which application to blame, as both seem to show the expected results when interacting with other applications. It's these two interacting with each other.
Author
Owner

@zadjii-msft commented on GitHub (Jun 9, 2020):

I'll say that Teams has by far the worst formatted paste of any app I've seen so far. I don't know why it seems to just pick a seemingly random color for the text background, and ignore everything else.

It works fine in Outlook and other office apps:
image

but Teams is just:
image


You can work around this usually by pressing ctrl+shift+v when pasting into Teams.


I'm gonna take this on me to follow up with the Teams team and figure out why this is so bad. I've filed feedback, and their bot gave me a link in my inbox to follow up with

@zadjii-msft commented on GitHub (Jun 9, 2020): I'll say that Teams has by far the worst formatted paste of any app I've seen so far. I don't know why it seems to just pick a seemingly random color for the text background, and ignore everything else. It works fine in Outlook and other office apps: ![image](https://user-images.githubusercontent.com/18356694/84194987-7040ca80-aa63-11ea-8102-a3f14001eff0.png) but Teams is just: ![image](https://user-images.githubusercontent.com/18356694/84195028-82226d80-aa63-11ea-9784-be75f9dccc00.png) <hr> You can work around this usually by pressing <kbd>ctrl+shift+v</kbd> when pasting into Teams. <hr> I'm gonna take this on me to follow up with the Teams team and figure out why this is so bad. I've filed feedback, and their bot gave me a link in my inbox to follow up with
Author
Owner

@DHowett commented on GitHub (Jun 10, 2020):

And if you want to disable formatted copy forever, add "copyFormatting": false to your toplevel settings. 😄

@DHowett commented on GitHub (Jun 10, 2020): And if you want to disable formatted copy forever, add `"copyFormatting": false` to your toplevel settings. :smile:
Author
Owner

@knuth-konrad commented on GitHub (Jun 16, 2020):

@zadjii-msft Thanks for picking this up and handing it over to the appropriate Teams ... pun intended, obviously.

Now that it isn't a Terminal isue, but got picked up, I'm unsure as to what to do with the issue? Close it, leave it open for you guys to follow up? I'd be fine by me, if you close it yourself, if no longer needed as an open issue.

@DHowett Thank you very much! Now that is helluva useful setting. If I had something to say, that'd be the default setting.

@knuth-konrad commented on GitHub (Jun 16, 2020): @zadjii-msft Thanks for picking this up and handing it over to the appropriate Teams ... pun intended, obviously. Now that it isn't a Terminal isue, but got picked up, I'm unsure as to what to do with the issue? Close it, leave it open for you guys to follow up? I'd be fine by me, if you close it yourself, if no longer needed as an open issue. @DHowett Thank you very much! Now that is helluva useful setting. If I had something to say, that'd be the default setting.
Author
Owner

@zadjii-msft commented on GitHub (Jun 16, 2020):

I'm gonna leave this open for now while to make sure I track down the right people. Thanks for the diligence though!

@zadjii-msft commented on GitHub (Jun 16, 2020): I'm gonna leave this open for now while to make sure I track down the right people. Thanks for the diligence though!
Author
Owner

@DHowett commented on GitHub (Jun 16, 2020):

the default setting

Good news! It is, for anyone who installed Terminal after version 1.0 came out. We didn’t stomp the defaults for everyone who was already using it, because moving peoples’ cheese is considered unkind ;)

@DHowett commented on GitHub (Jun 16, 2020): > the default setting Good news! It is, for anyone who installed Terminal after version 1.0 came out. We didn’t stomp the defaults for everyone who was already using it, because moving peoples’ cheese is considered unkind ;)
Author
Owner

@knuth-konrad commented on GitHub (Jun 17, 2020):

@DHowett

Good news! It is, for anyone who installed Terminal after version 1.0 came out.

What's this arcane sorcery? Mind-reading from afar ... 👍

@knuth-konrad commented on GitHub (Jun 17, 2020): @DHowett > Good news! It is, for anyone who installed Terminal after version 1.0 came out. What's this arcane sorcery? Mind-reading from afar ... 👍
Author
Owner

@zadjii-msft commented on GitHub (Jul 14, 2020):

Hey so a follow up from the Teams team - apparently this is going to be fixed in an upcoming Teams release, but I'm not sure when that release will land, and I'm pretty confident I couldn't communicate that timeline even if I did know.

@zadjii-msft commented on GitHub (Jul 14, 2020): Hey so a follow up from the Teams team - apparently this is going to be fixed in an upcoming Teams release, but I'm not sure when that release will land, and I'm pretty confident I couldn't communicate that timeline even if I did know.
Author
Owner

@zadjii-msft commented on GitHub (Oct 28, 2021):

Locally, this seems fixed, so I'm sure the GA for the teams-side fix for this is Soontm. Thanks!

@zadjii-msft commented on GitHub (Oct 28, 2021): Locally, this seems fixed, so I'm sure the GA for the teams-side fix for this is Soon<sup>tm</sup>. Thanks!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#8928