How to Solve NameError: name 'XML' is not defined -- xml

Solution: Import the 'XML' module

To Solve the error, add the following line to the top of your code.

from xml import XML

 

For more information:
Python xml XML