Skip to content

Unable to use pyinstaller to package - always informed module doesnt exist "darkdetect" #2779

@CesparRes

Description

@CesparRes

I've thrown my self at this for quite some time today - I've followed the docs page about using --onedir and --add-data

The command line I'm currently running:
pyinstaller --onedir --windowed --hidden-import=pkg_resources.extern --hidden-import=darkdetect --hidden-import distutils --add-data "e:/python stuff/site stuff/simply book/.venv/lib/site-packages/customtkinter;customtkinter/" bookings_tool_themed.py

Upon attempting to run the exe - i'm told that darkdetect module is not found.

Everything is running within the .venv and I've even manually tried installing darkdetect but pip tells me it's already installed (I guess as part of customtkinter package).

I've only discovered customtkinter today so it's a fresh install with (I assume) the latest version (5.2.2).

I've been using pyinstaller for a while but usually hidden imports solves things - so not totally sure why darkdetect is not being found, despite clearly being in the env, and even hidden imported.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions