# Document Marked With an Error

A document drawn with a **red border** contains at least one error the parser recorded while reading
your byte stream. The rest of the document still renders; the border marks that something in it did
not add up.

## Reading the error

- A **warning triangle** appears next to the document. Hover it to see the error text.
- Or switch on **Raw Data** for that document to see the byte stream alongside the parsed elements,
  with the failure in place. This is the faster route when you need to know *where* in the receipt it
  went wrong rather than just what happened.

Most messages are self-explanatory: an argument outside the range the command allows, a length that
does not match the data that followed, a command cut short by the connection closing mid-sequence.

## When it is your byte stream

Common causes, in order:

- **A truncated job.** The connection closed in the middle of a command. Usually an application that
  times out or exits without flushing.
- **An out-of-range argument.** For example a colour byte where the command only allows 0/48 and 1/49.
- **Wrong protocol.** EPL sent to an ESC/POS printer produces a document full of errors rather than a
  label. See [Printer protocols](/docs/protocols).

## When it is us

The parser may also flag a command it does not implement yet. ESC/POS is large, vendors extend it, and
some sequences are undocumented - so an error does not automatically mean your client is wrong.

If the command looks correct against the specification, **write to
[support@virtual-printer.online](mailto:support@virtual-printer.online)** with the document and the
bytes. Adding a command is usually quick, and a real byte stream from the field is exactly what makes
that possible.
