Skip to content

Validate DSN host before posting Sentry envelopes#89

Draft
cursor[bot] wants to merge 1 commit intomainfrom
cursor/high-impact-sentry-errors-9937
Draft

Validate DSN host before posting Sentry envelopes#89
cursor[bot] wants to merge 1 commit intomainfrom
cursor/high-impact-sentry-errors-9937

Conversation

@cursor
Copy link
Copy Markdown

@cursor cursor Bot commented Apr 20, 2026

Summary

  • add DSN parsing/validation in GithubClient to only accept https DSNs with *.sentry.io hosts
  • prevent envelope uploads when DSN parsing fails, logging a warning instead of raising network/SSL errors
  • add unit tests for valid DSN parsing, invalid host rejection, and no-POST behavior when DSN is invalid

Validation

  • python3 -m pytest tests/test_github_sdk.py tests/test_web_app_handler.py tests/test_sentry_config_file.py
  • Result: 22 passed, 1 skipped
Open in Web View Automation 

Co-authored-by: Armen Zambrano G. <armenzg@users.noreply.github.com>
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