Expands a user-provided specification of source files into a list of paths.

def _expand_sources(sources):
    '''
    Expands a user-provided specification of source files into a list of paths.
    '''
    if sources is None:
        return []
    if isinstance(sources, six.string_types):
        sources = [x.strip() for x in sources.split(',')]
    elif isinstance(sources, (float, six.integer_types)):
        sources = [six.text_type(sources)]
    return [path
            for source in sources
            for path in _glob(source)]