Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible to add a notification with a name that's too long #165

Open
danpalmer opened this issue Oct 9, 2019 · 0 comments
Open

Possible to add a notification with a name that's too long #165

danpalmer opened this issue Oct 9, 2019 · 0 comments

Comments

@danpalmer
Copy link
Contributor

It's currently possible to create a notification handler with a function name too long to fit in the key column in the notifications database table.

Recommendations of fixes, either:

  • Convert to TextField, on Postgres at least there's essentially no performance benefit of using a CharField with a cap over a TextField if you don't want to cap the column size.
  • Validate at registration time of the notification handler that the function name is short enough to fit in the database.

I think the first option is a better option, as writing the name as Python source code will naturally limit it to reasonable lengths, at which using a TextField will have essentially the same performance.

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

No branches or pull requests

1 participant