Skip to content

Prevent bot visits to a few action urls via robots.txt#8913

Merged
gbp merged 2 commits intomysociety:developfrom
laurentS:robots_txt_actions
Nov 26, 2025
Merged

Prevent bot visits to a few action urls via robots.txt#8913
gbp merged 2 commits intomysociety:developfrom
laurentS:robots_txt_actions

Conversation

@laurentS
Copy link
Copy Markdown
Contributor

@laurentS laurentS commented Oct 7, 2025

Relevant issue(s)

Relates to #8132 and PR #8223

What does this do?

It adds a number of action links as disallowed for bots. Not all bots seem to respect robots.txt so a redundant approach is probably best, hence the overlap with #8223.

Why was this needed?

A lot of bot traffic is hitting our site on these urls, without actually providing any useful content to bots, but still causing server load. In some cases (/track for instance) the page visit creates a database record which is completely useless and uses up disk space. This aims at reducing this side effect.

Implementation notes

Screenshots

Notes to reviewer


Have you updated the changelog? If this is not necessary, put square brackets around this: skip changelog

@laurentS laurentS marked this pull request as ready for review November 18, 2025 16:19
@laurentS
Copy link
Copy Markdown
Contributor Author

@gbp Using this trivial PR as an exercise for me to check if I've got the PR process right, before sending some more substantial ones :)

@gbp gbp merged commit 0b96760 into mysociety:develop Nov 26, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants