clojure-emacs / clojure-emacs/cider-nrepl

Problem with breakpoints on multiple threads

Open
#630 4 comments 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
Clojure
Stars
749
Forks
182
Avg merge
1d 7h
Merged PRs (30d)
6

Description

## 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:
```clojure
(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:
;; [# #]

;; If inc-counter is instrumented and the breakpoint prompt is exited by pressing `c`:
;; @counter:
;; 1
;; results:
;; [# #]

```

## 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

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.