Getting data from remote sources into the spec #1113
Labels
hint: active
Hint: Tasks currently in an active project
scope: tooling
Scope: web rendering, build system, CI and other tooling
type: enhancement
Type: New feature or improvement to an existing feature
There are a few places where we want data from remote sources to be included in the spec
For some cases like audits we are adding yaml frontmatter to markdown docs, which is simple enough, but requires manual maintenance.
For Code files we are using hugo modules, which is not ideal as it fetches the entire external repo into the spec working tree.
For CI status we pull it at build time via hugo data helpers... this is neat, but if the remote is unavailable the build will fail. It also means the info is only as fresh as the last build, but a cron job would be sufficient to solve that.
I suspect an api that aggregates the info we want to see in the sepc would be helpful... it can hide the complexity of extracting the data we want, and maintain a cache so it can return the last good result if any endpoint fails... we can also query it at build time, and for anything data that should be as fresh as possible we can also query it from the client.
This could just be a bunch of github actions that commit data files to the spec repo when something changes, or an app you run locally, or a hosted service (a cloudflare web worker or similar). A local app would be nice and hackable / upgradeable. A hosted service would mean authors don't have to think about providing github tokens or similar auth issues to get access to data to be scraped.
The situation right now is too spread out and requires too much knowledge, and is hard to include all the transformations we want.
TODO
The text was updated successfully, but these errors were encountered: