Skip to content

Weird debugger behavior, not firing on some cases #1021

Description

@jpmonettas

Instrumenting code like this makes the debugger behave weirdly, sometimes not firing :

(add-lib 'prismatic/schema {:mvn/version "1.4.1"})
(require '[schema.core])

(schema.core/defn fibo-iter-with-schema
  ([n :- schema.core/Int] (fibo-iter-with-schema 0 1 n))
  ([curr :- schema.core/Int
    nxt :- schema.core/Int
    n :- schema.core/Int]
   (cond
     (zero? n) curr
     :else (recur nxt (+ curr nxt) (dec n)))))

I'm attaching a small video that I think describes it better.

issue.mp4

I'm also not sure why the debugger is popping up on instrumentation, looks like schema.core/defn macroexpansion is calling some already instrumented code.

Environment & Version information

CIDER version information

;; CIDER 1.15.0-snapshot (package: 20240603.825), nREPL 1.3.0-beta2
;; Clojure 1.12.0-beta1, Java 17.0.12-ea

Emacs version

29.4

Operating system

Debian Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions