-
Notifications
You must be signed in to change notification settings - Fork 61
Closed
Description
Hi,
I am new to this and struggled for the past 3 hours trying to find a simple mistake I made.
const MDNS_SERVICE_NAME: &'static str = "_VERYLONGNAME._tcp.local.";
let service_info = ServiceInfo::new(
MDNS_SERVICE_NAME,
&instance_name,
&host_name,
local_ip().map_err(|e| BackendError::new("Could not get local ip", &format!("{}", e)))?,
MDNS_PORT,
&MDNS_PROPERTIES[..],
)I used a long name inside MDNS_SERVICE_NAME. If this VERYLONGNAME part above is longer than 15 characters nothing will work you wont get any errors and it just silently fails. This is not mentioned in the code of ServiceInfo and not in docs.rs in the example.
I think we should add a comment to the ty_domain property on ServiceInfo, add assertions to verify this inside ServiceInfo::new, also add this in the docstring of new and add information for the module documentation for the example shown on docs.rs
If you confirm I could do that
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels