de32960039d19599f03e32ab0aedc090918b4602,tests/examples/test_examples.py,,test_server_examples,#Any#Any#Any#Any#,69

Before Change


    doc = app.create_document()

    // remove all periodic and timeout callbacks
    for session_callback in list(doc._session_callbacks.keys()):
        doc._remove_session_callback(session_callback)

    session_id = basename(example.path)
    push_session(doc, session_id=session_id)

    if example.no_js:

After Change


    for session_callback in doc.session_callbacks:
        if isinstance(session_callback, NextTickCallback):
            doc.remove_next_tick_callback(session_callback)
        elif isinstance(session_callback, PeriodicCallback):
            doc.remove_periodic_callback(session_callback)
        elif isinstance(session_callback, TimeoutCallback):
            doc.remove_timeout_callback(session_callback)
        else:
            raise RuntimeError("Unhandled callback type", type(session_callback))

    session_id = basename(example.path)
    push_session(doc, session_id=session_id)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: bokeh/bokeh
Commit Name: de32960039d19599f03e32ab0aedc090918b4602
Time: 2018-03-27
Author: p1himik@gmail.com
File Name: tests/examples/test_examples.py
Class Name:
Method Name: test_server_examples


Project Name: ContextLab/hypertools
Commit Name: 57341c920b62c30155a2dd36aa4ae6dd338a76c9
Time: 2017-05-31
Author: andrew.heusser@gmail.com
File Name: hypertools/plot/plot.py
Class Name:
Method Name: plot


Project Name: ContextLab/hypertools
Commit Name: 3e5f0e03cec31629d2a8db78751d80019aa629ce
Time: 2017-05-31
Author: andrew.heusser@gmail.com
File Name: hypertools/plot/plot.py
Class Name:
Method Name: plot