Python Forum
How do I install the dom.minidom module?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How do I install the dom.minidom module?
#1
I am using SUSE Linux. I ran this:
sudo pip install py-xml

I am trying to debug a Python program. I run this command from a Python prompt:

>>> from xml.dom.minidom import parse

I see this:

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named dom.minidom


I ran this: sudo zypper -n install python-libxml2

I tried cloning https://github.com/JeremyDemers/py-xml. I ran python setup.py build and python setup.py install. I do not know how to get the dom.minidom module installed. How do I get it installed so that I may use >>> from xml.dom.minidom import parse

I am able to use that Python interpreter command on non-SUSE servers.
Reply
#2
Quote:Python.org Warning
The xml.dom.minidom module is not secure against maliciously constructed data. If you need to parse untrusted or unauthenticated data see XML vulnerabilities.

usage: https://docs.python.org/3.8/library/xml....nidom.html
this is not in package py-xml, so remove import
Reply
#3
For my own situation I cannot remove the "import parse". The link you sent has the "import parse" statement. I see "from xml.dom.minidom import parse, parseString"
Reply
#4
not that one, the xml one.
look at the links provided
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Can't install nor import delorean module Tek 3 2,741 Oct-27-2021, 03:32 AM
Last Post: Tek
  Unable to install module rrowhe4d 1 2,252 Oct-13-2020, 10:20 AM
Last Post: Larz60+
  trying to pip install stasm module getting error djf123 3 4,454 Jul-26-2020, 05:00 AM
Last Post: millpond
  Install thresding module kalvarix 2 2,144 May-04-2020, 03:25 PM
Last Post: kalvarix
  Install module with pip3 on a non root user matthewpintor2107 1 2,348 Apr-28-2020, 03:16 PM
Last Post: pyzyx3qwerty
  Install module without "pip" hjk6734 2 10,882 Apr-09-2020, 09:09 AM
Last Post: buran
  how to import a module which is installed to personal folder using pip install --pre? geekgeek 2 2,372 Mar-09-2020, 02:38 PM
Last Post: geekgeek
  Can a module be executed even if the computer running it does not install it? CFYB 5 3,344 Feb-08-2020, 01:56 PM
Last Post: snippsat
  Cannot pip install py-xml module kump 3 6,921 Jul-23-2019, 02:42 PM
Last Post: snippsat
  I get this when trying to install a module - SyntaxError: invalid syntax ? ejected 2 3,281 Mar-25-2019, 07:53 PM
Last Post: ejected

Forum Jump:

User Panel Messages

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