d7873de414ea70bd384aa099e5255d2fbeff719a,studio/util.py,,download_file_from_qualified,#Any#Any#Any#,260

Before Change


    assert qualified.startswith("s3://") or \
        qualified.startswith("gs://")

    bucket = qualified.split("/")[2]
    key = "/".join(qualified.split("/")[3:])

    if logger is not None:
        logger.debug(("Downloading file from bucket {} " +

After Change


        qualified.startswith("gs://")

    qualified_split = qualified.split("/")
    if qualified_split[2].endswith(".com"):
        bucket = qualified_split[3]
        key = "/".join(qualified_split[4:])
    else:
        bucket = qualified_split[4]
        key = "/".join(qualified_split[5:])

    if logger is not None:
        logger.debug(("Downloading file from bucket {} " +
                      " and key {} to local path {}")
                     .format(bucket, key, local_path))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: studioml/studio
Commit Name: d7873de414ea70bd384aa099e5255d2fbeff719a
Time: 2017-12-02
Author: peter.zhokhov@sentient.ai
File Name: studio/util.py
Class Name:
Method Name: download_file_from_qualified


Project Name: sassoftware/python-dlpy
Commit Name: 8afa7fb5dc0ef8bb6f2eb98e97d64821624b4e3c
Time: 2019-08-02
Author: Xiaozhuo.Cheng@sas.com
File Name: dlpy/tests/test_speech.py
Class Name: TestSpeechToText
Method Name: setUpClass


Project Name: sassoftware/python-dlpy
Commit Name: 8afa7fb5dc0ef8bb6f2eb98e97d64821624b4e3c
Time: 2019-08-02
Author: Xiaozhuo.Cheng@sas.com
File Name: dlpy/tests/test_speech.py
Class Name: TestSpeechToTextInit
Method Name: setUp