Skip to content

Problem with breakpoints on multiple threads #630

Open
@timsgardner

Description

@timsgardner

Expected behavior

Breakpoints run on multiple threads simultaneously. If multiple breakpoints are running at the same time, a mechanism exists to switch between them.

Actual behavior

I can't find a mechanism for switching between simultaneous breakpoints. If two breakpoints are running simultaneously, one of them appears to hang:

(def counter (atom 0))

(defn inc-counter []
  (swap! counter inc))

(def results
  [(future (inc-counter))
   (future (inc-counter))])

;; If inc-counter is not instrumented:
;; @counter:
;; 2
;; results:
;; [#<Future@7c262db8: 1> #<Future@33382bde: 2>]

;; If inc-counter is instrumented and the breakpoint prompt is exited by pressing `c`:
;; @counter:
;; 1
;; results:
;; [#<Future@5b3f971d: :pending> #<Future@51a1bc5d: 1>]

Steps to reproduce the problem

See example above

Environment & Version information

cider-nrepl version

Not clear how to check this (installed automatically with cider-jack-in), but the cider emacs package information version is 20190720.1656.

Java version

1.8.0_221

Operating system

Windows 10

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions