Issue with google bucket

30 views
Skip to first unread message

Jason Sill

unread,
Jun 7, 2024, 7:36:27 AMJun 7
to OpenAIP - Aviation Data Platform
I have been using the following link to get access all the JSON files for airports for all the countries in the world.


Last week, it was working fine but when running it today, it seems to only get to the tc_apt.json file and doesn't list the rest after that

webmaster

unread,
Jun 7, 2024, 7:39:16 AMJun 7
to OpenAIP - Aviation Data Platform
Hi Jason,

hm, from a first look: it works as expected. You also have a "nextPageToken" since, afair, the response is paginated whenever the max item count is reached that fits into a single response. Did you try to get the next page?

Cheers,

Stephan

Jason Sill

unread,
Jun 7, 2024, 11:12:16 AMJun 7
to OpenAIP - Aviation Data Platform
Well, that's the weird issue, last week with the same url, I was able to get a JSON file with 235 items and this week it only returns 205 items.  In both cases there was a nextPageToken which I will admit I never really paid attention to before

After doing some testing, that nextPageToken can appear even when the results only has like 13 items: https://storage.googleapis.com/storage/v1/b/29f98e10-a489-4c82-ae5e-489dbcd4912f/o?delimiter=%2F&matchGlob=[r-z]*apt\.json

I think I must have been just lucky that previously the call returned all the countries in the first page while now it won't and I need to figure out how to use the nextPageToken.

webmaster

unread,
Jun 7, 2024, 11:18:08 AMJun 7
to OpenAIP - Aviation Data Platform
See https://cloud.google.com/storage/docs/json_api/v1/buckets/list which, to some extend, also applies to the simple build/guess URLs.

As per API docs, max items per page defaults to 200. Although I suppose thats a soft limit and may differ in small numbers.... But not sure.
Reply all
Reply to author
Forward
0 new messages