Skip to content

Unexpected behavior: parsing cloud data #91

@brotherJ4mes

Description

@brotherJ4mes

Hi thanks for this great tool!

I just wanted to point out something that I found pretty unintuitive: A METAR message with "CLR" (indicating no clouds) is treated the same as a message with no reported cloud information.

In my particular use case, I was converting CLR|FEW|SCT|BKN|OVC to approximate numeric values (0, 25%, 50%, etc.) when I discovered that the resulting object's clouds attribute will be empty for "CLR". I would expect CLR to be in the description of clouds quantity. Especially since the same thing occurs if no cloud strings are present in the METAR code. I was able to easily work around this by parsing the original METAR message for these strings with basic regular expression matches.

I'm no METAR expert so perhaps I'm misunderstanding something but I would think (beyond my use case) the end user would want to make a distinction between the two cases:

  • clear skies (essentially 0% cloud cover)
  • missing cloud information (unknown cloud cover / NA)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions