Closed dmtzs closed 2 years ago
We need to change the code about how we need to close the flask server. After that the issue will be closed. But its good to clarify that the problem and its respective solution its already identified.
I already change the way we close the flask server, this issue will still open until the next tests are executed.
Tests were executed with sucess, now this bug is fixed. Closing this issue.
At the moment we try to close the flask server when we run the electron app with the command npm start at the moment we close the electron app there is an error when we close the flask server. The error that appears is the next one and we should close it.
Traceback (most recent call last): File "C:\Users\Diego\AppData\Local\Programs\Python\Python38-32\lib\site-packages\flask\app.py", line 2070, in wsgi_app response = self.full_dispatch_request() File "C:\Users\Diego\AppData\Local\Programs\Python\Python38-32\lib\site-packages\flask\app.py", line 1515, in full_dispatch_request rv = self.handle_user_exception(e) File "C:\Users\Diego\AppData\Local\Programs\Python\Python38-32\lib\site-packages\flask\app.py", line 1513, in full_dispatch_request rv = self.dispatch_request() File "C:\Users\Diego\AppData\Local\Programs\Python\Python38-32\lib\site-packages\flask\app.py", line 1499, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args) File "main.py", line 263, in closeAll conn.closeConnection() File "C:\Users\Diego\Documents\ProyectoRaspArduino\resources\Flask\TerrariumLib\ArduinoConnection.py", line 89, in closeConnection self.connection.close() AttributeError: 'NoneType' object has no attribute 'close'