forked from getsentry/sentry
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(relocation): Change relocation_export RPC type (getsentry#75017)
Previously, we tried to send a raw `bytes` object. While pydantic allows this from a type checking perspective, it fails when we try to encode the data as a JSON payload for transport over the wire, which requires UTF-8 encoding. To get around this, we change the type of `encrypted_contents` to `list[int]`, then cast the `bytes` to/from a `list[int]` when alternating between sending over the wire and saving to a filestore. While a change to an RPC schema like this is generally unsafe, because this endpoint is behind an admin barrier and only being tested internally, I feel like it is safe to do so in this case.
- Loading branch information
1 parent
9894a93
commit 9f013d0
Showing
5 changed files
with
33 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters