cal-itp/gtfs-aggregator-checker

Output should indicate URL presence by aggregator

Closed this issue · 2 comments

The current output upon checking URL presence in the aggregator doesn't seem to include results about whether a URL was found in one feed aggregator, but not the other. The output should be modified so that it can provide feedback on whether a URL was present in each of the aggregators.

@evansiroky, the current output format for this probably isn't adequate. Currently there are just a list of urls that are in the agencies.yml file and a list that is in either feed. I could extend this by adding an "in_transitfeeds" and "in_transitland", but whoever consumes this would need to re-organize the data.

{
    "domain.com": {
        "in_yml": ["/path1", "/path3", ...],
        "in_feeds": ["/path1", "/path2"...],
        "in_transitland": ["/path1"], // proposed
        "in_transitfeeds" ["/path1", "/path3"], // proposed
    },
    ....
}

I don't know who the target audience is for this but if I had to guess I'd do something like this. Is this better?

{
    "domains.com": {
         "/path1": {
            "in_yml": true,
            "in_transitland": true,
            "in_transitfeeds": true,
            "in_feeds": true, // inclusive or of previous two rows (in_transitland || in_transitfeeds)
            "missing": false, // in_yml && !in_feeds
        },
        "path2: {...}
    },
    ...
}

The URL itself is a fine base analysis point, so something like this could work:

{
  url: {
    transitland: {
      status: missing | present,
      public_web_url: transit.land/feed/blah
    },
    transitfeeds: {
      status: missing | present,
      public_web_url: transit.land/feed/blah
    }
  }
}

If using the calitp agencies.yml, please add ITP ID and URL number:

{
  url: {
    itp_id: ##,
    url_number: ##,
    url_type: gtfs | gtfs_rt_*,
    transitland: {
      status: missing | present,
      public_web_url: transit.land/feed/blah
    },
    transitfeeds: {
      status: missing | present,
      public_web_url: transit.land/feed/blah
    }
  }
}