Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

import error when using git version and python3.5 #24

Open
thengineer opened this issue Nov 20, 2015 · 5 comments
Open

import error when using git version and python3.5 #24

thengineer opened this issue Nov 20, 2015 · 5 comments

Comments

@thengineer
Copy link

I have installed the git version using the setup script, and when trying to import slate i get the following error:

 >>> import slate
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.5/site-packages/slate-0.5.1-py3.5.egg/slate/__init__.py", line 66, in <module>
  File "/usr/local/lib/python3.5/site-packages/slate-0.5.1-py3.5.egg/slate/classes.py", line 25, in <module>
ImportError: No module named 'utils'
@pchaigno
Copy link

I have the same issue.
Slate is expecting to find utils.py in the current directory, which obviously isn't there.

Steps to reproduce:

pip3 install pdfminer3k
pip3 install git+https://github.com/timClicks/slate
python3 pdftotext.py /some/pdf/file.pdf

with pdftotext.py being:

import slate
import sys

if __name__ == "__main__":
    filepath = sys.argv[1]
    with open(filepath) as f:
        doc = slate.PDF(f)
        print(doc)

@wearpants
Copy link

Can this get merged please?

@benjaminweb
Copy link

It shouldn't if PR #32 turns out to do the same and more (untested). Read that chronology.

@arderyp
Copy link

arderyp commented Mar 2, 2019

this error persists, over 3 years later. I guess its impossible to run slate on python 3?

@juicedatom
Copy link

juicedatom commented Jul 21, 2020

+1 on the above. I was able to manually patch with the above fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants