URL моего основного сайта django
from django.contrib import admin
from django.urls import path,include
urlpatterns = [
path('ways/', include('ways.urls')),
path('admin/', admin.site.urls),
URL приложения
urlpatterns = [
path('newWay/', views.newWay, name='newWay'),
path('waySolved/', views.update_way, name='update_way'),
]
структура проекта

Но всякий раз, когда я нажимаю http://localhost:8000/ways/waySolved/
там написано Не найдено: / way / waySolved /
но http://localhost:8000/ways/newWay/ работает отлично.
Во взглядах у меня есть обе функции.
update_way
def update_way(request):
way_id= request.GET.get('way_id', None)
token=request.GET.get('token', None)
if way_id is not None and token is not None:
token = token.replace("\"", "")
community_osm_cur.execute("""SELECT latitude ,longitude from (SELECT * from (SELECT
latitude,longitude,id from current_nodes where id in (Select node_id from
current_way_nodes where way_id='%s' ORDER BY sequence_id asc )) AS temp1
Inner join
(Select node_id,sequence_id from current_way_nodes where way_id='%s'
ORDER BY sequence_id asc ) As temp2 on temp1.id=temp2.node_id
order by sequence_id asc) As temp3""", ((int)(way_id), (int)(way_id),))
nodes_list = community_osm_cur.fetchall()
coords = []
if len(nodes_list)>0:
for node in nodes_list:
lat = node[0] / 10000000
lng = node[1] / 10000000
coords.append([lat, lng])
position_hash = hashlib.sha3_256(json.dumps(coords).encode()).hexdigest()
community_osm_cur.execute("select user_id from oauth_tokens where secret = %s", (token,))
id = community_osm_cur.fetchone()[0]
updated_way_cur.execute("""INSERT INTO updated_ways (way_id,node_hash) values
(%s,%s) on conflict(way_id) do update set node_hash=%s""",
(way_id,position_hash,position_hash,))
updated_way_cur.execute("Delete from distribution where user_id=%s and id = %s ",(id,way_id,))
updated_way_con.commit()
return HttpResponse(status=200)
return HttpResponse(status=404)