markitdown icon indicating copy to clipboard operation
markitdown copied to clipboard

can't import markitdown

Open echo0218 opened this issue 1 year ago • 6 comments

I install markitdown in Anaconda using 'pip install markitdown',but can't import markitdown in python, the code is: from markitdown import MarkItDown

the Errorinfo is: cannot import name 'MarkItDown' from 'markitdown' (c:\Users\echo\anaconda3\lib\site-packages\markitdown_init_.py) File "C:\Practice\python\test_markitdown.py", line 6, in from markitdown import MarkItDown ImportError: cannot import name 'MarkItDown' from 'markitdown' (c:\Users\echo\anaconda3\lib\site-packages\markitdown_init_.py)

echo0218 avatar Dec 18 '24 01:12 echo0218

Using pip install makritdown, get .....

__about__.py
__init__.py

so, I can't get MarkItDown from markitdown! look this: Image

YiLan96 avatar Dec 18 '24 03:12 YiLan96

Update to the latest version? The latest version is 0.0.1a3

pip install -U markitdown

Soulter avatar Dec 18 '24 04:12 Soulter

Did the solution above work to fix your issue? @echo0218

kevinclb avatar Dec 18 '24 07:12 kevinclb

This worked for me pip install -U markitdown.

cheorges avatar Dec 18 '24 16:12 cheorges

Just got the same error when trying out. For those who are using python 3.8 or 3.9, note that the latest version requires py>=3.10. After switching to py 3.11 and installing the a3 version, issue is gone.

nobodxbodon avatar Dec 20 '24 06:12 nobodxbodon

I encountered the same issue, and upgrading Python and reinstalling the package solved it for me.

pip install -U markitdown
pyenv install 3.11
pyenv global 3.11

hitripod avatar Jan 21 '25 07:01 hitripod