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

[bug] messed console message color in pwsh with redirected stdout #15615

Closed
X1aomu opened this issue Feb 7, 2024 · 2 comments
Closed

[bug] messed console message color in pwsh with redirected stdout #15615

X1aomu opened this issue Feb 7, 2024 · 2 comments
Assignees

Comments

@X1aomu
Copy link

X1aomu commented Feb 7, 2024

Environment details

  • Operating System+version: Windows 11 + pwsh 7.4.1
  • Compiler+version: not related
  • Conan version: 2.0.17
  • Python version: 3.11.7

Steps to reproduce

  1. find any recipe to run conan export against
  2. in pwsh, run conan export <recipe> -f json > abc.txt
  3. console color is messed up
  4. run conan export <recipe> to see the correct color
  5. -f.json can be omited

Logs

image

@memsharded memsharded self-assigned this Feb 7, 2024
@memsharded
Copy link
Member

Hi @X1aomu

Thanks for your report.

Unfortunately this seems out of our control, but it seems a colorama issue, check: tartley/colorama#218 or tartley/colorama#335

We have seen this issue in other terminals like cmd and cmder with previous Python versions, but it seems with latest Python like 3.10 it is no longer a problem for us. But it seems the issue remains similar for powershell terminals.

To disable colors, there is the $Env:NO_COLOR=1 you can use to disable colors if necessary.

I suggest closing this ticket, as there is little we can do it from here, and track the colorama issues.

@X1aomu
Copy link
Author

X1aomu commented Feb 7, 2024

Thanks for pointing out the cause. Can close now. Let's reopen this when it is fixed on upstream, to make sure conan get updated.

@X1aomu X1aomu closed this as not planned Won't fix, can't repro, duplicate, stale Feb 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants