Why does calling super in PostSerializer#raw cause a 500 error while calling object.raw works?

You want to use add_to_serializer instead.

E.g. How to add user data to the post serializer?