question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to show weather data on Windows console

See original GitHub issue

The console is not able to display data returned by curl wttr.in. It’s all garbled. I know it’s a Windows problem but do you have any suggestions on how can I make it work.

I even tried an external console emulator, ConEmu. No luck there too.

Issue Analytics

  • State:open
  • Created 8 years ago
  • Comments:48 (36 by maintainers)

github_iconTop GitHub Comments

7reactions
majkinetorcommented, Apr 11, 2016

People on Reddit found solution:

 $(Invoke-WebRequest http://wttr.in ).ParsedHtml.body.outerText
6reactions
PhMajeruscommented, Mar 18, 2019

Just to let you guys know, that isn’t a bug in wttr.in, but a limitation of the current Win32 version of curl.

Basically the Windows 10 console starts without VT processing enabled for backward compatibility. The current Win32 version of curl.exe (shipping in Win10 1809) doesn’t change the configuration of the console, so it inherits whichever mode was set by another process attached to the same console before it. It seems cmd.exe and PowerShell both unset the VT-processing flag before launching external utilities, probably to accommodate for backward compatibility again, assuming if an utility expects VT processing, it will set the flag itself before outputting VT markup. Launching curl.exe from a shell that leaves the VT-processing flag on does result in the expected colorful result, but that means you’d need an intermediate launcher when using it from cmd.exe or PowerShell. The only proper fix is for curl.exe to enable VT-processing. More details if you want : https://github.com/Microsoft/console/issues/216

wttr.in works properly when ENABLE_VIRTUAL_TERMINAL_PROCESSING is set, except for diagonal wind directions arrows that use a glyph not available in the standard console fonts (Consolas and Lucida Console).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Fix: Windows 11 Is Not Displaying the Weather Widget
If the Weather Widget is not working on Windows 11, reinstall the Web Experience Pack. Then, go to Taskbar settings and re-enable Widgets....
Read more >
Weather widget isn't showing for me - Microsoft Community
tap or click one of the “plus” symbols and select Weather. Then under Choose an app to display detailed status, tap or click...
Read more >
Fix: Weather App not Working / Crashing In Windows 10
Go to Windows Settings and click Apps. · Search for the Weather app and click on it and then click the Advanced Options....
Read more >
Windows 10 issues - Davis Weather Stations Knowledgebase
Windows 10 is a major new Windows release from Microsoft. While Windows 10 offers many benefits, it does now have the potential to...
Read more >
How to Enable the New Weather Widget in Windows 11 Dev ...
Download link, commands used, and more info: https://itstechbased.com/how-to-enable-the-new- weather -widget-in- windows -11-dev-build/How to ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found