wsgidav icon indicating copy to clipboard operation
wsgidav copied to clipboard

Windows MSI installer error

Open lupohan44 opened this issue 2 years ago • 9 comments

Describe the bug Cannot run wsgidav with auth=nt

To Reproduce Steps to reproduce the behavior:

  1. Use MSI installer to install wsgidav on windows
  2. Execute wsgidav -p 16147 --host=0.0.0.0 --root=D:/ --auth=nt
  3. See error

Running without configuration file. 17:30:28.087 - ERROR : Dynamic import of 'wsgidav.dc.nt_dc.NTDomainController' failed: No module named 'win32net' Traceback (most recent call last): File "C:\prj\git\wsgidav.tox\bdist_msi\Lib\site-packages\cx_Freeze\initscripts_startup_.py", line 138, in run File "C:\prj\git\wsgidav.tox\bdist_msi\Lib\site-packages\cx_Freeze\initscripts\console.py", line 16, in run File "wsgidav\server\server_cli.py", line 841, in File "wsgidav\server\server_cli.py", line 803, in run File "C:\prj\git\wsgidav\wsgidav\wsgidav_app.py", line 247, in init File "C:\prj\git\wsgidav\wsgidav\http_authenticator.py", line 143, in init File "C:\prj\git\wsgidav\wsgidav\http_authenticator.py", line 108, in make_domain_controller File "C:\prj\git\wsgidav\wsgidav\util.py", line 530, in dynamic_import_class File "C:\Users\marti\AppData\Local\Programs\Python\Python39\lib\importlib_init_.py", line 127, in import_module File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 850, in exec_module File "", line 228, in _call_with_frames_removed File "C:\prj\git\wsgidav\wsgidav\dc\nt_dc.py", line 78, in ModuleNotFoundError: No module named 'win32net'

Expected behavior Run normally

Screenshots, Log-Files, Stacktrace

Running without configuration file.
17:30:28.087 - ERROR   : Dynamic import of 'wsgidav.dc.nt_dc.NTDomainController' failed: No module named 'win32net'
Traceback (most recent call last):
  File "C:\prj\git\wsgidav\.tox\bdist_msi\Lib\site-packages\cx_Freeze\initscripts\__startup__.py", line 138, in run
  File "C:\prj\git\wsgidav\.tox\bdist_msi\Lib\site-packages\cx_Freeze\initscripts\console.py", line 16, in run
  File "wsgidav\server\server_cli.py", line 841, in <module>
  File "wsgidav\server\server_cli.py", line 803, in run
  File "C:\prj\git\wsgidav\wsgidav\wsgidav_app.py", line 247, in __init__
  File "C:\prj\git\wsgidav\wsgidav\http_authenticator.py", line 143, in __init__
  File "C:\prj\git\wsgidav\wsgidav\http_authenticator.py", line 108, in make_domain_controller
  File "C:\prj\git\wsgidav\wsgidav\util.py", line 530, in dynamic_import_class
  File "C:\Users\marti\AppData\Local\Programs\Python\Python39\lib\importlib\__init__.py", line 127, in import_module
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "C:\prj\git\wsgidav\wsgidav\dc\nt_dc.py", line 78, in <module>
ModuleNotFoundError: No module named 'win32net'

If applicable, add screenshots to help explain your problem. If applicable, add a log file (consider --verbose).

Environment:

WsgiDAV/4.1.0 Python/3.9.9(64 bit) Windows-10-10.0.17763
Python from: C:\Users\Administrator\AppData\Local\Programs\WsgiDAV\wsgidav.exe

lupohan44 avatar Jan 18 '23 09:01 lupohan44

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Apr 19 '23 01:04 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jul 19 '23 02:07 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Oct 17 '23 20:10 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jan 16 '24 20:01 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Apr 16 '24 20:04 github-actions[bot]

Still fails with 4.3.2

mar10 avatar May 03 '24 15:05 mar10

Trying with Python 3.12, Pywin32 306, and cx_Freeze 7.0.0 I still get this error:

setup_bdist_msi.py already adds wsgidav.dc.nt_dc to the requirements and python setup_bdist_msi.py bdist_msi builds an exe folder that contains build\exe.win-amd64-3.12\lib\win32net.pyd.

Still, import win32net raises an ImportError.

mar10 avatar May 04 '24 18:05 mar10

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Aug 02 '24 20:08 github-actions[bot]

pip install pywin32 , work well.

Tlntin avatar Aug 09 '24 04:08 Tlntin