No leading or trailing blanks in UDF names

Note: only the last commit (986248e) is relevant. (Piggybacking on #1814 to preserve migration numbers.)

* Data migration to trim existing UDF names
* `strip` name before saving a UDF definition
* Update a test to ensure leading and trailing blanks removed