tappi287 / usdzconvert_webui

Web interface to convert 3d content to usdz format
MIT License
31 stars 3 forks source link

OSError: [WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions #5

Open antekj opened 4 years ago

antekj commented 4 years ago

Hi, I am trying to run the program as you've explained in the previous issue ("C:\Program Files\usdz_webui\Python\python.exe" "C:\Program Files\usdz_webui\usdz_webui.launch.py" in command prompt) but after installing all the dependencies successfully, I get the error mentioned above. Here are all the messages from the command prompt:

C:\WINDOWS\system32>"C:\Program Files\usdz_webui\Python\python.exe" "C:\Program Files\usdz_webui\usdz_webui.launch.py" 18:30 INFO: USDZ Converter located or installed successfully. C:\Users\antoni\AppData\Local\usdzconvert_webui\instance\converter\pxr_usd_abc1710_py27_win64 18:30 INFO: Providing module with logger: usdz_webui.modules.ftp 18:30 INFO: Providing module with logger: usdz_webui.modules.settings 18:30 INFO: Providing module with logger: usdz_webui.modules.file_mgr 18:30 INFO: Providing module with logger: usdz_webui.modules.usdzconvert_args 18:30 INFO: Providing module with logger: usdz_webui.modules.job Logging setup called: app.py Logging setup detected production env. File handler will be used. Removing handler that will be added to queue listener: <RotatingFileHandler C:\Users\antoni\AppData\Local\usdzconvert_webui\Logs\usdzconvert_webui.log (DEBUG)> Removing handler that will be added to queue listener: <StreamHandler (NOTSET)> 21.08.2020 18:30 usdz_webui INFO: Started Log listener in thread: 16804 21.08.2020 18:30 root INFO: Serving at 192.168.0.24 Traceback (most recent call last): File "C:\Program Files\usdz_webui\usdz_webui.launch.py", line 35, in serve_to_lan() File "C:\Program Files\usdz_webui\pkgs\serve.py", line 16, in serve_to_lan serve(App, host=host, port=port) File "C:\Program Files\usdz_webui\pkgs\waitress__init__.py", line 12, in serve server = _server(app, **kw) File "C:\Program Files\usdz_webui\pkgs\waitress\server.py", line 81, in create_server last_serv = TcpWSGIServer( File "C:\Program Files\usdz_webui\pkgs\waitress\server.py", line 239, in init self.bind_server_socket() File "C:\Program Files\usdz_webui\pkgs\waitress\server.py", line 368, in bind_server_socket self.bind(sockaddr) File "C:\Program Files\usdz_webui\pkgs\waitress\wasyncore.py", line 398, in bind return self.socket.bind(addr) OSError: [WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions

Any help would be much appreciated!

tappi287 commented 4 years ago

Hi, thanks for providing the error messages. The waitress module couldn't open your local port 5000 which either means:

If this port is really already in use on your machine: try to edit the file serve.py in the usdz_webui/pkgs directory in Line 13 port=5000 and change the port to something between 1024 - 50000

antekj commented 4 years ago

Hi, thank you so much, I really appreciate your help!

eoffermann commented 2 years ago

@tappi287 - Thanks to this:

    if sys.platform == 'win32':
        host = socket.gethostbyname(socket.gethostname())   
        port = 80

running this on windows forces the port to 80 (regardless of how it's set at the top) which is a little bonkers (especially since it's assigned to something more sensible - port 5000 - initially).

The chance that another service is bound to 80 is fairly high. In my case the domain resolution doesn't work that well either, but that's probably unique to my situation. I don't get forcing the port to 80 on Windows, though.