raise Error on import
This commit is contained in:
parent
26eee37757
commit
77af2a4b46
1 changed files with 3 additions and 1 deletions
|
@ -381,10 +381,12 @@ def show_part_changer(ui_element: nicegui.ui.element, part: Part) -> None:
|
|||
|
||||
|
||||
|
||||
# if __name__ in {"__main__", "__mp_main__"}:
|
||||
nicegui.app.add_static_files('/images_landscape', 'images_landscape')
|
||||
ui.run(title="Fahrradteile",
|
||||
favicon="website_resources/favicon.ico",
|
||||
language="de",
|
||||
host=gl_options.host,
|
||||
port=gl_options.port)
|
||||
|
||||
if __name__ not in {"__main__", "__mp_main__"}:
|
||||
raise ImportError(f"{__name__} cannot be used as a module, just as a callable program.")
|
||||
|
|
Loading…
Reference in a new issue