Closed twerkmeister closed 4 years ago
The parsing of urls misses an edge case where there is additional invalid info at the end of a url.
in elm repl:
import Url Url.fromString "https://www.test.org (will be online next week)"
Result: Just { fragment = Nothing, host = "www.test.org (will be online next week)", path = "/", port_ = Nothing, protocol = Https, query = Nothing }
expected Result: Nothing
Also:
import Url Url.fromString "https://In development"
Result: Just { fragment = Nothing, host = "In development", path = "/", port_ = Nothing, protocol = Https, query = Nothing } : Maybe Url.Url
Expected Result: Nothing
just realized that this is also the case for the default js parser and also in python3. So it seems this is more of a global problem than one of this library
The parsing of urls misses an edge case where there is additional invalid info at the end of a url.
in elm repl:
Result: Just { fragment = Nothing, host = "www.test.org (will be online next week)", path = "/", port_ = Nothing, protocol = Https, query = Nothing }
expected Result: Nothing
Also:
Result: Just { fragment = Nothing, host = "In development", path = "/", port_ = Nothing, protocol = Https, query = Nothing } : Maybe Url.Url
Expected Result: Nothing