f1e668d3bf88c88560dd2b40c6db8ea9500f9dc6,bokeh/model.py,Model,js_on_change,#Model#Any#,477

Before Change


        if not all(isinstance(x, CustomJS) for x in callbacks):
            raise ValueError("not all callback values are CustomJS instances")

        if event in self.properties():
            event = "change:%s" % event

        old = {k: [cb for cb in cbs] for k, cbs in self.js_property_callbacks.items()}
        if event not in self.js_property_callbacks:
            self.js_property_callbacks[event] = []
        for callback in callbacks:

After Change


        if not all(isinstance(x, CustomJS) for x in callbacks):
            raise ValueError("not all callback values are CustomJS instances")

        descriptor = self.lookup(event, raises=False)
        if descriptor is not None:
            event = f"change:{descriptor.name}"

        old = {k: [cb for cb in cbs] for k, cbs in self.js_property_callbacks.items()}
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: bokeh/bokeh
Commit Name: f1e668d3bf88c88560dd2b40c6db8ea9500f9dc6
Time: 2021-01-25
Author: mattpap@gmail.com
File Name: bokeh/model.py
Class Name: Model
Method Name: js_on_change


Project Name: HyperGAN/HyperGAN
Commit Name: 8a3148f6f973652500853e656274e65070edaf7e
Time: 2017-06-03
Author: martyn@255bits.com
File Name: hypergan/losses/least_squares_loss.py
Class Name: LeastSquaresLoss
Method Name: create


Project Name: googledatalab/pydatalab
Commit Name: d98df66f581dca38bbe7dfc299386921b65bda0d
Time: 2017-09-28
Author: qimingj@users.noreply.github.com
File Name: solutionbox/code_free_ml/mltoolbox/code_free_ml/trainer/task.py
Class Name:
Method Name: make_prediction_output_tensors