summaryrefslogtreecommitdiffstats
path: root/urls.py
diff options
context:
space:
mode:
authorPhilip Sargent <philip.sargent@klebos.com>2020-07-18 16:23:54 +0100
committerPhilip Sargent <philip.sargent@klebos.com>2020-07-18 16:23:54 +0100
commitedd5a3efd901df68243372f46087d96d4fbf7715 (patch)
tree037682c9ad9a85c2de8532c5623bf750c12dee5b /urls.py
parent90dfa516da857f300bd0ff483ebf7a412934bbcf (diff)
downloadtroggle-edd5a3efd901df68243372f46087d96d4fbf7715.tar.gz
troggle-edd5a3efd901df68243372f46087d96d4fbf7715.tar.bz2
troggle-edd5a3efd901df68243372f46087d96d4fbf7715.zip
Module documentation docstrings
Diffstat (limited to 'urls.py')
-rw-r--r--urls.py25
1 files changed, 17 insertions, 8 deletions
diff --git a/urls.py b/urls.py
index 02dddd0..3a252a9 100644
--- a/urls.py
+++ b/urls.py
@@ -10,16 +10,25 @@ from troggle.core.views_other import logbook_entry_suggestions
from troggle.core.views_caves import ent, prospecting_image
from troggle.core.views_statistics import pathsreport, stats
from flatpages import views as flatviews
-
+"""This sets the actualurlpatterns[] and urlpatterns[] lists which django uses
+to resolve urls - in both directions as these are declarative. It runs
+django autodiscover() first:
+https://docs.djangoproject.com/en/1.11/ref/contrib/admin/#discovery-of-admin-files
+which may no longer be necessary in Django 1.11.29
+
+HOW THIS WORKS
+This is a "url dispatcher" - something needed by every web framework.
+url( <regular expression that matches the thing in the web browser>,
+<reference to python function in 'core' folder>, <optional name>)
+
+Django also provides the reverse function: given an an object, provide the URL
+which is vital to writing code for the webapp. So the URL dispatch is declarative.
+"""
admin.autodiscover()
-# HOW DOES THIS WORK:
-# This is a "url dispatcher" - something needed by every web framework.
-# url( <regular expression that matches the thing in the web browser>,
-# <reference to python function in 'core' folder>, <optional name>)
-
-# Django also provides the reverse function: given an an object, provide the URL
-# which is vital to writing code for the webapp. So the URL dispatch is declarative.
+# Many of these patterns do not work because troggle spent many years broken and we have
+# not yet restored all the functions. Some may have never been fully implemented in
+# the first place and what they were intended to provide is obscure.
actualurlpatterns = [
url(r'^troggle$', views_other.frontpage, name="frontpage"),