Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error occurred loading flow for integration moonraker: No module named 'moonraker_api' #423

Open
broizter opened this issue Oct 10, 2024 · 9 comments
Labels

Comments

@broizter
Copy link

broizter commented Oct 10, 2024

Edit: This is an upstream issue. A workaround for now is setting the environment variable PYTHONPATH to "/config/deps".

When adding the component I get the error message {"message":"Invalid handler specified"} and the logs show me Error occurred loading flow for integration moonraker: No module named 'moonraker_api'.

I tried restarting, reinstalling and restarting again with no luck.

@marcolivierarsenault
Copy link
Owner

mm looks like it's not installing properly, can you share the logs and do a reinstall. Please include debug logs for when you book Home Assistant

@broizter
Copy link
Author

How do I enable debug logs?

@marcolivierarsenault
Copy link
Owner

@broizter
Copy link
Author

That documentation doesn't explain how to enable debug logs.

@broizter
Copy link
Author

broizter commented Oct 12, 2024

The correct documentation was found at https://www.home-assistant.io/integrations/logger/
Install log:

2024-10-12 18:16:40.153 INFO (MainThread) [custom_components.hacs] Starting download, 1.3.7
2024-10-12 18:16:40.154 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Running pre installation steps
2024-10-12 18:16:40.154 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Pre installation steps completed
2024-10-12 18:16:40.154 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Running installation steps
2024-10-12 18:16:40.154 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Getting repository information
2024-10-12 18:16:40.442 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Did not update, content was not modified
2024-10-12 18:16:40.443 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Local path is set to /config/custom_components/moonraker
2024-10-12 18:16:40.443 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Remote path is set to custom_components/moonraker
2024-10-12 18:16:40.443 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Version to install: 1.3.7
2024-10-12 18:16:40.443 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Downloading repository archive
2024-10-12 18:16:40.443 DEBUG (MainThread) [custom_components.hacs] Trying to download https://github.com/marcolivierarsenault/moonraker-home-assistant/archive/refs/tags/1.3.7.zip
2024-10-12 18:16:41.212 DEBUG (SyncWorker_8) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Cleaning up /tmp/tmp3y763fls
2024-10-12 18:16:41.213 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Content was extracted to /config/custom_components/moonraker
2024-10-12 18:16:41.214 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Installation steps completed
2024-10-12 18:16:41.214 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Running post installation steps
2024-10-12 18:16:41.214 INFO (MainThread) [custom_components.hacs] Reloading custom_component cache
2024-10-12 18:16:41.217 INFO (SyncWorker_4) [homeassistant.loader] Loaded switch_manager from custom_components.switch_manager
2024-10-12 18:16:41.217 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration switch_manager which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-10-12 18:16:41.218 INFO (SyncWorker_4) [homeassistant.loader] Loaded moonraker from custom_components.moonraker
2024-10-12 18:16:41.218 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration moonraker which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-10-12 18:16:41.219 INFO (SyncWorker_4) [homeassistant.loader] Loaded adaptive_lighting from custom_components.adaptive_lighting
2024-10-12 18:16:41.219 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration adaptive_lighting which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-10-12 18:16:41.220 INFO (SyncWorker_4) [homeassistant.loader] Loaded hacs from custom_components.hacs
2024-10-12 18:16:41.220 WARNING (SyncWorker_4) [homeassistant.loader] We found a custom integration hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-10-12 18:16:41.221 INFO (MainThread) [custom_components.hacs] Custom_component cache reloaded
2024-10-12 18:16:41.221 DEBUG (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Creating restart_required issue
2024-10-12 18:16:41.221 INFO (MainThread) [custom_components.hacs] <Integration marcolivierarsenault/moonraker-home-assistant> Post installation steps completed
2024-10-12 18:16:41.223 INFO (MainThread) [homeassistant.components.update] Setting up hacs.update
2024-10-12 18:16:41.229 INFO (MainThread) [homeassistant.helpers.entity_registry] Registered new update.hacs entity: update.moonraker_update
2024-10-12 18:16:41.230 DEBUG (MainThread) [custom_components.hacs] <HacsData async_write> Saving data

Adding the component:

2024-10-12 18:17:36.911 INFO (SyncWorker_23) [homeassistant.util.package] Attempting install of moonraker-api==2.0.6
2024-10-12 18:17:37.729 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration moonraker: No module named 'moonraker_api'

@broizter
Copy link
Author

bild

The module gets installed but doesn't seem to be detected.

@marcolivierarsenault
Copy link
Owner

mm, not sure how to help here, this looks to be a Home Assistant specific issue.
The integration don't control how to libs gets loaded and installed.

@jdobes
Copy link

jdobes commented Nov 17, 2024

I have the same problem, trying to setup this integration for the first time.

Home Assistant 2024.11.2
HACS 2.0.1

EDIT: Seems to be this issue - home-assistant/core#127966

@broizter
Copy link
Author

That's a great find! So the issue is actually upstream. A workaround for now is setting the environment variable PYTHONPATH to "/config/deps".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants