e1d39a4c9158c9a9db1218cb5be9946152e2ca1b,src/fetch_cnpj_info.py,,,#,137

Before Change



    print("%i CNPJ\"s to be fetched" % len(cnpj_list_to_import))

    with futures.ThreadPoolExecutor(max_workers=10) as executor:
        future_to_cnpj_info = dict((executor.submit(fetch_cnpj_info, cnpj), cnpj)
                                   for cnpj in cnpj_list)

After Change



    for cnpj in cnpj_list[:3]:
        result = fetch_cnpj_info(cnpj)
        if result != None and result["status"] == "OK":
            info_dataset = info_dataset.append(result, ignore_index=True)

    info_dataset.to_csv(INFO_DATASET_PATH,
                        compression="xz",
                        encoding="utf-8",
                        index=False)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 2

Instances


Project Name: okfn-brasil/serenata-de-amor
Commit Name: e1d39a4c9158c9a9db1218cb5be9946152e2ca1b
Time: 2017-04-14
Author: marcus.rehm@gmail.com
File Name: src/fetch_cnpj_info.py
Class Name:
Method Name:


Project Name: okfn-brasil/serenata-de-amor
Commit Name: cef99445ab551931fed507518b85034b97c946ee
Time: 2016-11-09
Author: cuducos@gmail.com
File Name: src/search_suspect_places.py
Class Name:
Method Name: search_suspicious_around_companies


Project Name: vatlab/SoS
Commit Name: 92d26a01d73f0bc00405f51324756ae16b9f7d4a
Time: 2017-04-16
Author: ben.bog@gmail.com
File Name: sos/sos_task.py
Class Name: TaskEngine
Method Name: run