Notifications
Clear all

10/18/2023 Map Stopped Working?
Visit this post for the fix

3 letter airport codes and warning/error message

5 Posts
2 Users
0 Likes
1,156 Views
(@kevin_404)
Active Member
Joined: 3 years ago
Posts: 0
Topic starter  

F00 is a valid airport with metar data however the airport editor requires 4 characters.  If you put in KF00 it identifies the airport correctly but weather will not pull for the airport. If you manually edit the airport file and change it to f00 all other airports fail to get weather.

 

I'm also seeing the following unrelated message in the log files :

[I 210408 19:25:30 metar-v4:1150] KWDR Not Reporting Flight Category through the API.
[I 210408 19:25:30 metar-v4:1150] KLFT Not Reporting Flight Category through the API.

 

The airports seem to still be working though -- any idea what this message means?

 

Thanks!

 


   
Quote
Mark Harris
(@markyharris)
Member Admin Registered
Joined: 4 years ago
Posts: 552
 

Kevin,

aviationweather.gov requires 4 digits for its data server to return weather for an airport. So in your case this is the URL that is being used to pull weather from KF00;

 https://www.aviationweather.gov/adds/dataserver_current/httpparam?dataSource=metars&requestType=retrieve&format=xml&hoursBeforeNow=1.5&stationString=KF00 

This returns valid XML Weather data for the airport. Here's a small portion of the returned data;

<response xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.2" xsi:noNamespaceSchemaLocation="http://www.aviationweather.gov/static/adds/schema/metar1_2.xsd">
<request_index>338775503</request_index>
<data_source name="metars"/>
<request type="retrieve"/>
<errors/>
<warnings/>
<time_taken_ms>7</time_taken_ms>
<data num_results="5">
<METAR>
<raw_text>KF00 081535Z AUTO 30008KT 10SM CLR 20/00 A2989 RMK AO2 T01950005</raw_text>
<station_id>KF00</station_id>
<observation_time>2021-04-08T15:35:00Z</observation_time>
<latitude>33.62</latitude>
<longitude>-96.18</longitude>
<temp_c>19.5</temp_c>
<dewpoint_c>0.5</dewpoint_c>
<wind_dir_degrees>300</wind_dir_degrees>
<wind_speed_kt>8</wind_speed_kt>
<visibility_statute_mi>10.0</visibility_statute_mi>
<altim_in_hg>29.890747</altim_in_hg>
<quality_control_flags>
<auto>TRUE</auto>
<auto_station>TRUE</auto_station>
</quality_control_flags>
<sky_condition sky_cover="CLR"/>
<flight_category>VFR</flight_category>
<metar_type>SPECI</metar_type>
<elevation_m>189.0</elevation_m>
</METAR>

As long as the information is returned, LiveSectional will properly display it. But there are times where the data is either incomplete or not returned at all. This is usually temporary and will resolve itself. So based on what I'm seeing this morning, all should be good with your map. Just be sure to put the K (for US and its territories) and it will work.

Regarding the message; 'KWDR Not Reporting Flight Category through the API.' There are many times when the FAA doesn't provide the actual flight category for an airport. You can see this in the XML data above 4th line from the bottom.

The script will first look for the 'flight_category' and use it if its returned by the FAA. However, when its not, there is a routine in the script that will try to decode the flight category based on ceilings and visibility. So I log the message you asked about to let the user know that its decoding the flight category manually rather than using the flight category normally provided by the FAA in the XML data.

Hope this helps. - Mark


   
ReplyQuote
(@kevin_404)
Active Member
Joined: 3 years ago
Posts: 0
Topic starter  

ok thanks! in that case there is a bug in airport editor, because if you put KF00 it identifies the airport correctly but says KF00 METAR (Data Unavailable).  When you click on the link for the airport it returns airport not found with the following URL : https://nfdc.faa.gov/nfdcApps/services/ajv5/airportDisplay.jsp?airportId=KF00


   
ReplyQuote
Mark Harris
(@markyharris)
Member Admin Registered
Joined: 4 years ago
Posts: 552
 

I understand. Thanks for pointing this out. I have to use a different weather product from the FAA for the LED's vs the weather reported on the web page. I'll look to see if there is a way to reconcile this. - Mark


   
ReplyQuote
Mark Harris
(@markyharris)
Member Admin Registered
Joined: 4 years ago
Posts: 552
 

Kevin, I changed the site for airport information to fltplan.com since it will accept the airport name in either 3 or 4 letter designations. So that problem is solved.

If the FAA API is not currently providing a METAR for an airport, I have a message stating this and a link to manually get the current weather. Finally, if the ID is not recognized, it will come back as 'Undefined'.

I'll play with this more to see if there is anything else that would make this better. Thanks for pointing this out. It will be available in the next image update. - Mark


   
ReplyQuote
Share: