-
Notifications
You must be signed in to change notification settings - Fork 217
Open
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Description
The URL validation in ureq3 is too strict. Even if ureq3 doesn't claim to support unix domain sockets itself, it's not possible to implement a transport that could do it.
This is stricter than what ureq3 is intended to be.
I just spent a day trying to get this work, and couldn't. There's no way I could find to avoid the check in
default_port:Lines 49 to 59 in 1ce334d
fn default_port(&self) -> Option<u16> { if *self == Scheme::HTTPS { Some(443) } else if *self == Scheme::HTTP { Some(80) } else if let Ok(proxy) = ProxyProtocol::try_from(self.as_str()) { Some(proxy.default_port()) } else { debug!("Unknown scheme: {}", self); None } Which always results in a parsing error:
Lines 319 to 321 in 1ce334d
scheme .default_port() .ok_or_else(|| Error::BadUri(format!("unknown scheme: {}", scheme)))?; You could just pass a completely fake uri to the agent, I guess, but that's pretty ugly. I think this issue should be reopened.
Originally posted by @colinmarc in #538
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request