         )
         if opts.cb?
             salvus_client.execute_callbacks[uuid] = opts.cb
+
+    _remove_execute_callbacks: () =>
+        if @_execute_callbacks?
+            for uuid in @_execute_callbacks
+                delete salvus_client.execute_callbacks[uuid]
+            delete @_execute_callbacks
 
     introspect_line: (opts) =>
         opts = defaults opts,


        # store pref in localStorage to not auto-open this file next time
        @editor.local_storage('auto_open', false)

        @chat_session?.disconnect_from_session()

    execute_code: (opts) =>


    disconnect_from_session: (cb) =>
        @_remove_listeners()
        if @session_uuid? # no need to re-disconnect if not connected (and would cause serious error!)
            salvus_client.call
                timeout : 10
                message : message.codemirror_disconnect(session_uuid : @session_uuid)
