mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Merge pull request #6553 from tk0miya/6549_escaped_errmsg
Fix #6549: sphinx-build: Escaped characters in error messages
This commit is contained in:
commit
ef2f1057cd
1
CHANGES
1
CHANGES
@ -53,6 +53,7 @@ Bugs fixed
|
|||||||
* #6527: :confval:`last_updated` wrongly assumes timezone as UTC
|
* #6527: :confval:`last_updated` wrongly assumes timezone as UTC
|
||||||
* #5592: std domain: :rst:dir:`option` directive registers an index entry for
|
* #5592: std domain: :rst:dir:`option` directive registers an index entry for
|
||||||
each comma separated option
|
each comma separated option
|
||||||
|
* #6549: sphinx-build: Escaped characters in error messages
|
||||||
|
|
||||||
Testing
|
Testing
|
||||||
--------
|
--------
|
||||||
|
@ -47,7 +47,7 @@ def handle_exception(app: Sphinx, args: Any, exception: BaseException, stderr: I
|
|||||||
print(terminal_safe(exception.args[0]), file=stderr)
|
print(terminal_safe(exception.args[0]), file=stderr)
|
||||||
elif isinstance(exception, SphinxError):
|
elif isinstance(exception, SphinxError):
|
||||||
print(red('%s:' % exception.category), file=stderr)
|
print(red('%s:' % exception.category), file=stderr)
|
||||||
print(terminal_safe(str(exception)), file=stderr)
|
print(str(exception), file=stderr)
|
||||||
elif isinstance(exception, UnicodeError):
|
elif isinstance(exception, UnicodeError):
|
||||||
print(red(__('Encoding error:')), file=stderr)
|
print(red(__('Encoding error:')), file=stderr)
|
||||||
print(terminal_safe(str(exception)), file=stderr)
|
print(terminal_safe(str(exception)), file=stderr)
|
||||||
|
Loading…
Reference in New Issue
Block a user