Amersham trains have no destination before Finchley Road

Apologies if this has been answered before, but I have tried to find the information and couldn’t see it.
I’m looking at westbound Metropolitan line trains for Amersham. They only seem to have the destination stated once they are past Baker Street. The same appears to be true on the website, so it looks like an issue with the underlying data.
Is this an issue with the signalling system that I’ve seen referred to elsewhere? If so, do we have an approximate date for the upgrade?
If not, can someone shed light on either how I can get the data, or when it might become available?
Many thanks all

It looks as though you’re right - I am seeing Amersham trains in the Trackernet data but not in the Unified API - they are either just not there or show ‘Check front of train’

The Trackernet data is available here:
http://cloud.tfl.gov.uk/TrackerNet/PredictionDetailed/M/AME
(the M is for Metropolitan Line and AME is the code for Amersham) To get all the trains on the Met Line you’ll need to poll more stations - MPK, HOH, BKS and KXX are good places to try.

It’s in XML though, which might not be welcome.
There are advantages, it is (supposedly) the underlying data that the Unified feed is based on (although there must be other sources) and it is more accurate and up to date. TFL want to retire it though, so how long it is good for is an open question.

Note that for some reason it can’t handle Chesham at all. It refuses to acknowledge that Chesham exists.

You might get comfort (or despair) from this project:
https://intertube.eta.st/live-line?code=M
It’s a pretty nice piece of work overall but she has determined that the Metropolitan Line data is unusable - which is probably sensible - but disappointing.

2 Likes

@grahamwell @jkent

Another thing that I recall about this strange stretch of track is that there are no platform numbers either, thus needing…

   case "HOH" :
        case "RIC":
        case "CLW":
        case "CFO":
            if ($destination->crs !== "MYB") {
                $strReturn = "1";
            } else {
                $strReturn = "2";
            }
            break;
        // Met terminal in the middle
        case "AMR" :
            if ($destination->crs !== "MYB") {
                $strReturn = "1";
            } else {
                $strReturn = "3";
            }
            break;
1 Like

Thank you, I wasn’t aware of that source, I’m not afraid of a bit of xml as long as the data is there to be found, so I’ll give it a go and see if I can find anything for the eastern end of the line

Good luck. I have some C# code if that’s any use, including the classes you’ll need.

The Amersham issue is real. I watched it last night. The current arrivals predictions in the Unified feed are just wrong, they’re completely ignoring Amersham trains.

1 Like

@grahamwell I think that @jamesevans said at some point that when 4LM programme was complete, this would provide an opportunity to have accurate data for the whole of the “4 lines” (circle, district, h&c and met). Four Lines Modernisation - Transport for London

Thanks everyone, really useful advice, I’ve finished the project now, it shows the location of Metropolitan and Chiltern trains in real time. I think it works pretty well


Did a making of video too, if anyone’s interested TubelightsByTubemouse - YouTube
Happy to share my (slightly shonky) code if anyone wants it

That looks great, it’s exactly what I was trying to do before I got … distracted.

Did you manage to find information for Chesham? I am convinced that there’s no Trackernet information for Chesham but I may just not have been trying the right code.

Hi, the code for Chesham should be CHM. Data for this station is available from the PredictionSummary feed:
http://cloud.tfl.gov.uk/TrackerNet/PredictionSummary/M

However, there does seem to be an issue when requesting the PredictionDetailed feed (it returns Status Code 204 – No Content):
http://cloud.tfl.gov.uk/TrackerNet/PredictionDetailed/M/CHM

I will discuss this issue with my colleagues to see if we can fix it.

Thanks, it took a long run up, but I got there in the end.
I didn’t end up trying to get the Chesham data, because I realised it was busy enough with just Amersham, It would have been a bit hard to make out what was going on with them if I’d added another in.
Looks like it’s being looked into though, so that’s good

1 Like

Thank you, I’d appreciate it.
The same issue appears to affect Battersea Power Station (BPS). It appears in the summary feed OK, but the detailed feed:
https://cloud.tfl.gov.uk/TrackerNet/PredictionDetailed/N/BPS
… returns an empty page.

1 Like

That’s useful to know. :slight_smile:

I ran a script to test every station and found that the following stations return an HTTP status code other than 200:

line_code station_code station_name status_code
B BSY Bushey. 204
B CPP Carpenders Park. 204
B HAT Hatch End. 204
B HSL Headstone Lane. 204
B WTH Watford High Street. 204
B WTJ Watford Junction. 204
D PADc Paddington Circle. 400
H BAY Bayswater. 204
H FRD Finchley Road. 204
H GHR Goldhawk Road. 204
H LGR Ladbroke Grove. 204
H LAT Latimer Road. 204
H NEA Neasden. 204
H NHG Notting Hill Gate. 204
H PADc Paddington Circle. 400
H ROY Royal Oak. 204
H SBM Shepherd’s Bush Market. 204
H WPK Wembley Park. 204
H WBP Westbourne Park. 204
H WLG Willesden Green. 204
H WDLP Wood Lane. 400
M CHM Chesham. 204
M NEA Neasden. 204
M WLG Willesden Green. 204
N BPS Battersea Power Station. 204
N NIE Nine Elms. 204
P AWY Aldwych. 204
P RCP Ravenscourt Park. 204

I will feed this back to my colleagues.

1 Like

That’s great, thank you. Of all of those, most are not really live tube services and the issue is probably with the summary feed (Aldwych?) rather than the detail feed - but the absence of detail data from Chesham and Battersea - both the end of the line of active services, is significant.

If you are going to have a conversation, could I also highlight the strange oddity on the Wimbledon branch of the District line, where trains for Victoria and beyond are marked as Circle Line trains with a destination of Parsons Green? This is This has been raised in the forum before:

Thanks

Thanks for your thoughts on this. Regarding the District line issue, I’ll respond in the linked topic (just to keep things organised).