Documentation

Type defined in library builtins

ModuleNotFoundError

Python raises a module not found error when it cannot find the library (i.e., the module) mentioned in an import statement.

A module not found error is a special kind of import error.

Note that the text of the error message depends on the implementation. Different versions of Python and different checking tools will give slightly different messages.

Code
from pitamaro import rectangle
error
ModuleNotFoundError: No module named 'pitamaro'
Code
import maths
error
ModuleNotFoundError: No module named 'maths'

PyTamaro logo

PyTamaro is a project created by the Lugano Computing Education Research Lab at the Software Institute of USI

Privacy Policy • Platform Version c67fb165 (October 16, 2026 at 2:45:13 PM UTC)