Skip to content

Increase OAuth connection URL column lengths to 2048 characters#30

Draft
Copilot wants to merge 3 commits into
developfrom
copilot/increase-oauth-url-column-lengths
Draft

Increase OAuth connection URL column lengths to 2048 characters#30
Copilot wants to merge 3 commits into
developfrom
copilot/increase-oauth-url-column-lengths

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 13, 2026

OAuth providers (e.g. Google, GitHub) can return image_url and profile_url values exceeding 512 characters, causing truncation or insertion errors against the current Unicode(512) column constraint.

Changes

  • model.py — Increase the length limit of profile_url and image_url on OauthConnection from 512 to 2048:

    # before
    profile_url: Mapped[str | None] = mapped_column(Unicode(512))
    image_url:   Mapped[str | None] = mapped_column(Unicode(512))
    
    # after
    profile_url: Mapped[str | None] = mapped_column(Unicode(2048))
    image_url:   Mapped[str | None] = mapped_column(Unicode(2048))
  • alembic/versions/d3e4f5a6b7c8_expand_oauth_url_columns.py — New migration that ALTER COLUMNs both fields from VARCHAR(512) to VARCHAR(2048). The existing 5be3d628dcc3 migration is left untouched to avoid breaking already-applied environments.

Copilot AI changed the title [WIP] Increase OAuth connection URL column lengths beyond 512 characters Increase OAuth connection URL column lengths to unbounded TEXT May 13, 2026
Copilot AI requested a review from exhuma May 13, 2026 19:00
Copilot finished work on behalf of exhuma May 13, 2026 19:00
@exhuma
Copy link
Copy Markdown
Owner

exhuma commented May 13, 2026

@copilot let's not make that an inbound limit. Set it to 2048

Copy link
Copy Markdown
Contributor Author

Copilot AI commented May 13, 2026

@copilot let's not make that an inbound limit. Set it to 2048

Done — both profile_url and image_url are now Unicode(2048) in model.py and the migration (3bad043).

Copilot AI changed the title Increase OAuth connection URL column lengths to unbounded TEXT Increase OAuth connection URL column lengths to 2048 characters May 13, 2026
Copilot finished work on behalf of exhuma May 13, 2026 19:07
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.

Increase OAuth connection URL column lengths beyond 512 characters

2 participants