I see that putting a : character in front of the port is clearly intentional :
https://github.com/haskell/network-uri/blob/master/Network/URI.hs#L602
Two questions:
- Could this be a Maybe Int instead of a string? Most URI implementations store this as an integer and it is far more convenient.
Failing that..
- Why is there a : in front of the value? This makes it rather annoying to parse out.