Closed humbertogontijo closed 1 month ago
Hi @humbertogontijo, thanks for the PR. Such URLs bAdScHeMa://github.com
will be validated if extra_schemes = {'bAdScHeMa',}
.
Say a library user provides a domain name, which now suppose is validated against itself, wouldn't that defeat the purpose of domain validation? I think so.
We do plan to support more schemas, see #388.
validators.url
method already has a lot of parameters, wouldn't adding more, clutter it? WDYT?
The idea is to just add custom schemes. For my purpose it would be for Telegram https://core.telegram.org/api/links
I do agree that this is more a URI than URL stuff though. But it would workout while uri validation is not available
Yes, it will work, but that is no reason for doing counter-intuitive validation. If a huge number of schemas need to be validated, something like TLD validation can be performed.
Also tg://
links need not follow the classical http
URL syntax, which therefore will return ValidationError
regardless of the scheme.
So is it worth it, what do you think?
Thats ok. Thank you
This allows for a more flexible scheme validation