Fork me on GitHub
#chlorine
<
2020-04-08
>
fabrao01:04:53

Hello all, I´m trying to use chlorine:go-to-var-definition but it fails and is getting a crazy path.

fabrao01:04:43

is that because I´m using alias/function mode?

mauricio.szabo01:04:36

What's the path you're getting?

fabrao01:04:43

C:\Trabalho\BM\****\Projeto\Clojure\Monitoracao\baytinela\C:\Trabalho\BM\*****\Projetos\Clojure\bayconfig\src\uim\config.clj

fabrao01:04:47

It seems that is concat path from 2 projects

fabrao01:04:15

I included 2 folders of 2 projects

mauricio.szabo01:04:57

Uhn, never tested the feature with multi folders... I'll check here what happens.

fabrao01:04:27

A silly question, how do I clean all the evaluate values ?

fabrao02:04:42

@ I used your keybinds 🙂. So you don´t clean you inlines?

'atom-workspace atom-text-editor:not([mini])':

  'ctrl-; ; b':     'chlorine:teste'
  'ctrl-; b':       'sean:inspect-block'
  'ctrl-; B':       'sean:inspect-top-block'
  'ctrl-; c':       'chlorine:break-evaluation'
  'ctrl-; d':       'chlorine:doc-for-var'
  'ctrl-; D':       'sean:def-binding'
  'ctrl-; e':       'chlorine:disconnect'
  'ctrl-; f':       'chlorine:load-file'
  'ctrl-; j':       'sean:inspect-java'
  'ctrl-; k':       'chlorine:clear-console'
  'ctrl-; n':       'sean:inspect-ns'
  'ctrl-; s':       'sean:inspect-selection'
  'ctrl-; S':       'chlorine:source-for-var'
  'ctrl-; t':       'chlorine:run-test-for-var'
  'ctrl-; v':       'sean:inspect-var'
  'ctrl-; x':       'chlorine:run-tests-in-ns'
  'ctrl-; y':       'chlorine:connect-clojure-socket-repl'
  'ctrl-; .':       'chlorine:go-to-var-definition'

seancorfield02:04:03

Visit that link again.

seancorfield02:04:28

Compare it to what you have. You haven't updated your keymap since I updated mine 🙂

fabrao02:04:59

yes, 11 days ago

seancorfield02:04:03

That link goes directly to the line that solves your problem.

fabrao02:04:56

yes, thanks

fabrao20:04:09

@mauricio.szabo so, is it a bug about wrong path?

seancorfield20:04:27

@fabrao How did you start your REPL? Via cmd/powershell or via WSL?

seancorfield20:04:02

I wonder if it's some artifact of how your dependencies are set up? You're using CLI/`deps.edn`?

seancorfield20:04:57

How do those two projects relate to each other? (Monitoracao\baytinela and bayconfig)

fabrao21:04:02

no relationship btw them

seancorfield21:04:16

(I use Atom/Chlorine on both Mac and Windows with multiple projects open and have never seen go-to-var-definition mess up like that -- and I use PS for starting my REPL on Windows mostly)

mauricio.szabo21:04:42

Hi, I was checking if there's any code on goto-var-definition that uses the project's folders, and I didn't find anything... Are you using a Clojure REPL, or ClojureScript, ClojureCLR?

fabrao21:04:31

I start with clj -J'-Dclojure.server.repl={:port,5555,:accept,clojure.core.server/repl}'

fabrao21:04:44

connect to it

mauricio.szabo21:04:57

Can you try to re-start Atom with only one directory for the project, issue goto-var definition again, and check if the problem persist?

fabrao21:04:30

restart repl too?

fabrao21:04:49

I did without repl restart and the same problem

mauricio.szabo21:04:37

Try to restart it. See if it changes anything

fabrao21:04:31

'C:\Trabalho\BM\\Projetos\Clojure\bayconfig\C:\Trabalho\BM\\Projetos\Clojure\bayconfig\src\uim\comm.clj'

mauricio.szabo21:04:09

Are these ***** on the path too?

mauricio.szabo21:04:39

Also, what's the path of the project?

fabrao21:04:43

That´s our customer name, I have to hide

mauricio.szabo21:04:39

Ok, no worries. I liteally just wanted to see if the directory was messing up so far that it was adding invalid chars on the path 😄

fabrao21:04:55

hehe, no, the path is ok with it

mauricio.szabo21:04:42

Okay, so... can you evaluate (replacing your-fn-name with the name of the var you're trying to go to defintion):

(:file (meta #'your-fn-name))
And send the result here? You can redact the path name, no worries 🙂

mauricio.szabo21:04:38

Also, evaluate:

(keys (meta #'your-fn-name))

fabrao21:04:24

uim/comm.clj and (:arglists :line :column :file :name :ns)

mauricio.szabo22:04:06

Okay, one more thing: can you evaluate, please:

(str
 (.getResource (clojure.lang.RT/baseLoader)
               "uim/comm.clj"))

mauricio.szabo22:04:43

I believe this is the last thing I'll ask 🙂

fabrao22:04:21

"file:/C:/Trabalho/BM/*/Projetos/Clojure/bayconfig/src/uim/comm.clj"

fabrao22:04:52

@mauricio.szabo no problem, anything you want to contribute