Date: Wed, 7 Feb 2024 16:22:21 +0000
Subject: [PATCH 41/74] fix test
---
tests/acceptance/test_guidance.py | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/tests/acceptance/test_guidance.py b/tests/acceptance/test_guidance.py
index 39874843..6ef8a678 100644
--- a/tests/acceptance/test_guidance.py
+++ b/tests/acceptance/test_guidance.py
@@ -3,36 +3,46 @@ def test_guidance_pages_load_ok(server_url, page):
assert response.ok
heading = page.get_by_role(
"heading",
- name="Guidance for local planning authorities",
+ name="Publish planning and housing data for England",
).last
assert heading.is_visible()
page.get_by_label("Guidance navigation").get_by_role(
- "link", name="Introduction"
+ "link", name="Prepare data to the specifications"
).click()
assert response.ok
heading = page.get_by_role(
"heading",
- name="Introduction for local planning authorities",
+ name="Prepare data to the specifications",
)
assert heading.is_visible()
page.get_by_label("Guidance navigation").get_by_role(
- "link", name="How to provide data"
+ "link", name="Publish data on your website"
).click()
assert response.ok
heading = page.get_by_role(
"heading",
- name="How to provide data",
+ name="Publish data on your website",
)
assert heading.is_visible()
page.get_by_label("Guidance navigation").get_by_role(
- "link", name="Data specifications guidance"
+ "link", name="Keep your data up to date"
).click()
assert response.ok
heading = page.get_by_role(
"heading",
- name="Data specifications for local planning authorities",
+ name="Keep your data up to date",
+ )
+ assert heading.is_visible()
+
+ page.get_by_label("Guidance navigation").get_by_role(
+ "link", name="Try our new check and publish service"
+ ).click()
+ assert response.ok
+ heading = page.get_by_role(
+ "heading",
+ name="Try our new check and publish service",
)
assert heading.is_visible()
From 6e1b3348035970e952ae3b5fce7b3e1adf719545 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:00:50 +0000
Subject: [PATCH 42/74] Adding full stop
---
.../pages/guidance/specifications/conservation-area.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/conservation-area.md b/application/templates/pages/guidance/specifications/conservation-area.md
index 430b3177..b95d7e1d 100644
--- a/application/templates/pages/guidance/specifications/conservation-area.md
+++ b/application/templates/pages/guidance/specifications/conservation-area.md
@@ -1,7 +1,7 @@
Version: 1.2.2
Published: 8 September 2023
-This is guidance on how to meet the [conservation area technical specification](https://digital-land.github.io/specification/specification/conservation-area/)
+This is guidance on how to meet the [conservation area technical specification](https://digital-land.github.io/specification/specification/conservation-area/).
---
From 319fb199c7be1c30a748ff3e76d7c26c74081d98 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:03:41 +0000
Subject: [PATCH 43/74] Adding link to tech spec
---
.../pages/guidance/specifications/listed-building.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/application/templates/pages/guidance/specifications/listed-building.md b/application/templates/pages/guidance/specifications/listed-building.md
index 08006234..a8472ca5 100644
--- a/application/templates/pages/guidance/specifications/listed-building.md
+++ b/application/templates/pages/guidance/specifications/listed-building.md
@@ -1,6 +1,6 @@
-Version: 1.1.1
+**Version:** 1.1.1**Published:** 9 June 2023
-Published: 9 June 2023
+This is guidance on how to meet the [listed buildings technical specification](https://digital-land.github.io/specification/specification/listed-building/).
---
From db6c5449cb0f67adbe9336e02c5b2efbebddbe05 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:06:41 +0000
Subject: [PATCH 44/74] Link to tech spec
---
.../pages/guidance/specifications/tree-preservation-order.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/application/templates/pages/guidance/specifications/tree-preservation-order.md b/application/templates/pages/guidance/specifications/tree-preservation-order.md
index 6fb7c817..c1ccf43c 100644
--- a/application/templates/pages/guidance/specifications/tree-preservation-order.md
+++ b/application/templates/pages/guidance/specifications/tree-preservation-order.md
@@ -1,6 +1,6 @@
-Version: 1.2.2
+**Version:** 1.2.2**Published:** 8 September 2023
-Published: 8 September 2023
+This is guidance on how to meet the [tree preservation order technical specification](https://digital-land.github.io/specification/specification/tree-preservation-order/)
---
From c3d77ee1a414e34da6769d1f8e67a6a5443b9059 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:07:27 +0000
Subject: [PATCH 45/74] Adding missing word 'direction'
---
.../pages/guidance/specifications/article-4-direction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/article-4-direction.md b/application/templates/pages/guidance/specifications/article-4-direction.md
index 4f20da87..e53aee57 100644
--- a/application/templates/pages/guidance/specifications/article-4-direction.md
+++ b/application/templates/pages/guidance/specifications/article-4-direction.md
@@ -1,7 +1,7 @@
**Version:** 1.2.2
**Published:** 11 September 2023
-This is guidance on how to meet the [article 4 technical specification](https://digital-land.github.io/specification/specification/article-4-direction/).
+This is guidance on how to meet the [article 4 direction technical specification](https://digital-land.github.io/specification/specification/article-4-direction/).
---
From 55297498bfbc4b0ab72cd3fc745b859014ef76f1 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:13:45 +0000
Subject: [PATCH 46/74] Fixing paragraph class
---
application/templates/pages/guidance/specifications/index.html | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index 460a3a3d..70683000 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -19,7 +19,7 @@
Expected now
We expect you to follow these specifications:
+We expect you to follow these specifications:
- brownfield land
- developer contributions
From ef24547681128d3b19424100d7a956212d105337 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:15:00 +0000
Subject: [PATCH 47/74] Fixing heading on 'licensing'
---
.../templates/pages/guidance/publish-data-on-your-website.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index 950296fe..3cf05e3c 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -29,7 +29,7 @@ This dataset shows the locations of conservation areas. Conservation areas are d
[Conservation areas (CSV, 188KB)](https://publish.planning.data.gov.uk/public/downloadable/conservationArea.csv)
-### Licensing
+#### Licensing
The data is provided under the [Open Government Licence](https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/).
From 9dd77e90b656496425b9a194611496c4dc0d122b Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Wed, 7 Feb 2024 17:18:28 +0000
Subject: [PATCH 48/74] Fixing links
---
application/templates/pages/guidance/index.html | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/application/templates/pages/guidance/index.html b/application/templates/pages/guidance/index.html
index 4d56cf7f..06b86990 100644
--- a/application/templates/pages/guidance/index.html
+++ b/application/templates/pages/guidance/index.html
@@ -16,15 +16,15 @@
- Publish data on your website
+ Publish data on your website
- Keep your data up to date
+ Keep your data up to date
- Try our new check and publish service
+ Try our new check and publish service
{#
#}
From 3cf24e6658141d6a2ca811829782244077f1a5ee Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 09:30:29 +0000
Subject: [PATCH 49/74] Adding 2 more datasets that are now in the service
---
.../templates/pages/guidance/try-check-publish-service.md | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/application/templates/pages/guidance/try-check-publish-service.md b/application/templates/pages/guidance/try-check-publish-service.md
index 22984482..9dc69cc7 100644
--- a/application/templates/pages/guidance/try-check-publish-service.md
+++ b/application/templates/pages/guidance/try-check-publish-service.md
@@ -2,7 +2,9 @@ We have an online service that checks if some data meets the standard and helps
For now the service supports:
-- [article 4 direction area dataset](https://www.planning.data.gov.uk/guidance/specifications/article-4-direction#article-4-direction-area)
-- [conservation area dataset](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-dataset)
+- [article 4 direction area data](https://www.planning.data.gov.uk/guidance/specifications/article-4-direction#article-4-direction-area)
+- [conservation area data](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-dataset)
+- [listed building outline data](https://www.planning.data.gov.uk/guidance/specifications/listed-building#listed-buildings-outline-dataset)
+- [tree preservation zone data](https://www.planning.data.gov.uk/guidance/specifications/tree-preservation-order#tree-preservation-zone-dataset)
[Try the publish planning and housing data service](https://publish.planning.data.gov.uk/)
From 338d5f6d71d2b0daec9156c06641608ce6183ce8 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 09:50:12 +0000
Subject: [PATCH 50/74] Simplifying guidance to remove confusion about live
URLs
---
.../templates/pages/guidance/keep-your-data-up-to-date.md | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/application/templates/pages/guidance/keep-your-data-up-to-date.md b/application/templates/pages/guidance/keep-your-data-up-to-date.md
index 4ac75eeb..3b44acfa 100644
--- a/application/templates/pages/guidance/keep-your-data-up-to-date.md
+++ b/application/templates/pages/guidance/keep-your-data-up-to-date.md
@@ -1,5 +1,3 @@
-If the data is on a webpage, update the data on that page whenever it changes.
+Update the data in the link on the webpage whenever it changes.
-If you have given us a live URL from your data system, it will update automatically with any changes.
-
-We take the data from your webpage or URL every day.
+Every day we take the data from the link you have shared.
From ff76f93b15e905ccc88a7f58b0e6496b1b3d67d2 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 09:51:08 +0000
Subject: [PATCH 51/74] Slight rewording for clarity
---
.../templates/pages/guidance/keep-your-data-up-to-date.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/keep-your-data-up-to-date.md b/application/templates/pages/guidance/keep-your-data-up-to-date.md
index 3b44acfa..3764a681 100644
--- a/application/templates/pages/guidance/keep-your-data-up-to-date.md
+++ b/application/templates/pages/guidance/keep-your-data-up-to-date.md
@@ -1,3 +1,3 @@
-Update the data in the link on the webpage whenever it changes.
+Whenever the data changes, update it in the link on the webpage.
Every day we take the data from the link you have shared.
From 2cecabf765db5423bd851b3c1a44d6fd56ee079b Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 10:01:13 +0000
Subject: [PATCH 52/74] Clarifying the ODP wording and making it consistent
with rest of page
---
application/templates/pages/guidance/specifications/index.html | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index 70683000..e3436161 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -38,7 +38,7 @@
- If you're funded by
Open Digital Planning, we already expect you to provide these.
Check your Open Digital Planning commitments
+ If you're funded by
Open Digital Planning, we expect you to follow all the specifications.
Check your Open Digital Planning commitments
{% endblock %}
From cf1cf09dfe71204c3fd13754b298476d932da581 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 15:45:52 +0000
Subject: [PATCH 53/74] Improving intro line
---
.../templates/pages/guidance/specifications/index.html | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index e3436161..e043a8a2 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -13,7 +13,9 @@
{% block content_primary %}
-Your planning authority can give us incomplete data and fill in the gaps later.
+Before you publish data on your website, you need to make sure it complies with our specifications.
+
+Do not worry if there’s some data missing. We can help you fill in the gaps later.
Expected now
From 1278abe9da54d3c0261c8ddf8edfbe948c81e065 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 8 Feb 2024 16:53:24 +0000
Subject: [PATCH 54/74] Clarifying that the email comes after the webpage
---
.../templates/pages/guidance/publish-data-on-your-website.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index 3cf05e3c..33df0735 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -36,7 +36,7 @@ The data is provided under the [Open Government Licence](https://www.nationalarc
Tell us about the webpage
-------------
-Once you have data that matches one of the [specifications](https://www.planning.data.gov.uk/guidance/specifications/), send an email to [digitalland@levellingup.gov.uk](mailto:digitalland@levellingup.gov.uk).
+Send an email to [digitalland@levellingup.gov.uk](mailto:digitalland@levellingup.gov.uk).
The email must include:
From 718ab5787e7c8702ec683485539606bc074f4634 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 10:17:30 +0000
Subject: [PATCH 55/74] Correting wording on link to tech spec to match the
tech spec name
---
.../templates/pages/guidance/specifications/listed-building.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/listed-building.md b/application/templates/pages/guidance/specifications/listed-building.md
index a8472ca5..413177d5 100644
--- a/application/templates/pages/guidance/specifications/listed-building.md
+++ b/application/templates/pages/guidance/specifications/listed-building.md
@@ -1,6 +1,6 @@
**Version:** 1.1.1**Published:** 9 June 2023
-This is guidance on how to meet the [listed buildings technical specification](https://digital-land.github.io/specification/specification/listed-building/).
+This is guidance on how to meet the [listed building outline technical specification](https://digital-land.github.io/specification/specification/listed-building/).
---
From b27dd704057c8a1e4ff249712b2d16b4c88bf636 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 10:19:17 +0000
Subject: [PATCH 56/74] Changing 'data' to 'dataset'
---
.../templates/pages/guidance/try-check-publish-service.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/application/templates/pages/guidance/try-check-publish-service.md b/application/templates/pages/guidance/try-check-publish-service.md
index 9dc69cc7..dc5f30eb 100644
--- a/application/templates/pages/guidance/try-check-publish-service.md
+++ b/application/templates/pages/guidance/try-check-publish-service.md
@@ -2,9 +2,9 @@ We have an online service that checks if some data meets the standard and helps
For now the service supports:
-- [article 4 direction area data](https://www.planning.data.gov.uk/guidance/specifications/article-4-direction#article-4-direction-area)
-- [conservation area data](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-dataset)
-- [listed building outline data](https://www.planning.data.gov.uk/guidance/specifications/listed-building#listed-buildings-outline-dataset)
-- [tree preservation zone data](https://www.planning.data.gov.uk/guidance/specifications/tree-preservation-order#tree-preservation-zone-dataset)
+- [article 4 direction area dataset](https://www.planning.data.gov.uk/guidance/specifications/article-4-direction#article-4-direction-area)
+- [conservation area dataset](https://www.planning.data.gov.uk/guidance/specifications/conservation-area#conservation-area-dataset)
+- [listed building outline dataset](https://www.planning.data.gov.uk/guidance/specifications/listed-building#listed-buildings-outline-dataset)
+- [tree preservation zone dataset](https://www.planning.data.gov.uk/guidance/specifications/tree-preservation-order#tree-preservation-zone-dataset)
[Try the publish planning and housing data service](https://publish.planning.data.gov.uk/)
From 1fc4d96e5d8ef52201a16fb2ee4660f7949f34b9 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 10:29:52 +0000
Subject: [PATCH 57/74] Changing 'link on the webpage' to 'data URL' after
discussion with Owen
---
.../templates/pages/guidance/keep-your-data-up-to-date.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/application/templates/pages/guidance/keep-your-data-up-to-date.md b/application/templates/pages/guidance/keep-your-data-up-to-date.md
index 3764a681..c11adb86 100644
--- a/application/templates/pages/guidance/keep-your-data-up-to-date.md
+++ b/application/templates/pages/guidance/keep-your-data-up-to-date.md
@@ -1,3 +1,3 @@
-Whenever the data changes, update it in the link on the webpage.
+Whenever the data changes, update it in the data URL.
-Every day we take the data from the link you have shared.
+Every day we take the data from the URL you have shared.
From a865b32eb1bc56741f165250ccd0be766b23b796 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 15:44:44 +0000
Subject: [PATCH 58/74] Improving intro, removing line about site showing
sources and other tweaks after team reviews
---
.../pages/guidance/publish-data-on-your-website.md | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index 33df0735..3dda4b2e 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -1,14 +1,12 @@
-All data needs to be public on a website your planning authority controls.
+Your data must be on a URL the public can access. We take the latest data from there every day.
-We take the latest data from there every day.
+You must link to that URL from a webpage about the data. This needs to be on your official planning authority website, usually ending in gov.uk.
Why publish on your website
----------------
Your planning authority will always be the source of truth about your data.
-People using [find planning and housing data in England](https://www.planning.data.gov.uk/) will see a link to your webpage.
-
Create your webpage
--------------------
@@ -42,5 +40,5 @@ The email must include:
- your full name
- the name of your planning authority
-- a link to the webpage
-- a link to the data file
+- a link to the webpage on your official planning authority website
+- a link to the data URL
From 70c2a368a6a2486d430cefb2600525c64f916089 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 15:46:37 +0000
Subject: [PATCH 59/74] Removing repetitive menu and replacing with summary
text
---
application/templates/pages/guidance/index.html | 14 +-------------
1 file changed, 1 insertion(+), 13 deletions(-)
diff --git a/application/templates/pages/guidance/index.html b/application/templates/pages/guidance/index.html
index 06b86990..5aa11072 100644
--- a/application/templates/pages/guidance/index.html
+++ b/application/templates/pages/guidance/index.html
@@ -12,19 +12,7 @@
{% block content_primary %}
- Prepare data to the specifications
-
-
-
- Publish data on your website
-
-
-
- Keep your data up to date
-
-
-
- Try our new check and publish service
+ Guidance for planning authorities adding data to the platform.
{#
#}
From 011526c92aae6b778a39a4c505d3a0d69e0a7c20 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 16:00:07 +0000
Subject: [PATCH 60/74] Correcting the details for funded LPAs
---
.../pages/guidance/specifications/index.html | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index e043a8a2..eeb82fab 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -15,13 +15,13 @@
Before you publish data on your website, you need to make sure it complies with our specifications.
-Do not worry if there’s some data missing. We can help you fill in the gaps later.
+We understand you might not have all the fields available. You can start with what you have now. You’ll need to fill in the gaps later.
Expected now
We expect you to follow these specifications:
+We expect you to prepare and publish data for:
- brownfield land
- developer contributions
@@ -31,7 +31,7 @@
Expected soon
-We’ll soon expect you to follow these specifications:
+We’ll soon expect you to prepare and publish data for:
+Or you can provide this data now if you have published it.
+
+
- If you're funded by
Open Digital Planning, we expect you to follow all the specifications.
Check your Open Digital Planning commitments
+ If you're funded through the Planning Software Improvement Fund, we expect you to follow all the specifications.
What we expect from funded planning authorities
{% endblock %}
From 4409256d999495af336239180baf6d01b3467b41 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Thu, 22 Feb 2024 16:00:55 +0000
Subject: [PATCH 61/74] Removing space
---
application/templates/pages/guidance/specifications/index.html | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index eeb82fab..6404c9f1 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -43,7 +43,7 @@
- If you're funded through the Planning Software Improvement Fund, we expect you to follow all the specifications.
What we expect from funded planning authorities
+ If you're funded through the Planning Software Improvement Fund, we expect you to follow all the specifications.
What we expect from funded planning authorities
{% endblock %}
From ee8923842cbd7f6a01cb905f0be1c9102f52f669 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 10:07:04 +0000
Subject: [PATCH 62/74] Changing "take" to "collect" as agreed with Matt L
---
.../templates/pages/guidance/publish-data-on-your-website.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index 3dda4b2e..e331ebfd 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -1,4 +1,4 @@
-Your data must be on a URL the public can access. We take the latest data from there every day.
+Your data must be on a URL the public can access. We collect the latest data from there every day.
You must link to that URL from a webpage about the data. This needs to be on your official planning authority website, usually ending in gov.uk.
From 328f45afc75b6ed86f279d499006439c9a8a313d Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 10:08:13 +0000
Subject: [PATCH 63/74] Changing "take" to "collect, as agreed with Matt L
---
.../templates/pages/guidance/keep-your-data-up-to-date.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/keep-your-data-up-to-date.md b/application/templates/pages/guidance/keep-your-data-up-to-date.md
index c11adb86..bb61b62c 100644
--- a/application/templates/pages/guidance/keep-your-data-up-to-date.md
+++ b/application/templates/pages/guidance/keep-your-data-up-to-date.md
@@ -1,3 +1,3 @@
Whenever the data changes, update it in the data URL.
-Every day we take the data from the URL you have shared.
+Every day we collect the data from the URL you have shared.
From d688f6cb1bdfdde93ed55756cd7f4f2e7850b227 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 10:09:54 +0000
Subject: [PATCH 64/74] Changing "some data" to "some of your data"
---
.../templates/pages/guidance/try-check-publish-service.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/try-check-publish-service.md b/application/templates/pages/guidance/try-check-publish-service.md
index dc5f30eb..62f9cfb7 100644
--- a/application/templates/pages/guidance/try-check-publish-service.md
+++ b/application/templates/pages/guidance/try-check-publish-service.md
@@ -1,4 +1,4 @@
-We have an online service that checks if some data meets the standard and helps you publish it.
+We have an online service that checks if some of your data meets the standard and helps you publish it.
For now the service supports:
From 8053d248c4fcbf603ffa67cc83afcd9f0526ca68 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 10:14:23 +0000
Subject: [PATCH 65/74] Changing first bullet to day "the data URL" for
consistency and clarity
---
.../templates/pages/guidance/publish-data-on-your-website.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/publish-data-on-your-website.md b/application/templates/pages/guidance/publish-data-on-your-website.md
index e331ebfd..3f4ea7fc 100644
--- a/application/templates/pages/guidance/publish-data-on-your-website.md
+++ b/application/templates/pages/guidance/publish-data-on-your-website.md
@@ -12,7 +12,7 @@ Create your webpage
The webpage must include, for each dataset:
-- a link to the data
+- the link to the data URL
- a summary of what the data is about
- a statement that the data is provided under the [Open Government Licence](https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/)
From 29f7118e75ecfa01f8644849dba9f547f184619a Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 16:01:51 +0000
Subject: [PATCH 66/74] Correcting heading weight
---
.../templates/pages/guidance/specifications/index.html | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/application/templates/pages/guidance/specifications/index.html b/application/templates/pages/guidance/specifications/index.html
index 6404c9f1..d6aecca6 100644
--- a/application/templates/pages/guidance/specifications/index.html
+++ b/application/templates/pages/guidance/specifications/index.html
@@ -17,9 +17,9 @@
We understand you might not have all the fields available. You can start with what you have now. You’ll need to fill in the gaps later.
-
+
Expected now
-
We expect you to prepare and publish data for:
-
+
Expected soon
From d3a8c590ba7aef54e31bf32dcf0969e0db293c76 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 16:32:15 +0000
Subject: [PATCH 67/74] Bolding 'version' and 'published'
---
.../pages/guidance/specifications/conservation-area.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/application/templates/pages/guidance/specifications/conservation-area.md b/application/templates/pages/guidance/specifications/conservation-area.md
index b95d7e1d..67a7baae 100644
--- a/application/templates/pages/guidance/specifications/conservation-area.md
+++ b/application/templates/pages/guidance/specifications/conservation-area.md
@@ -1,5 +1,5 @@
-Version: 1.2.2
-Published: 8 September 2023
+**Version:** 1.2.2
+**Published:** 8 September 2023
This is guidance on how to meet the [conservation area technical specification](https://digital-land.github.io/specification/specification/conservation-area/).
From 6a9b22b4cf5b53d2a1c2fc853d8796a3bd4d96a7 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 16:33:47 +0000
Subject: [PATCH 68/74] Fixing line break on version
---
.../templates/pages/guidance/specifications/listed-building.md | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/listed-building.md b/application/templates/pages/guidance/specifications/listed-building.md
index 413177d5..a1d5beea 100644
--- a/application/templates/pages/guidance/specifications/listed-building.md
+++ b/application/templates/pages/guidance/specifications/listed-building.md
@@ -1,4 +1,5 @@
-**Version:** 1.1.1**Published:** 9 June 2023
+**Version:** 1.1.1
+**Published:** 9 June 2023
This is guidance on how to meet the [listed building outline technical specification](https://digital-land.github.io/specification/specification/listed-building/).
From eb033f0f67191e52a5183ed85d316f874627af10 Mon Sep 17 00:00:00 2001
From: Jeremy-Hodge <105053544+Jeremy-Hodge@users.noreply.github.com>
Date: Mon, 4 Mar 2024 16:34:22 +0000
Subject: [PATCH 69/74] Fixing line break on version
---
.../pages/guidance/specifications/tree-preservation-order.md | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/application/templates/pages/guidance/specifications/tree-preservation-order.md b/application/templates/pages/guidance/specifications/tree-preservation-order.md
index c1ccf43c..20383e6f 100644
--- a/application/templates/pages/guidance/specifications/tree-preservation-order.md
+++ b/application/templates/pages/guidance/specifications/tree-preservation-order.md
@@ -1,4 +1,5 @@
-**Version:** 1.2.2**Published:** 8 September 2023
+**Version:** 1.2.2
+**Published:** 8 September 2023
This is guidance on how to meet the [tree preservation order technical specification](https://digital-land.github.io/specification/specification/tree-preservation-order/)
From 7c8b0cefd29201ea281528c32b61170992917ab7 Mon Sep 17 00:00:00 2001
From: George Goodall
Date: Tue, 5 Mar 2024 11:25:47 +0000
Subject: [PATCH 70/74] added redirects from old guidance pages
---
application/routers/guidance_.py | 22 ++++
.../pages/guidance/how-to-provide-data.html | 22 ----
.../pages/guidance/how-to-provide-data.md | 101 ------------------
.../pages/guidance/introduction.html | 24 -----
.../templates/pages/guidance/introduction.md | 60 -----------
5 files changed, 22 insertions(+), 207 deletions(-)
delete mode 100644 application/templates/pages/guidance/how-to-provide-data.html
delete mode 100644 application/templates/pages/guidance/how-to-provide-data.md
delete mode 100644 application/templates/pages/guidance/introduction.html
delete mode 100644 application/templates/pages/guidance/introduction.md
diff --git a/application/routers/guidance_.py b/application/routers/guidance_.py
index 0fa02a91..8a808f8c 100644
--- a/application/routers/guidance_.py
+++ b/application/routers/guidance_.py
@@ -1,6 +1,7 @@
import os
import logging
from fastapi import APIRouter, Request
+from starlette.responses import RedirectResponse
from application.core.templates import templates
router = APIRouter()
@@ -66,6 +67,13 @@ def get_breadcrumbs(path):
return crumb_dict
+def handleGuidanceRedirects(url_path, redirects):
+ for redirect in redirects:
+ if redirect["from"] == url_path:
+ return RedirectResponse(url=redirect["to"], status_code=301)
+ return False
+
+
@router.get("/{url_path:path}")
async def catch_all(request: Request, url_path: str):
index_file = "index"
@@ -77,6 +85,20 @@ async def catch_all(request: Request, url_path: str):
elif url_path[-1] == "/":
url_path += index_file
+ # Some redirects from old guidance
+
+ # introduction
+ shouldRedirect = handleGuidanceRedirects(
+ url_path,
+ [
+ {"from": "introduction", "to": "/guidance"},
+ {"from": "how-to-provide-data", "to": "/guidance"},
+ ],
+ )
+
+ if shouldRedirect:
+ return shouldRedirect
+
# build string of the URL path and then the system path to the template file
root_url_path = "pages/guidance/"
url_path_to_file = root_url_path + url_path
diff --git a/application/templates/pages/guidance/how-to-provide-data.html b/application/templates/pages/guidance/how-to-provide-data.html
deleted file mode 100644
index 7950d91c..00000000
--- a/application/templates/pages/guidance/how-to-provide-data.html
+++ /dev/null
@@ -1,22 +0,0 @@
-{%- do pageData.update({
- 'pageTitle': 'How to provide data'
-}) %}
-{% set templateName = 'dl-info/guidance/how-to-provide-data.html' %}
-{% extends "layouts/layout--guidance.html" %}
-{%- from "components/back-button/macro.jinja" import dlBackButton %}
-
-{% block breadcrumbs%}
- {{ dlBackButton({
- "parentHref": '/guidance/'
- })}}
-{% endblock %}
-
-{% block content_primary %}
-
- {% set markdown_content %}
- {%- include pageData.root_url + "how-to-provide-data.md" with context -%}
- {% endset %}
-
- {{ markdown_content | render_markdown(govAttributes=True) }}
-
-{% endblock %}
diff --git a/application/templates/pages/guidance/how-to-provide-data.md b/application/templates/pages/guidance/how-to-provide-data.md
deleted file mode 100644
index 6276557f..00000000
--- a/application/templates/pages/guidance/how-to-provide-data.md
+++ /dev/null
@@ -1,101 +0,0 @@
-The Planning Data platform gathers data from local planning authorities (LPAs) across England. We do this in order to make the data more open and accessible, so better planning decisions are made.
-
-This guidance will take you through the process of publishing data that meets the technical specifications required by the Planning Data platform.
-
----
-
-## Steps
-
-1. [Prepare your data](#{{ 'Step 1: Prepare your data' | slugify }})
-
-2. [Provide your documentation](#{{ 'Step 2: Provide your documentation' | slugify }})
-
-3. [Create or update the webpage hosting your data](#{{ 'Step 3: Create or update the webpage hosting your data' | slugify }})
-
-4. [Tell Planning Data where the webpage is](#{{ 'Step 4: Tell Planning Data where the webpage is' | slugify }})
-
----
-
-Step 1: Prepare your data
--------------------------------------
-
-The data needed for the Digital Planning Services such as [PlanX](https://opendigitalplanning.org/services) are:
-
-- [Article 4 direction data](specifications/article-4-direction)
-- [Conservation area data](specifications/conservation-area)
-- [Listed building data](specifications/listed-building)
-- [Tree preservation order data](specifications/tree-preservation-order)
-
-You may need to create more than one set of data for each subject. You'll find what to include in the [data specifications guidance](specifications/).
-
-We will accept data supplied as either:
-
-- CSV
-- GeoJSON
-- GML
-- Geopackage
-
-These may be uploaded to a single URL, or served via an OGC WFS or ArcGIS API.
-
-It’s important that the data used in Digital Planning Services is as up to date as possible - whatever data you provide us with must be maintained and updated to reflect changes in your planning constraints.
-
----
-
-Step 2: Provide your documentation
-----------------------------------
-
-For most data subjects, you must also publish links to supporting documentation that gives evidence that the data is correct.
-
-See the [data specifications guidance](specifications/) for how to provide this for each different subject.
-
-We have preferred formats for each field. We automatically change the formats of some fields, for example the dates.
-
----
-
-Step 3: Create or update the webpage hosting your data
-------------------------------------------------------
-
-To complete step 3, you must be able to edit a webpage on your LPA's official website. This will probably have a URL ending in .gov.uk or .org.
-
-If you aren't able or authorised to do this, please speak to a person who updates your organisation's website.
-
-### Create a webpage
-
-Create a separate webpage for each dataset. This webpage must have a URL that does not change, so the Planning Data platform can keep collecting the data.
-
-If the URL does change, please email .
-
-You may want to use an alias to create a short URL that is easy to remember. For example: https://www.yourLPA.gov.uk/conservation-area-data
-
-### Describe the data
-
-Add a short description of the data on the page. We recommend including these descriptors as a minimum:
-
-**Summary**
-
-Briefly explain what the data is about. For example:
-
-This dataset shows the locations of conservation areas. Conservation areas are designated to safeguard areas of special architectural and historic interest, the character and appearance of which it is desirable to preserve or enhance. Within these areas special planning controls operate which need to be considered when undertaking development.
-
-**Licensing**
-
-State that the data is provided under the [Open Government Licence](https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/).
-
-**Last updated**
-
-The date you are creating or updating the webpage.
-
-**Link to your data**
-
-Publish the links to your data on this page. Depending on what format you supply the data in, this could be the uploaded CSV, GeoJSON or GML files, or the link to the OGC WFS service.
-
----
-
-Step 4: Tell Planning Data where the webpage is
------------------------------------------------
-
-If you are creating a new webpage, you must tell us the URL. Email the URL of the webpage containing your files to .
-
-If you have already told us, you can skip this step. The Planning Data platform will regularly collect data from the URL you have given us.
-
-If the URL ever changes, please tell us.
diff --git a/application/templates/pages/guidance/introduction.html b/application/templates/pages/guidance/introduction.html
deleted file mode 100644
index 3a22fae7..00000000
--- a/application/templates/pages/guidance/introduction.html
+++ /dev/null
@@ -1,24 +0,0 @@
-{%- do pageData.update({
- 'pageTitle': 'Introduction for local planning authorities'
-}) %}
-{% set templateName = 'dl-info/guidance/introduction.html' %}
-{% extends "layouts/layout--guidance.html" %}
-
-{%- from "components/back-button/macro.jinja" import dlBackButton %}
-{% block breadcrumbs%}
- {{ dlBackButton({
- "parentHref": '/guidance/'
- })}}
-{% endblock %}
-
-{% block content_primary %}
-
- The Planning Data platform gathers data from local planning authorities (LPAs) across England. We do this in order to make the data more open and accessible, so better planning decisions are made.
-
- {% set markdown_content %}
- {%- include pageData.root_url + "introduction.md" with context -%}
- {% endset %}
-
- {{ markdown_content | render_markdown }}
-
-{% endblock %}
diff --git a/application/templates/pages/guidance/introduction.md b/application/templates/pages/guidance/introduction.md
deleted file mode 100644
index c96da374..00000000
--- a/application/templates/pages/guidance/introduction.md
+++ /dev/null
@@ -1,60 +0,0 @@
-How to provide data
--------------------
-
-This is a brief overview of our process for LPAs that are considering getting involved. We are currently only collecting data from select LPAs, but if you are interested in providing your data in future, please let us know at .
-
-The data we collect is likely to be held by your LPA already. However, it may need some work to get ready for publishing. This will likely mean:
-
-- digitising any data that is currently held in a paper format
-- formatting your data so it meets our specifications
-
-Your data then needs to be published on a trustworthy website that is open to the public. Normally, it will be on your organisational website.
-
-The Planning Data platform will access that data and routinely collect anything that is new or has changed.
-
-Benefits to LPAs
-----------------
-
-Sharing data in this way will help planners and developers gain a better understanding of the potential for development in each participating authority.
-
-The data will be used in the [PlanX](https://opendigitalplanning.org/services) service, which can:
-
-- show potential development sites that fit local planning requirements
-- help people to plan developments that meet those requirements
-
-PlanX (formerly RIPA) has the potential to save LPAs time by reducing the number of invalid planning applications they receive by [up to 80%](https://www.ripa.digital/objectives). This could [save £179 million](https://www.ripa.digital/understanding-the-problem) in costs to LPAs nationally.
-
-It will also make the planning application process easier for homeowners and businesses.
-
-By publishing your data, you will be helping to create a national resource of open planning data. Other services are likely to be built using this resource in future.
-
-What data we collect
---------------------
-
-Planning Data collects [data about a range of subjects](https://www.digital-land.info/dataset).
-
-There are 4 main data subjects that are needed for the PlanX service:
-
-- [Article 4 direction data](specifications/article-4-direction)
-- [Conservation area data](specifications/conservation-area)
-- [Listed building data](specifications/listed-building)
-- [Tree preservation order data](specifications/tree-preservation-order)
-
-We recommend publishing at least this data to benefit from PlanX and to allow developers to use it in your area.
-
-### Data formats
-
-Planning Data can take data in different formats, although some are preferred. Preferred formats will give the most accurate results.
-
-The [specifications guidance](specifications/) will tell you which formats to use for each dataset.
-
-### Updating your data
-
-If you think our version of your data is out of date or needs changing, you can email us at .
-
-Data accuracy
--------------
-
-The data collected is used to help make planning decisions, but it does not replace LPAs as a decision maker, or claim complete accuracy. People using these services will be made aware of this.
-
-With this in mind, incomplete or out of date data may still be worth publishing. We encourage you to provide as much data as you have, even if it is not perfect. This will enrich the service.
From fe500e6c997a69da432aab62f447122cb7c53a91 Mon Sep 17 00:00:00 2001
From: George Goodall
Date: Wed, 6 Mar 2024 10:00:03 +0000
Subject: [PATCH 71/74] ignore trailing slash in redirects
---
application/routers/guidance_.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/application/routers/guidance_.py b/application/routers/guidance_.py
index 8a808f8c..2648ced1 100644
--- a/application/routers/guidance_.py
+++ b/application/routers/guidance_.py
@@ -69,6 +69,9 @@ def get_breadcrumbs(path):
def handleGuidanceRedirects(url_path, redirects):
for redirect in redirects:
+ redirectFrom = redirect["from"]
+ if redirectFrom[-1] == "/":
+ redirectFrom = redirectFrom[:-1]
if redirect["from"] == url_path:
return RedirectResponse(url=redirect["to"], status_code=301)
return False
From b17f23f447cbef62bf2d2b3a4fd9b1df010ec78c Mon Sep 17 00:00:00 2001
From: George Goodall
Date: Wed, 6 Mar 2024 10:28:34 +0000
Subject: [PATCH 72/74] fix bug
---
application/routers/guidance_.py | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/application/routers/guidance_.py b/application/routers/guidance_.py
index 2648ced1..310da29a 100644
--- a/application/routers/guidance_.py
+++ b/application/routers/guidance_.py
@@ -69,9 +69,8 @@ def get_breadcrumbs(path):
def handleGuidanceRedirects(url_path, redirects):
for redirect in redirects:
- redirectFrom = redirect["from"]
- if redirectFrom[-1] == "/":
- redirectFrom = redirectFrom[:-1]
+ if url_path[-1] == "/":
+ url_path = url_path[:-1]
if redirect["from"] == url_path:
return RedirectResponse(url=redirect["to"], status_code=301)
return False
@@ -84,9 +83,6 @@ async def catch_all(request: Request, url_path: str):
# if URL path in this route is empty
if url_path == "":
url_path += index_file
- # if URL path in this route ends with /
- elif url_path[-1] == "/":
- url_path += index_file
# Some redirects from old guidance
From 9f91e00d382a4f62fe644978da236038162764d1 Mon Sep 17 00:00:00 2001
From: George Goodall
Date: Wed, 6 Mar 2024 10:57:38 +0000
Subject: [PATCH 73/74] fix one more bug
---
application/routers/guidance_.py | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/application/routers/guidance_.py b/application/routers/guidance_.py
index 310da29a..7ed2fe41 100644
--- a/application/routers/guidance_.py
+++ b/application/routers/guidance_.py
@@ -69,9 +69,10 @@ def get_breadcrumbs(path):
def handleGuidanceRedirects(url_path, redirects):
for redirect in redirects:
- if url_path[-1] == "/":
- url_path = url_path[:-1]
- if redirect["from"] == url_path:
+ url_path_copy = url_path
+ if url_path_copy[-1] == "/":
+ url_path_copy = url_path_copy[:-1]
+ if redirect["from"] == url_path_copy:
return RedirectResponse(url=redirect["to"], status_code=301)
return False
@@ -80,10 +81,6 @@ def handleGuidanceRedirects(url_path, redirects):
async def catch_all(request: Request, url_path: str):
index_file = "index"
- # if URL path in this route is empty
- if url_path == "":
- url_path += index_file
-
# Some redirects from old guidance
# introduction
@@ -98,6 +95,13 @@ async def catch_all(request: Request, url_path: str):
if shouldRedirect:
return shouldRedirect
+ # if URL path in this route is empty
+ if url_path == "":
+ url_path += index_file
+ # if URL path in this route ends with /
+ elif url_path[-1] == "/":
+ url_path += index_file
+
# build string of the URL path and then the system path to the template file
root_url_path = "pages/guidance/"
url_path_to_file = root_url_path + url_path
From cd4ffdb0aab2e1a0e53d0517179a54366f7183c7 Mon Sep 17 00:00:00 2001
From: George Goodall
Date: Wed, 6 Mar 2024 11:23:39 +0000
Subject: [PATCH 74/74] fixed bug
---
application/routers/guidance_.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/application/routers/guidance_.py b/application/routers/guidance_.py
index 7ed2fe41..9b4a27ec 100644
--- a/application/routers/guidance_.py
+++ b/application/routers/guidance_.py
@@ -70,7 +70,7 @@ def get_breadcrumbs(path):
def handleGuidanceRedirects(url_path, redirects):
for redirect in redirects:
url_path_copy = url_path
- if url_path_copy[-1] == "/":
+ if len(url_path_copy) > 0 and url_path_copy[-1] == "/":
url_path_copy = url_path_copy[:-1]
if redirect["from"] == url_path_copy:
return RedirectResponse(url=redirect["to"], status_code=301)