faust.utils.urls

URL utilities - Working with URLs.

faust.utils.urls.urllist(arg: Union[yarl.URL, str, List[yarl.URL]], *, default_scheme: str = None) → List[yarl.URL][source]

Create list of URLs.

You can pass in a comma-separated string, or an actual list and this will convert that into a list of yarl.URL objects.

Return type:List[URL]
faust.utils.urls.ensure_scheme(default_scheme: Optional[str], url: Union[str, yarl.URL]) → yarl.URL[source]

Ensure URL has a default scheme.

An URL like “localhost” will be returned with the default scheme added, while an URL with existing scheme is returned unmodified.

Return type:URL