tudelft3d / ifcgref

MIT License
17 stars 1 forks source link

FileNotFoundError: [Errno 2] No such file or directory: '/work/ifcgref/envelop/EnvNew.exe' #1

Closed nataschake closed 7 months ago

nataschake commented 8 months ago

Hi! I followed the instruction in the README and have done pip install Flask ifcopenshell pyproj pint numpy scipy pandas shapely successfully. Then cloned repo, and run as recommended python app.py. The Flask did not started, with the traceback:


<_io.TextIOWrapper name='envelop/00.json' mode='w+' encoding='UTF-8'>
<_io.TextIOWrapper name='envelop/00.json' mode='w+' encoding='UTF-8'>
Traceback (most recent call last):
  File "/home/nata/work/ifcgref/app.py", line 1, in <module>
    from flask import Flask, render_template, request, redirect, url_for, session, make_response # Import the redirect function
  File "/home/nata/.local/lib/python3.10/site-packages/flask/__init__.py", line 5, in <module>
    from . import json as json
  File "/home/nata/.local/lib/python3.10/site-packages/flask/json/__init__.py", line 6, in <module>
    from ..globals import current_app
  File "/home/nata/.local/lib/python3.10/site-packages/flask/globals.py", line 6, in <module>
    from werkzeug.local import LocalProxy
  File "/home/nata/.local/lib/python3.10/site-packages/werkzeug/__init__.py", line 5, in <module>
    from .serving import run_simple as run_simple
  File "/home/nata/.local/lib/python3.10/site-packages/werkzeug/serving.py", line 27, in <module>
    from http.server import BaseHTTPRequestHandler
  File "/usr/lib/python3.10/http/server.py", line 94, in <module>
    import http.client
  File "/usr/lib/python3.10/http/client.py", line 72, in <module>
    import email.message
  File "/usr/lib/python3.10/email/message.py", line 10, in <module>
    import uu
  File "/home/nata/work/ifcgref/uu.py", line 42, in <module>
    result = subprocess.Popen([path1 , path2])
  File "/usr/lib/python3.10/subprocess.py", line 971, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.10/subprocess.py", line 1863, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/nata/work/ifcgref/envelop/EnvNew.exe'
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 72, in apport_excepthook
    from apport.fileutils import likely_packaged, get_recent_crashes
  File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in <module>
    from apport.report import Report
  File "/usr/lib/python3/dist-packages/apport/report.py", line 21, in <module>
    from urllib.request import urlopen
  File "/usr/lib/python3.10/urllib/request.py", line 88, in <module>
    import http.client
  File "/usr/lib/python3.10/http/client.py", line 72, in <module>
    import email.message
  File "/usr/lib/python3.10/email/message.py", line 10, in <module>
    import uu
  File "/home/nata/work/ifcgref/uu.py", line 42, in <module>
    result = subprocess.Popen([path1 , path2])
  File "/usr/lib/python3.10/subprocess.py", line 971, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.10/subprocess.py", line 1863, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/nata/work/ifcgref/envelop/EnvNew.exe'

Original exception was:
Traceback (most recent call last):
  File "/home/nata/work/ifcgref/app.py", line 1, in <module>
    from flask import Flask, render_template, request, redirect, url_for, session, make_response # Import the redirect function
  File "/home/nata/.local/lib/python3.10/site-packages/flask/__init__.py", line 5, in <module>
    from . import json as json
  File "/home/nata/.local/lib/python3.10/site-packages/flask/json/__init__.py", line 6, in <module>
    from ..globals import current_app
  File "/home/nata/.local/lib/python3.10/site-packages/flask/globals.py", line 6, in <module>
    from werkzeug.local import LocalProxy
  File "/home/nata/.local/lib/python3.10/site-packages/werkzeug/__init__.py", line 5, in <module>
    from .serving import run_simple as run_simple
  File "/home/nata/.local/lib/python3.10/site-packages/werkzeug/serving.py", line 27, in <module>
    from http.server import BaseHTTPRequestHandler
  File "/usr/lib/python3.10/http/server.py", line 94, in <module>
    import http.client
  File "/usr/lib/python3.10/http/client.py", line 72, in <module>
    import email.message
  File "/usr/lib/python3.10/email/message.py", line 10, in <module>
    import uu
  File "/home/nata/work/ifcgref/uu.py", line 42, in <module>
    result = subprocess.Popen([path1 , path2])
  File "/usr/lib/python3.10/subprocess.py", line 971, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.10/subprocess.py", line 1863, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/nata/work/ifcgref/envelop/EnvNew.exe'
```.
Indeed, EnvNes.exe is not present in `ifcgref/envelop/`, only
`00.json  Env01.exe  Env02.exe  Env03.exe  Env04.exe`
Python = 3.10.12, OS Ubuntu Jammy 22.04 LTS 
amiroo4 commented 7 months ago

Hi! Thanks for submitting the issue. Apparently, your flask was directing to another files. The file has been deleted now. You can either try the process again or try https://ifcgref.bk.tudelft.nl/ for using the tool.

nataschake commented 7 months ago

@amiroo4 Thanks, it now runs and converts the CRS, as expected.