Closed Cheukting closed 3 months ago
@Cheukting, thanks for opening the issues, and apologize for not doing it earlier 🙃 I'll comment here in the afternoon
So, coming back to this.
At the moment we read two fields from the user: name
and order
here: https://github.com/EuroPython/discord/blob/main/EuroPythonBot/cogs/registration.py#L31-L47
After browsing the existing tickets, I see that order is A-Z
and 0-9
and it looks like it always has a length of 5.
TODO: add max-length
parameter to the order
field.
For the names someone needs to take a deeper look, I see that some names are not only ascii, like Jániaer Voščák
. We need some smart validation here.
Do pretix has a documentation about what is valid? If not maybe we can ask their team?
Do pretix has a documentation about what is valid? If not maybe we can ask their team?
I didn't see any, but I already put some limitations here: https://github.com/EuroPython/discord/blob/main/EuroPythonBot/cogs/registration.py#L33-L50
for min_length
max_length
, but anyway it would be nice to validate order and name
From today's meeting and Artem's feedback:
I am not too sure about this one, maybe @Kislovskiy can elaborate, or maybe it means just a simple check on if the input is valid
(e.g. no emojis or not allowing characters in names - what is valid depends on what Pretix said is valid; checking if the ticket identification number has enough characters etc.)