Most document-conversion bugs are not engine bugs. They are layout bugs wearing an engine costume.
I build small converters for office files, mostly Arabic and English ones, and the same three failures come up again and again: a bank statement whose table spans two pages with a repeated header, an attendance export where the night shift's out-punch lands on the next calendar day, and a right-to-left table where the number column silently reverses.
The bank statement case
A PDF statement looks like a table to a human and like a stream of positioned glyphs to a parser. Two things go wrong:
- Column inference by x-coordinate. Statements often have two date columns (value date and posting date) that are close together, so a naive x-clustering merges them into one, and every row after that is shifted by one column.
- Header repetition. The header row repeats on every page. If you treat every repeated header as data, you get rows that look like transactions and are not.
The fix that has held up for me: detect the header row once, key columns by their text rather than their position, and treat any later row that matches the header text within tolerance as a page break, not a transaction.
The attendance case
Punch logs are worse than they look, because the errors are not formatting errors, they are semantic ones:
- Duplicate punches seconds apart (a finger read twice) inflate the punch count.
- A missing punch turns a day into either zero hours or twelve hours depending on how you pair.
- A night shift puts the out-punch on the next calendar day, so any grouping by date splits one shift into two days.
Pairing the first and last punch inside a shift window, and flagging odd punch counts for a human instead of guessing, gets you most of the way. Rounding is a policy decision, not a parsing one, so keep it separate from the parser.
Why browser tools for this
The tuning per document type is the whole job, and tuning is much cheaper to ship as a web page than as an installer. The converters run client-side, so the file never leaves the machine.
If you want the long walkthroughs with screenshots of each step:
The free browser tools are at MuraTools, and the Windows tools that do the same thing offline are at murabyte.gumroad.com.
Murabyte, Egypt.

