Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
docx module alternatives
#1
I'm reading all of the text from a word document(docx).
Until upgrading to 3.8 the docx module has done a fine job, but today I ran into a compound issue.
Error:
import docx File "C:\Program Files\Python38\lib\site-packages\docx.py", line 30, in <module> from exceptions import PendingDeprecationWarning ModuleNotFoundError: No module named 'exceptions'
So, I have questions:
What is the most modern module for reading docx? Where can I find a good example of reading a word doc line by line?
Why would my 3.8 installation not have the exceptions module?

Ah, found it myself.
https://pypi.org/project/python-docx/ appears to be the answer.
Is this the best module to go with?
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  no module named 'docx' when importing docx MaartenRo 1 711 Dec-31-2023, 11:21 AM
Last Post: deanhystad
  Use module docx to get text from a file with a table Pedroski55 8 5,802 Aug-30-2022, 10:52 PM
Last Post: Pedroski55
  python-docx regex: replace any word in docx text Tmagpy 4 2,139 Jun-18-2022, 09:12 AM
Last Post: Tmagpy
  Eliminating error in Python update-alternatives Led_Zeppelin 2 2,942 Apr-14-2021, 12:49 PM
Last Post: Led_Zeppelin
  Selecting rows that contain certain values using two alternatives tgottsc1 1 1,551 Jan-24-2021, 08:34 PM
Last Post: nealc
  Are there any python alternatives for LuaMacros? NathanStanley 1 3,742 Apr-07-2020, 09:51 AM
Last Post: Larz60+
  Python 3.6 Alternatives to Cx_Freeze KipCarter 5 4,956 Jan-14-2020, 11:51 AM
Last Post: KipCarter

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020