b9dc15ecef0393a55a953acff3c1d0278b19d9f5,src/fonduer/utils/utils_udf.py,,add_keys,#Any#Any#Any#,128

Before Change


    
    // Do nothing if empty
    if not keys:
        logger.warning(
            "Attempted to insert empty list of keys to {}.".format(
                key_table.__tablename__
            )
        )
        return

    // NOTE: If you pprint these values, it may look funny because of the
    // newlines and tabs as whitespace characters in these names. Use normal

After Change


    // if not exists type of syntax.
    while True:
        existing_keys = set(k.name for k in session.query(key_table).all())
        new_keys = set(keys).difference(existing_keys)
        // Bulk insert all new feature keys
        if new_keys:
            try:
                session.execute(
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: HazyResearch/fonduer
Commit Name: b9dc15ecef0393a55a953acff3c1d0278b19d9f5
Time: 2018-09-01
Author: lwhsiao@stanford.edu
File Name: src/fonduer/utils/utils_udf.py
Class Name:
Method Name: add_keys


Project Name: pfnet/optuna
Commit Name: 32f2649c5cda9acca3354e3246d798d8e0cec5dc
Time: 2020-07-04
Author: hiroyuki.vincent.yamazaki@gmail.com
File Name: optuna/storages/_rdb/storage.py
Class Name: RDBStorage
Method Name: _get_trials


Project Name: pantsbuild/pants
Commit Name: 9979b78f759ef7f210f5c6319b194db121157197
Time: 2020-05-06
Author: stuhood@twitter.com
File Name: src/python/pants/init/options_initializer.py
Class Name: OptionsInitializer
Method Name: compute_pantsd_invalidation_globs