Skip to content

Cannot catch KernelModuleLoadError #110

@ggstuart

Description

@ggstuart

Hi, I was trying to catch the KernelModuleLoadError and handle it.

from w1thermsensor.errors import KernelModuleLoadError

However, its not possible to import the exception without raising the error.

This seems to be because your __init__.py module calls the load_kernel_modules() method immediately.

So its not possible to get a reference to the error without raising it first.

Any ideas about how I could work around this? Or ways to rearrange things?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions