-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Reject device display names that are too long #6882
Conversation
I'm seeing a SyTest fail:
This doesn't feel related to this PR and seems to be failing on develop as well (see https://buildkite.com/matrix-dot-org/synapse/builds/7019). |
matrix-org/sytest#801 should have fixed that |
👍 I see that those were merged into develop on SyTest. Kicked off the builds again. Thanks @ara4n! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, though a regression test in tests.handlers.test_device
would have won bonus points...
95b37d3
to
520a579
Compare
Thanks for the review @richvdh! I added a unit test, although now it seems more builds are failing for unrelated reasons. |
Too long is currently defined as 100 characters in length.
520a579
to
3e10e10
Compare
@richvdh Would appreciate a quick check over the unit test to see if it is a reasonable test. Builds are green again too! Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup looks great, thank you!
* commit 'a92e703ab': Reject device display names that are too long (#6882)
This rejects device display name updates that are too long by raising a
SynapseError
from update device endpoint.This defines a maximum length of 100 characters, but that is arbitrary. If someone has a better suggestion, please let me know!