Open jt4000 opened 6 years ago
After running into the same problem (using Pip 18.1 and installing with pip3 install pattern3
), it seems like the file pattern3/text/tree.py
on GitHub and the file on PyPI are different.
If you just replace tree.py
with the GitHub version, the IndentationError
goes away and you can import the package. (This doesn't guarantee the correctness of the package, however.)
In case anyone still have issue, you can run the command
sed -i '36s/.*/ pass/' /usr/local/lib/python3.6/dist-packages/pattern3/text/tree.py
I was using a dockerfile for the project so did the same, you can change it manually otherwise.
I'm using Anaconda and i retrieve this message "IndentationError: expected an indented block" when I apply this code "from pattern3.en import tag"