Skip to content

Conversation

jarofgreen
Copy link
Contributor

No description provided.

@jarofgreen jarofgreen self-assigned this Jul 8, 2025
…dividual data records

This means we can get all the dataset fields datatig has,
previously we could only get fields in list_fields in the datatig config
"country": value["fields"]["country"]["value"],
registered_datasets = {}
for key, value in json_data["records"].items():
r_data = requests.get(value["api_url"])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how big json_data["records"] is but that could be a very large number of requests all at once? Has needing some kind of control on that been considered?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's only ~10 records and isn't expected to grow fast, and we have control over the API.

If it gets bigger the thing to do is look into methods where we can get all the data with one API call - currently the API does allow that (there's a sqlite with all the data in it) but it would be more changes, and this will do for now.

Copy link
Member

@michaelwood michaelwood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved - One comment to possibly consider

@jarofgreen jarofgreen merged commit 2aa9fa2 into main Jul 22, 2025
1 check passed
@jarofgreen jarofgreen deleted the portals branch July 22, 2025 07:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants