response icon indicating copy to clipboard operation
response copied to clipboard

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

Open danpalmer opened this issue 6 years ago • 0 comments

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.

danpalmer avatar Oct 09 '19 17:10 danpalmer