Skip to content

fix(serializer): Implement abstract base class for customizing serialization#1363

Closed
sl0thentr0py wants to merge 3 commits intomasterfrom
neel/sentry-repr-abc
Closed

fix(serializer): Implement abstract base class for customizing serialization#1363
sl0thentr0py wants to merge 3 commits intomasterfrom
neel/sentry-repr-abc

Conversation

@sl0thentr0py
Copy link
Copy Markdown
Member

The addition of sentry_repr in #1322 breaks MagicMock since it creates attrs on the fly.
This adds a new ABC mixin class called SentryReprMixin which the user has to inherit and implement the sentry_repr method to customize serialization instead of directly implementing it on their class.

…ing getattr directly since it breaks MagicMock
@sl0thentr0py sl0thentr0py requested a review from antonpirker March 7, 2022 17:56
@sl0thentr0py
Copy link
Copy Markdown
Member Author

closing in favour of __sentry_repr__

@sl0thentr0py sl0thentr0py deleted the neel/sentry-repr-abc branch March 7, 2022 22:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant