Remove organization name unique constraint - #799
Merged
Conversation
Global uniqueness on the organization name meant one tenant's choice of name blocked an unrelated tenant from using theirs, which is a real collision for organizations that genuinely share a name. Nothing in the library resolved an organization by name - URLs, permission checks and the active-organization session value are all keyed on id - so the constraint provided no isolation, only friction. Since names can now collide, __str__ includes the id so same-named organizations stay distinguishable wherever a human picks one, such as admin foreign key dropdowns. Email templates and public pages render organization.name directly rather than the model, so they are unaffected. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The TableContainer capped its height at 440px, so once an account had enough organizations the list became an inner scroll area nested inside the page scroll. Removing the cap lets the table extend and the page scroll as a whole. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The hook was pinned to v0.1.8 while pyproject.toml requires >=0.16.1,<0.17.0, so the version gating PRs - CI runs `make pre-commit`, which is `pre-commit run --all-files` - was two years behind the one developers install. Formatting that the pinned ruff produces locally could therefore differ from what CI accepted, in either direction. Also renames the `ruff` hook id to `ruff-check`; `ruff` is a deprecated alias in current ruff-pre-commit and reports itself as a legacy alias. The reformatting this surfaces is committed separately. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Fallout from pinning the ruff hook to the required version: ruff now collapses `def f() -> X:` followed by an indented `...` onto a single line. Cosmetic only - every change is a Protocol or stub body, and no runtime behavior is affected. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.