 
 (defun live-py-trace-update ()
   "Trace the Python code using code_tracer.py."
+  ;; For when called from elsewhere than `live-py-after-change-function'.
+  (when live-py-timer (cancel-timer live-py-timer))
   (setq-local live-py-lighter " Live-T") ; T for tracing
   (force-mode-line-update)
   (redisplay)

    (add-hook 'kill-buffer-hook 'live-py-mode-off nil t)
    (add-hook 'after-change-functions 'live-py-after-change-function nil t)
    (live-py-show-output-window)
    (live-py-after-change-function 0 0 0)
    (add-hook 'post-command-hook 'live-py-check-to-scroll nil t))
   ;; Turning the mode OFF.
   (t

    (setq-local live-py-parent (directory-file-name
                                (file-name-directory live-py-parent))))
  (setq live-py-dir (file-name-as-directory live-py-dir))
  (live-py-trace-update))

(defun live-py-set-path()
  "Prompt user to enter extra directories for the Python path."
