mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-16 15:47:58 +00:00
use string representation when dumping variables
This commit is contained in:
@@ -196,7 +196,7 @@ class HTMLLogger(BaseLogger):
|
||||
|
||||
def _python_var(self, var: Any) -> str:
|
||||
if CODE_HIGHLIGHT:
|
||||
fmt = highlight(repr(var), PythonLexer(), HtmlFormatter(nowrap=True))
|
||||
fmt = highlight(str(var), PythonLexer(), HtmlFormatter(nowrap=True))
|
||||
return f'<div class="highlight"><code class="lang-python">{fmt}</code></div>'
|
||||
|
||||
return f'<code class="lang-python">{str(var)}</code>'
|
||||
|
||||
Reference in New Issue
Block a user