Skip to content
EPUBCheck · Resources and references

EPUBCheck RSC-014: fragment of the wrong type

Updated:

EPUBCheck RSC-014 is a usage message: “Fragment identifier defines an incompatible resource type.” A fragment identifier points to something of a different type than the reference expects. It is a usage message, shown only with -u, for example a link that should target an SVG element but resolves to another kind of resource.

The official message

Fragment identifier defines an incompatible resource type.

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

Typical causes

  • A fragment copied from another file that has an element with the same id but of another type.
  • A reference to an SVG fragment that actually points into an XHTML document, or the reverse.

How to fix it

  1. Read the reference EPUBCheck names and check what kind of element the #fragment resolves to.
  2. Point the reference at an element of the expected type, or at the right file.
  3. Validate again with -u to confirm.

When it's not this

If the fragment does not exist at all, the error is RSC-012.

Terms used here

Other RSC messages

  • RSC-013 Fragment identifier is used in a reference to a stylesheet resource.
  • RSC-015 A fragment identifier is required for svg use tag references.
  • RSC-012 Fragment identifier is not defined.
  • RSC-016 Fatal Error while parsing file: …
  • RSC-011 Found a reference to a resource that is not a spine item.
  • RSC-017 Warning while parsing file: …

Sources

Message text and severity from EPUBCheck 5.4.0 (W3C, BSD-3-Clause). Explanation by EpubCC.

FAQ

What does EPUBCheck RSC-014 mean?

EPUBCheck RSC-014 is a usage message: “Fragment identifier defines an incompatible resource type.” A fragment identifier points to something of a different type than the reference expects. It is a usage message, shown only with -u, for example a link that should target an SVG element but resolves to another kind of resource.

Is RSC-014 an error?

RSC-014 is reported as usage by default. Informative only and hidden by default: it appears when EPUBCheck runs with -u (--usage). It does not make the EPUB invalid.