def _get_app_path(url):
    ''' Extract the app path from a Bokeh server URL

    Args:
        url (str) :

    Returns:
        str

    '''
    app_path = urlparse(url).path.rstrip("/")
    if not app_path.startswith("/"):
        app_path = "/" + app_path
    return app_path
Extract the app path from a Bokeh server URL

    Args:
        url (str) :

    Returns:
        str