Ejemplo n.º 1
0
def _setup():

    sites = []
    for site_path in get_environ_list('KS_SITES'):
        try:
            site = Site(site_path)
        except ValueError as e:
            log.log(5, 'invalid site %s: %s' % (site_path, e.args[0]))
        else:
            sites.append(site.python_path)

    try:
        add_site_list(sites)
    except Exception:
        warnings.warn('Error while adding sites %s:\n%s' % (sites, traceback.format_exc().rstrip()))
Ejemplo n.º 2
0
def _setup():

    sites = []
    for site_path in get_environ_list('SITETOOLS_SITES'):
        try:
            site = Site(site_path)
        except ValueError as e:
            log.log(5, 'invalid site %s: %s' % (site_path, e.args[0]))
        else:
            sites.append(site.python_path)

    try:
        add_site_list(sites)
    except Exception:
        warnings.warn('Error while adding sites %s:\n%s' %
                      (sites, traceback.format_exc().rstrip()))
Ejemplo n.º 3
0
def get_dev_site_patterns():
    return get_environ_list('KS_DEV_SITES', ['~/dev/venv/bin/python', '~/dev'])
Ejemplo n.º 4
0
def get_dev_site_patterns():
    return get_environ_list('SITETOOLS_DEV_SITES',
                            ['~/dev/venv/bin/python', '~/dev'])