You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 8, 2018. It is now read-only.
I have been studying the code and noticed that signup and profile apps have empty urls.py files and these have been referenced in the main urls.py file of infohub. I have following concerns:
These should not be empty as these should reference to the views of its own views leading to increase in code reusability.
In case these are empty, these should not be included or at least be commented out as it leads to open branches in code structure, hence decreasing code quality.
The text was updated successfully, but these errors were encountered:
The standard code structure requires urls.py to be present in every app of Django. If that was the case, there are many unused models.py there as well. But they're mostly not removed, as I've seen in other Django projects.
@mish24 What I am trying to say is that, the purpose of having urls.py file is to map the urls to the view functions. If we have defined an app in django and there are functions in the views.py, these should be mapped via the urls of that app(in this case profile and signup app) to be able to reuse that app. Also, models and urls are different stories as models have the code for tables in the database and if we don't need to create tables for a app, it makes sense to leave it empty.
I have been studying the code and noticed that signup and profile apps have empty urls.py files and these have been referenced in the main urls.py file of infohub. I have following concerns:
The text was updated successfully, but these errors were encountered: