How do you solve "Unable to import 'cx_freeze'" - E0401:import-error?

1 week ago 5
ARTICLE AD BOX

I am using cx_freeze for the first time, and ran the quickstart command to begin working on the package. However, upon opening the setup file in VSCodium I received the error message:

Unable to import 'cx_freeze' Pylint(E0401:import-error)

I had not modified the setup file when the message first appeared. I've only found one similar post to this; however, it didn't have any definite fixes.

I'm on an M2 MacBook Air running MacOS 26.1, Python 3.14.2, cx_Freeze 8.5.3, and working in VSCodium 1.107.18605 using Pylint as a linter. The line causing the error message is below.

from cx_Freeze import setup, Executable
Read Entire Article