Travel Mapping

User Discussions => Other Discussion => Topic started by: mapcat on July 24, 2025, 08:49:21 am

Title: TM Airports
Post by: mapcat on July 24, 2025, 08:49:21 am
About a month ago I started playing around with Copilot and discovered that it likes to code. Eventually this happened, and Jim graciously agreed to host it on TravelMapping:

https://tmairports.teresco.org/ (https://tmairports.teresco.org/)

Here's how it works:

The current output is simple: symbols at airports worldwide that show a user's visits to that airport. Users who have departed an airport will see a green upward-pointing triangle, and users who have arrived at an airport will see one in red pointing downward. Airports where users experienced a layover (with or without a plane change) appear as a blue circle surrounding the triangles.


How to create a map

Maps are generated from "alist" files submitted by users via GitHub or email, however they normally submit their travel updates. The map shows all airports the user has visited: arrivals, departures, and layovers (refueling stops are considered layovers for now).

The filename should be [username].alist. In the file, user data should use the following format:

[IATA Airport Code] [N] [N]* [N]*

*the third and fourth fields are optional.

N can be any of the following codes: A (for arrival), D (for departure), and L (for layover).

Example file lines:

Code  Meaning
ATL A D L  Traveler arrived at and departed from Atlanta, and had a layover there.
LAX A D  Traveler arrived at and departed from Los Angeles.
ORD L  Traveler had a layover at Chicago O'Hare, but no arrival or departure.

Each airport should be on a separate line. The order of the A, D, and L does not matter. The file should be submitted via a GitHub pull request at TravelMapping/AirportData/air/data (email submissions will be available soon but are not currently supported). Once the file is merged, their map should update automatically within a few minutes. Users can locate their maps by choosing their username from the drop-down menu.

There is only one option for the map currently (show all airports, or only visited airports).

More airports will be added. If a user submits an .alist with an airport not currently in airports.csv, that airport will be flagged automatically, which will prompt me to add it to the database. So please include all airports you've visited in your .alist.

Hovering over an airport (or clicking on the icon) will identify it with the name pulled from a list stored in airports.csv.


Known issues:

Future plans and items for discussion:

I hope users find this useful. Let me know if you have any questions or ideas, and please make suggestions for improvements and related pages (user page, rankings, etc). Or share your thoughts at GitHub: https://github.com/TravelMapping/AirportData (https://github.com/TravelMapping/AirportData)
Title: Re: TM Airports
Post by: si404 on July 24, 2025, 12:11:57 pm
Added my stuff - https://github.com/TravelMapping/AirportData/pull/3

This point thing has potential for other uses - you could do a similar thing with other things that's basically a binary "I've been here" with some ability to give different codes to describe your visit. Eg National Parks (though preferably that would have areas that are coloured rather than points. But National Historic Sites would probably work better as points).
Title: Re: TM Airports
Post by: Jim on July 24, 2025, 01:05:08 pm
I pulled in a couple of new .alist files on GitHub then pulled the results down onto the TM server.  So the two new users are there now.

I couldn't force a hard enough reload in Firefox to see the updates, maybe I have to manually clear something from its cache.  I'm seeing the latest data when I load in a different browser.
Title: Re: TM Airports
Post by: si404 on July 24, 2025, 02:03:36 pm
An issue I found in my data is that I listed each flight separately in order, and the data only shows the final line with that airport in rather than stacking the multiple lines and saying that I've both landed and departed.

This is perhaps more a feature request than a bug to fix.
Title: Re: TM Airports
Post by: mapcat on July 24, 2025, 08:02:41 pm
An issue I found in my data is that I listed each flight separately in order, and the data only shows the final line with that airport in rather than stacking the multiple lines and saying that I've both landed and departed.

This is perhaps more a feature request than a bug to fix.
Thanks for trying that. I had not considered that users might want to enter data that way, but will work on it some more and see if it's possible for the script to combine data from lines that begin with the same code.
Title: Re: TM Airports
Post by: mapcat on July 24, 2025, 08:04:49 pm
I pulled in a couple of new .alist files on GitHub then pulled the results down onto the TM server.  So the two new users are there now.

I couldn't force a hard enough reload in Firefox to see the updates, maybe I have to manually clear something from its cache.  I'm seeing the latest data when I load in a different browser.

I'll look into that since I usually don't have that issue after it rebuilds the pages.
Title: Re: TM Airports
Post by: mapcat on July 24, 2025, 08:07:13 pm
This point thing has potential for other uses - you could do a similar thing with other things that's basically a binary "I've been here" with some ability to give different codes to describe your visit. Eg National Parks (though preferably that would have areas that are coloured rather than points. But National Historic Sites would probably work better as points).

Great ideas! I agree that national parks should be areas instead of points, but the scripts here should be easy to modify for other travel-related destination displays, assuming there's a demand not already being met somewhere else.
Title: Re: TM Airports
Post by: neroute2 on July 25, 2025, 01:15:12 am
One potential use for the point tracking: which freeway interchanges you've used. Obviously no new wpt files are needed, just a new list file and a way to parse it.
Title: Re: TM Airports
Post by: Griffith on July 25, 2025, 09:15:57 am
NAN airport code is shown as Nan Nakhon in Thailand, the correct code for that airport is NNT.
NAN is actually Nadi International in Fiji
Title: Re: TM Airports
Post by: bejacob on July 25, 2025, 09:48:37 am
NAN is actually Nadi International in Fiji

That's pretty important to me as back in the 1970s Nadi was an important fuel stop between Australia and the US. Stopped there several times as a kid on trips between SYD and SFO. NAN and HNL were almost always part of that route. The first time I got to do it nonstop was in 1977 on a Pan Am 747SP. At the time, it was the longest flight in the world.
Title: Re: TM Airports
Post by: mapcat on July 25, 2025, 10:41:27 am
Thanks for catching that. Just fixed the csv, and the map should update in the next hour or so.

