31 releases

0.7.7 Oct 4, 2023
0.7.6 Jun 3, 2023
0.7.5 Jul 26, 2022
0.5.0 Feb 25, 2021
0.2.3 Nov 10, 2019

#734 in Parser implementations

Download history 5/week @ 2024-08-12 21/week @ 2024-08-19 129/week @ 2024-09-23 13/week @ 2024-10-07 2/week @ 2024-11-04 10/week @ 2024-11-11 33/week @ 2024-11-18 7/week @ 2024-11-25

52 downloads per month

MIT license

31KB
737 lines

METAR parsing library for Rust

Testing

metar-rs Automated Testing

This library is being testing regularly with real-world METARs to find failures. The badge above indicates whether these tests are currently successful.

Quick usage

This simple usage will print out the parsed data from the METAR.

use metar::Metar;

fn main() {
  let metar = "EGHI 282120Z 19015KT 140V220 6000 RA SCT006 BKN009 16/14 Q1006";
  let r = Metar::parse(metar).unwrap();
  println!("{:#?}", r);
}

Issues

METARs are complicated structures. If you come across a METAR that doesn't parse correctly, please open an issue and include the METAR. This will aid in debugging the issue significantly.


lib.rs:

METAR parsing library for Rust

Quick usage

This simple usage will print out the parsed data from the METAR.

use metar::Metar;

let metar = "EGHI 282120Z 19015KT 140V220 6000 RA SCT006 BKN009 16/14 Q1006";
let r = Metar::parse(metar).unwrap();
println!("{:#?}", r);

Issues

METARs are complicated structures. If you come across a METAR that doesn't parse correctly, please open an issue and include the METAR. This will aid in debugging the issue significantly.

Dependencies

~2–2.8MB
~56K SLoC