Skip to content

chore: Remove Email model#116245

Draft
markstory wants to merge 1 commit into
masterfrom
chore-remove-email-model
Draft

chore: Remove Email model#116245
markstory wants to merge 1 commit into
masterfrom
chore-remove-email-model

Conversation

@markstory
Copy link
Copy Markdown
Member

The Email model and writes (via signal handlers) was added back in 2017, but there have never been any reads to the table in either sentry, getsentry or internal etl pipelines.

This table is often missing records which cause relocation validation failures. Removing this table will reduce our write throughput and simplify the user datamodel.

The Email model and writes (via signal handlers) was added back in 2017,
but there have never been any reads to the table in either sentry, getsentry
or internal etl pipelines.

This table is often missing records which cause relocation validation
failures. Removing this table will reduce our write throughput and
simplify the user datamodel.
@github-actions github-actions Bot added the Scope: Backend Automatically applied to PRs that change backend components label May 26, 2026
@github-actions
Copy link
Copy Markdown
Contributor

This PR has a migration; here is the generated SQL for src/sentry/migrations/1101_remove_email_model_pending.py

for 1101_remove_email_model_pending in sentry

--
-- Moved model Email to pending deletion state
--
-- (no-op)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 26, 2026

Backend Test Failures

Failures on 452a31f in this run:

tests/sentry/backup/test_validate.py::test_good_user_custom_ordinallog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/backup/test_validate.py:793: in test_good_user_custom_ordinal
    out = validate(left, right)
          ^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:173: in validate
    left_models, left_ordinal_counters = build_model_map(left_data, Side.left, findings)
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:98: in build_model_map
    raise RuntimeError("Unknown model class")
E   RuntimeError: Unknown model class
tests/sentry/backup/test_validate.py::test_auto_assign_email_obfuscating_comparatorlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/backup/test_validate.py:287: in test_auto_assign_email_obfuscating_comparator
    out = validate(left, right)
          ^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:173: in validate
    left_models, left_ordinal_counters = build_model_map(left_data, Side.left, findings)
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:98: in build_model_map
    raise RuntimeError("Unknown model class")
E   RuntimeError: Unknown model class
tests/sentry/backup/test_validate.py::test_bad_missing_custom_ordinallog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/backup/test_validate.py:524: in test_bad_missing_custom_ordinal
    out = validate(left, right)
          ^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:173: in validate
    left_models, left_ordinal_counters = build_model_map(left_data, Side.left, findings)
                                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
src/sentry/backup/validate.py:98: in build_model_map
    raise RuntimeError("Unknown model class")
E   RuntimeError: Unknown model class

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Backend Automatically applied to PRs that change backend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant