Expand description
Upstream docs: many packages ship no documentation (Next.js, Django,
FastAPI…). Their repositories do, under the exact version’s git tag.
This module finds the repository from the package’s own metadata, finds
the tag for the pinned version, and downloads only the docs folders
(Markdown, MDX, reStructuredText) from GitHub into the cache, once.
First-use queries fetch public docs at an immutable release commit. Explicit
fetch also supports major-version docs sites and optional GitHub credentials.
Structs§
Constants§
- FORMAT
- Bump when what
fetchdownloads changes, solockdocs fetchrefreshes older copies (a stale copy is still used until then).
Functions§
- cached
- A previous fetch (with or without files). Never touches the network.
- dir
- downloaded_
bytes - Compressed archive bytes downloaded by this process so far.
- fetch
- Download the docs folders of
dep’s repository at the pinned version’s tag. - fetch_
automatic - Anonymous, bounded first-use enrichment; never substitutes a major docs site.
- needs_
refresh - A prior explicit enrichment is also usable by automatic and offline queries.
- parse_
github - Parse a GitHub URL or shorthand into owner/name.
- repo_of
- The package’s source repository, from its own metadata.
- stale
- Was this copy made by an older lockdocs that downloaded less?
- tag_
candidates - Tag names projects use for a release.