def fetch_courses(job_config, data_bucket, data_dir ="morf-data/"):
    """
    Fetch list of course names in data_bucket/data_dir.
    :param job_config: MorfJobConfig object.
    :param data_bucket: name of bucket containing data; s3 should have read/copy access to this bucket.
    :param data_dir: path to directory in data_bucket that contains course-level directories of raw data.
    :return: courses; list of course names as strings.
    """
    s3 = job_config.initialize_s3()
    if not data_dir.endswith("/"):
        data_dir = "{0}/".format(data_dir)
    bucket_objects = s3.list_objects(Bucket=data_bucket, Prefix=data_dir, Delimiter="/")
    courses = [item.get("Prefix").split("/")[1] for item in bucket_objects.get("CommonPrefixes")]
    return courses