after deploying site on heroku ,it's showing Internal server error.
for debug I made "debug=true" and I found this error :
"ModuleNotFoundError: No module named 'my_app.urls' "
I've added my app in installed app list
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'my_app',
]
my_project urls :
from django.contrib import admin
from django.urls import path, include
urlpatterns = [
path('admin/', admin.site.urls),
path('',include('my_app.urls'))
]
my_app urls:
from django.urls import path
from . import views
urlpatterns = [
path('',views.home ),
]
views.py:
from django.shortcuts import render
def home(request):
return render(request,'index.html')
site running on local server while debug = true
but not running while debug=false(showing server error )
so how to fix this error "ModuleNotFoundError: No module named 'my_app.urls' "
What did I miss. Any help/suggestion will be highly appreciated. Thanks