Repository navigation
Serve the h5p-author skill, with a page of its files' full addresses - #16
Merged
Merged
Conversation
/h5p/skill/ serves SKILL.md, its licence and references/ as the pinned h5p-author 0.9.0 carries them, for a chat that cannot install the skill and is refused by GitHub's per-address limit. The page writes out every file's full address, as a chat's fetch tool may open only addresses it has seen whole. The preview server answers a missing file with a 404, as GitHub Pages does, so the tests that a file is served mean it. Closes #15
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #15.
/h5p/skill/serves the h5p-author skill as the pinned@missing-elements/h5p-author0.9.0 carries it, for a chat that cannot install the skill and is refused by GitHub's per-address limit ("I couldn't access the GitHub SKILL.md file due to rate limiting").SKILL.md,LICENSEandreferences/(the brief and 32 type files), copied as they are byeleventy.config.js.src/h5p/skill/index.njkwrites out the full address of every file, each as its link's text, since a chat's fetch tool may open only addresses it has seen whole. The link to give a chat ishttps://missing-elements.github.io/h5p/skill/.index.json: the author's version and the files, fromsrc/_data/skill.js, which stops the build if the pinned package carries noSKILL.md.appType: 'mpa':vite previewanswered every missing file with the home page and a 200, so a test that a file is served passed when it was not. It now gives a 404, as GitHub Pages does. The existing tests all pass under it.Tests
e2e/skill.spec.ts, 3 tests: the page lists every file the package carries, each address as its link's text,SKILL.mdfirst, andindex.jsonagrees; each file is served byte-equal to the package's; every addressSKILL.mdgives resolves here, both its relative links and its addresses on this site, with<Type>filled in. The whole suite passes from a clean build, 15 of 15.Six mutations, each caught: dropping the copy of
LICENSEorreferences/, a link's text not the whole address, the type files not listed,LICENSEmissing fromfiles,SKILL.mdnot first. BeforeappType: 'mpa', the two copy mutations failed one test each, not two.The page at 375 px and 1100 px, light and dark: no horizontal scroll, no console errors.
Summary by cubic
Serves the h5p-author skill at
/h5p/skill/for a chat that cannot install it, since GitHub's per-address rate limit refused the SKILL.md file. The page lists every file's full address, because a chat's fetch tool may only open addresses it has seen whole.SKILL.md,LICENSE, andreferences/from the pinned@missing-elements/h5p-authorpackage as-is.@missing-elements/h5p-authorfrom 0.8.0 to 0.9.0, the first version that carriesSKILL.md; the build page's type files and bundles move with it.appType: 'mpa'to the Vite config sovite previewreturns a 404 for missing files, as GitHub Pages does, instead of the home page with a 200.Written for commit 0890f91. Summary will update on new commits.