Skip to content

Conversation

@ejmmje
Copy link

@ejmmje ejmmje commented Oct 3, 2025

Hi all!

Just noticed my METARMap failing - no idea why it took me so long to notice. Saw a few people offering fixes, but I went a bit more nuclear. The new metar.py should be good to go now and has been working for me, including lightning and wind gusts. I also moved to JSON instead of XML and cleaned up a bunch of the code. Ideally I would have done more but didn't really understand how the external display code worked and didn't want to cause that to break.

Things I was unable to test:

  • LEGEND (I don't use one)
  • EXTERNAL DISPLAY (again, don't have one)

Let me know if anyone sees any issues with the updates! Should hopefully be plug and play, I tried to match both the inputs and outputs of the old code.

ejmmje added 3 commits October 2, 2025 21:47
- Cleaned up code and converted to easier to use JSON format.
Updated metar.py to include new API
Updated configuration settings for wind and lightning animations, and adjusted daytime dimming options.
@ejmmje ejmmje mentioned this pull request Oct 3, 2025
Copy link

@gth758y gth758y left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for putting this together. It worked for me, but I'd suggest adding some error handling for incomplete METARs. For instance, VUO is currently not reporting a visibility, which caused this error: ValueError: invalid literal for int() with base 10: ''

@ejmmje
Copy link
Author

ejmmje commented Oct 8, 2025

@gth758y

Thanks for the tip! I should have added a more robust section there, just kinda threw something together to get it working. I've added all that functionality and even added a new feature. If REPLACE_CAT_WITH_CLOSEST (a new config option) is set to True, then the code will find the nearest METAR (from your airports list) and show that category so that you don't just have a blank there.

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

Successfully merging this pull request may close these issues.

4 participants