EPUBCheck RSC-006b: remote resource for a script
Updated:
EPUBCheck RSC-006b is a usage message: “Resource "…" is located outside the EPUB Container; please check the resource is retrieved in scripted content.” A resource is located outside the EPUB container, and EPUBCheck asks you to check that a script fetches it. It is a usage message, shown only with -u; resources retrieved through scripting APIs may legitimately be remote.
The official message
Resource "%1$s" is located outside the EPUB Container; please check the resource is retrieved in scripted content.
- Default severity
- Usage. Informative only and hidden by default: it appears when EPUBCheck runs with -u (--usage). It does not make the EPUB invalid.
- EPUBCheck version
- 5.4.0
%1$s, %2$s… are filled in with the file, value or element EPUBCheck found.
Typical causes
- A scripted document that loads data or media from a server.
- A remote reference in a place EPUBCheck cannot classify, such as markup a script uses.
How to fix it
- Confirm the resource really is fetched by a script; if so, nothing needs to change.
- If it is an image or stylesheet the page displays directly, move it into the EPUB, add it to the manifest and use a relative path.
- Remember that reading apps may run without network access, so the book should still work without it.
When it's not this
If the remote resource is used where EPUB forbids it, EPUBCheck reports the error RSC-006 instead.
Terms used here
Other RSC messages
RSC-006Remote resource reference is not allowed in this context; resource "…" must be located in the EPUB container.RSC-005Error while parsing file: …RSC-007Referenced resource "…" could not be found in the EPUB.RSC-004File "…" is encrypted, its content will not be checked.RSC-008Referenced resource "…" is not declared in the OPF manifest.RSC-003No rootfile tag with media type "application/oebps-package+xml" was found in the container.
Sources
- EPUB 3.3, §3.6 Resource locations · read
- EPUB 3.3, §6.3.2 Scripting · read
Message text and severity from EPUBCheck 5.4.0 (W3C, BSD-3-Clause). Explanation by EpubCC.