﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
37251	Document Incomplete substitution rendering of inline `|version|` placeholder in tutorial01.txt	Vainl		"Section `The development server` at File: `docs/intro/tutorial01.txt`

The raw string in the source text:
`For more information on production servers see: https://docs.djangoproject.com/en/|version|/howto/deployment/`

Compiles into HTML as:
`For more information on production servers see: <a class=""reference external"" href=""https://docs.djangoproject.com/en/"">https://docs.djangoproject.com/en/</a>6.2/howto/deployment/`

The `|version|` tag breaks the link.

The following change fixes the issue, but it still hardcodes the language to `en`. There might be a better way to implement this dynamically.

{{{
diff --git a/docs/conf.py b/docs/conf.py
index 864b9f7..e32e6f9 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -146,6 +146,7 @@ extlinks = {
     # A file or directory. GitHub redirects from blob to tree if needed.
     ""source"": (""https://github.com/django/django/blob/main/%s"", ""%s""),
     ""ticket"": (""https://code.djangoproject.com/ticket/%s"", ""#%s""),
+    ""djlink"": (f""https://djangoproject.com/en/{version}/%s"", None),
 }
 
 if sphinx_version < (8, 1):
diff --git a/docs/intro/tutorial01.txt b/docs/intro/tutorial01.txt
index db6150a..643ba44 100644
--- a/docs/intro/tutorial01.txt
+++ b/docs/intro/tutorial01.txt
@@ -131,7 +131,7 @@ You'll see the following output on the command line:
     Quit the server with CONTROL-C.
 
     WARNING: This is a development server. Do not use it in a production setting. Use a production WSGI or ASGI server instead.
-    For more information on production servers see: https://docs.djangoproject.com/en/|version|/howto/deployment/
+    For more information on production servers see: :djlink:`howto/deployment/`
 
 .. note::
     Ignore the warning about unapplied database migrations for now; we'll deal

}}}

"	Cleanup/optimization	new	Uncategorized	6.0	Normal				Unreviewed	0	0	0	0	0	0
