Skip to content

Trying to run the instructions.ipynb got this error : XMLSyntaxError: Document is empty, line 1, column 1 (, line 1)  #6

@parth-jr

Description

@parth-jr
XMLSyntaxError                            Traceback (most recent call last)
[.\slicemypdf.py](.\slicemypdf.py) in _get_token_coordinates(self, draw_img, entry)
    538             parser = etree.XMLParser(recover=True)
--> 539             xml_doc = etree.fromstring(xml_doc, parser=parser)
    540 

src/lxml/etree.pyx in lxml.etree.fromstring()

src/lxml/parser.pxi in lxml.etree._parseMemoryDocument()

src/lxml/parser.pxi in lxml.etree._parseDoc()

src/lxml/parser.pxi in lxml.etree._BaseParser._parseUnicodeDoc()

src/lxml/parser.pxi in lxml.etree._ParserContext._handleParseResultDoc()

src/lxml/parser.pxi in lxml.etree._handleParseResult()

src/lxml/parser.pxi in lxml.etree._raiseParseError()

XMLSyntaxError: Document is empty, line 1, column 1 (, line 1)

During handling of the above exception, another exception occurred:
...
--> 879             raise Exception("Unable to locate coordinates for text! Provide a valid path to a text-based PDF with a single table")
    880         return coordinate_table, vertical_distance_list,\
    881             horizontal_distance_list, img, original

Exception: Unable to locate coordinates for text! Provide a valid path to a text-based PDF with a single table.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions