177dfb891089cc872bab34fb8369d75cae13bc0a,distributed/protocol/serialize.py,,dask_dumps,#Any#Any#,25

Before Change


    Serialise object using the class-based registry
    typ = typename(type(x))
    if typ in class_serializers:
        dumps, loads, has_context = class_serializers[typ]
        if has_context:
            header, frames = dumps(x, context=context)
        else:
            header, frames = dumps(x)

After Change


    Serialise object using the class-based registry
    type_name = typename(type(x))
    try:
        dumps = dask_serialize.dispatch(type(x))
    except TypeError:
        raise NotImplementedError(type_name)
    if has_keyword(dumps, "context"):
        header, frames = dumps(x, context=context)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: dask/distributed
Commit Name: 177dfb891089cc872bab34fb8369d75cae13bc0a
Time: 2018-08-19
Author: mrocklin@gmail.com
File Name: distributed/protocol/serialize.py
Class Name:
Method Name: dask_dumps


Project Name: brilee/MuGo
Commit Name: ac532f8ee44d044696a5d6142c3070194a73d3cb
Time: 2016-07-01
Author: brian.kihoon.lee@gmail.com
File Name: main.py
Class Name:
Method Name:


Project Name: dask/distributed
Commit Name: 177dfb891089cc872bab34fb8369d75cae13bc0a
Time: 2018-08-19
Author: mrocklin@gmail.com
File Name: distributed/protocol/serialize.py
Class Name:
Method Name: dask_loads