mirror of
https://github.com/jlengrand/bugsink.git
synced 2026-03-09 23:51:20 +00:00
Adds a `stacktrace_md` field to EventSerializer and a `/stacktrace` action returning the same markdown (but as the full response). Also switches `data` to use `get_parsed_data()` (as it should have) and in json dict format (rather than str).
11 lines
277 B
Python
11 lines
277 B
Python
from rest_framework.renderers import BaseRenderer
|
|
|
|
|
|
class MarkdownRenderer(BaseRenderer):
|
|
media_type = "text/markdown"
|
|
format = "md"
|
|
charset = "utf-8"
|
|
|
|
def render(self, data, accepted_media_type=None, renderer_context=None):
|
|
return data.encode("utf-8")
|