The user(s) with NAN in their .alist will need to change it to NNT.

First broken .alist! That didn't take long.
Title: Re: TM Airports
Post by: mapcat on July 25, 2025, 09:23:51 pm
Thanks to all for the submissions. They should all be up now. If the map hasn't updated for you yet, you'll need to clear your cache.
Title: Re: TM Airports
Post by: mapcat on July 27, 2025, 08:55:28 pm
Made some upgrades to TM airports over the weekend. You'll see that they were mostly about functionality rather than appearance.

https://tmairports.teresco.org/AirportData/air/web/ (https://tmairports.teresco.org/AirportData/air/web/)

Sorry for making the index page look like a squatter stole Jim's site.

Anyway, click the buttons and browse all the airports to see who's been there, or view personalized pages for each user.

Comments and suggestions welcome.
Title: Re: TM Airports
Post by: si404 on July 28, 2025, 04:30:46 am
Comments and suggestions welcome.
Viewing by airport records all the lines in my file, unlike viewing by user.

I like the list of users for each airport, and airports for each user.

Stepping in the right direction for functionality here.
Title: Re: TM Airports
Post by: Nagamasa on July 28, 2025, 04:43:25 pm
AI struggled, but pulled through in converting my spreadsheet into the desired list file. I've submitted a PR: https://github.com/TravelMapping/AirportData/pull/18
Title: Re: TM Airports
Post by: mapcat on August 03, 2025, 04:45:30 pm
I just pulled in a few more upgrades. The default user.html page now has a list of all users and their totals, with sortable columns, and links to individual user pages that show what the old default showed. The all-airport map at airports.html has different markers color-coded by number of users with travels to/from/through each airport.

A new user si403 is on there so I can test some enhancements that will allow users to submit a different type of .alist, like si404 did. His file was broken down by trip, so certain airports such as LHR appeared several times, anytime he departed from or arrived at the airport. The script currently digests his .alist incorrectly, showing only A or D for airports that appeared multiple times rather than both A and D. So si403.alist is there to demonstrate what si404.alist *should* produce, rather than its current output. It also corrects a typo in one airport code (AGO -> AHO since I assumed he didn't fly home from Arkansas after visiting Sardinia).

I'd like to focus on the aesthetics next. Please post suggestions for how I might make the pages look better or provide more useful information.

index.html (https://tmairports.teresco.org/AirportData/air/web/index.html): the opening page probably should resemble the general TM index page (highways (https://travelmapping.net/), rail (https://tmrail.teresco.org/)) but I'm not sure what to include. It looks horrible right now so this is the first one I want to work on.
airports.html (https://tmairports.teresco.org/AirportData/air/web/airports.html): it looks okay on my phone, but not great in landscape mode on a monitor. One thing that annoys me is the Leaflet map, which allows scrolling past 180° longitude, but only shows 2 hemispheres' worth of icons. It probably should be confined to -179.999° <-> 179.999° somehow. Not sure how to do that. A more attractive TM-style header and table would improve it as well.
user.html (https://tmairports.teresco.org/AirportData/air/web/user.html): generic page is boring but functional, and individual user pages have the same concerns as airports.html.
Title: Re: TM Airports
Post by: jlam on August 03, 2025, 06:56:04 pm
Created a pull request for a new list. Let me know if I messed up: https://github.com/TravelMapping/AirportData/pull/23
Title: Re: TM Airports
Post by: mapcat on August 03, 2025, 09:27:06 pm
Created a pull request for a new list. Let me know if I messed up: https://github.com/TravelMapping/AirportData/pull/23
Got it, thanks. I tested it and everything looks great. The airport part of TM auto-updates at :15 past the hour, so check back then.
Title: Re: TM Airports
Post by: Scott5114 on August 04, 2025, 01:03:14 am
Interesting project! As someone else stated, there are a lot of different potential applications for the code base—bridges visited would be another one. If you had 2D areas, you'd also be able to stand up a mob-rule replacement fairly quickly if something ever happened to that.

Somewhere out there, there is probably an FAA directory that has all the airports in the US you could dump to the site. Some state DOTs have these as well. While your stated focus is commercial airports, there are a good number of hobbyist pilots who would probably appreciate a way to track general-aviation airports they've flown in and out of as well. (The main difficulty with these is that they don't always have IATA codes—my "home airport" growing up had the code 1K4, and I don't know whether that code that was assigned by FAA or Oklahoma DOT.)

It might be useful to have a way to note that you visited an airport by a mode of travel other than airplane (e.g. if you were only there to pick up a passenger).
Title: Re: TM Airports
Post by: oscar on August 04, 2025, 10:03:18 am
It might be useful to have a way to note that you visited an airport by a mode of travel other than airplane (e.g. if you were only there to pick up a passenger).

I have a few airports in that category:

Denver-DEN (drove through the departures level of the terminal, after clinching the Peña Blvd. airport connector -- I've never flown into or out of either that airport or the former Stapleton airport which originally had the DEN IATA code)

Martha's Vineyard-MVY (made a bus connection at that hub for the island's bus system after taking a ferry to the island, and went into the terminal for a bathroom and lunch break)

Tuktoyaktuk-YUB (rest stop after clinching NT 10 in a rental car)

Charles M. Schulz/Sonoma County-STS (drove onto the airport grounds, just to photograph the airport's cool Snoopy logo (https://sonomacountyairport.org/about-sts/faq/))

Ketchikan-KTN (went into the terminal for a bathroom break, using the free airport parking permit that came with taking my car on the airport ferry -- though I've also made a conventional layover at that airport, so it's already on my map)

I've also rented cars at many of the other airports already on my map.