1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Anuncie Aqui
    Anuncie aqui você Também: fdantas@4each.com.br

[Python] Pyinstaller, exe file does not run for other users

Discussão em 'Python' iniciado por Stack, Setembro 14, 2025.

  1. Stack

    Stack Membro Participativo

    I have a problem with Pyinstaller, when I build the program everything works fine, but when I publish files on github or archive.org and download from there, when I try to run it, an error

    Traceback (most recent call last):
    File "my_app.py", line 28, in <module>
    webview.start(gui="edgechromium", debug=False)
    File "webview\__init__.py", line 174, in start
    File "webview\guilib.py", line 134, in initialize
    File "webview\guilib.py", line 83, in try_import
    File "webview\guilib.py", line 72, in import_winforms
    File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
    File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
    File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
    File "PyInstaller\loader\pyimod02_importers.py", line 499, in exec_module
    File "webview\platforms\winforms.py", line 13, in <module>
    File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
    File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
    File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
    File "PyInstaller\loader\pyimod02_importers.py", line 499, in exec_module
    File "clr.py", line 6, in <module>
    File "pythonnet\__init__.py", line 143, in load
    File "clr_loader\types.py", line 94, in get_function
    File "clr_loader\types.py", line 58, in __init__
    File "clr_loader\netfx.py", line 47, in _get_callable
    RuntimeError: Failed to resolve Python.Runtime.Loader.Initialize from C:\Users\[USERNAME]\Downloads\application_folder\pythonnet\runtime\Python.Runtime.dll


    my code:

    import os
    import sys
    import webview
    from pathlib import Path

    HERE = Path(__file__).resolve().parent
    INDEX = HERE / "launcher" / "index.html"
    if not INDEX.exists():
    raise FileNotFoundError(
    f"{INDEX} not found."
    )

    url = INDEX.as_uri()

    os.environ["WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS"] = \
    "--autoplay-policy=no-user-gesture-required"

    window = webview.create_window(
    title="ChickenFine",
    url=url,
    fullscreen=True,
    frameless=True,
    resizable=True,
    confirm_close=False
    )

    # edgechromium
    webview.start(gui="edgechromium", debug=False)


    I don't know what to do with this Can you tell me what the problem is?

    Continue reading...

Compartilhe esta Página