mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Dump full stacktrace in idea.log for errors during docstring rendering
This commit is contained in:
@@ -1,19 +1,14 @@
|
||||
import sys
|
||||
|
||||
from sphinxcontrib.napoleon.docstring import GoogleDocstring
|
||||
import textwrap
|
||||
|
||||
import rest_formatter
|
||||
from sphinxcontrib.napoleon.docstring import GoogleDocstring
|
||||
|
||||
|
||||
def main(text=None):
|
||||
try:
|
||||
src = sys.stdin.read() if text is None else text
|
||||
import textwrap
|
||||
rest_formatter.main(str(GoogleDocstring(textwrap.dedent(src))))
|
||||
except:
|
||||
exc_type, exc_value, exc_traceback = sys.exc_info()
|
||||
sys.stderr.write("Error calculating docstring: " + str(exc_value))
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user