Closed Perevalov closed 3 years ago
Why is the list of components hardcoded? https://github.com/jayeshdesai4520/chatbot-ng-internal/blob/e2ee3d19f0cbdce65244485c3672faf15580cb8f/RDF-Visualization/app.py#L25
Hi, @Perevalov can you check the code I have fixed the issue.
First of all, get rid of global variable (it will not work for many users that use it simultaneously): https://github.com/jayeshdesai4520/chatbot-ng-internal/blob/e2ee3d19f0cbdce65244485c3672faf15580cb8f/RDF-Visualization/app.py#L16
Secondly, change naming of functions according to PEP8 : https://www.python.org/dev/peps/pep-0008/#naming-conventions
Finally, optimize the code e.g. remove things like this: https://github.com/jayeshdesai4520/chatbot-ng-internal/blob/e2ee3d19f0cbdce65244485c3672faf15580cb8f/RDF-Visualization/app.py#L63