dirac

Dirac v1.7.2 is out: https://github.com/binaryage/dirac/releases/tag/v1.7.2
frank 2016-03-16T19:13:55.000059Z

is anyone else having trouble getting dirac to work with canary?

frank 2016-03-16T19:15:14.000060Z

it worked before šŸ˜­

frank 2016-03-16T19:18:14.000061Z

it's giving me the message that devtools isn't set up

2016-03-16T19:23:32.000062Z

are you running the devtools init stuff in your clojurescript code?

2016-03-16T19:23:38.000063Z

I was using it yesterday

2016-03-16T19:25:02.000064Z

@frank: I could try cut a new release with latest devtools merged in

frank 2016-03-16T19:25:32.000065Z

let me try some more debugging first

2016-03-16T19:26:10.000066Z

also please check how many js contexts do you have in your page (Console panel -> select box contains ā€œtopā€ and maybe some others)

2016-03-16T19:26:43.000067Z

right now dirac takes the first one in the list as current and executes javascript in it

2016-03-16T19:27:04.000068Z

it happened to me that a chrome extension injected content script into a page and appeared as the first item there

2016-03-16T19:27:29.000069Z

and that borked whole thing because now dirac was targeting that content script js context instead of pageā€™s js context

2016-03-16T19:29:42.000071Z

Iā€™m now trying to figure a way how to implement some heuristics there, maybe selecting a js context which contains cljs-devtools

frank 2016-03-16T19:38:10.000072Z

@darwin: I see lots of tops

2016-03-16T19:38:41.000074Z

that will be the problem, if the currently selected is not your real page context, dirac wonā€™t work

2016-03-16T19:39:02.000075Z

because it talks to something else

2016-03-16T19:39:37.000076Z

what do you see in Sources panel, when you switch to ā€œContent Scriptsā€ ?

frank 2016-03-16T19:40:59.000080Z

my console output shows "Installing cljs-devtools" so I'm pretty sure that part is fine

2016-03-16T19:41:37.000081Z

start canary with a new chrome user profile, do not use any other extensions than dirac

frank 2016-03-16T19:42:08.000082Z

refers to dirac readme

2016-03-16T19:42:34.000083Z

this will be likely fixed in the next release, but for now you have to get rid of any content scripts in your page

2016-03-16T19:43:29.000084Z

you may as well disable those extensions, but it makes better sense to me to do debugging in clean chrome profile, to avoid any interference from extensions

frank 2016-03-16T19:44:31.000085Z

oh that makes sense. I skipped the user profiles stuff when i was setting up dirac initially because i didn't know what it was

frank 2016-03-16T19:44:44.000086Z

but I'm perfectly happy using canary without my other extensions

2016-03-16T19:45:26.000087Z

also dirac might contain some security issues, so it is not recommended to introduce it into your real chrome profile

frank 2016-03-16T19:45:45.000088Z

yikes

2016-03-16T19:45:47.000089Z

theoretically some malicious code could exploit some dirac vulnerability

frank 2016-03-16T19:50:17.000090Z

hmmmm now the cljs repl never loads in

frank 2016-03-16T19:50:43.000091Z

no more warnings or anything though

frank 2016-03-16T19:50:55.000092Z

oh wait

frank 2016-03-16T19:50:55.000093Z

nvm

frank 2016-03-16T19:50:59.000094Z

pgdn did it

2016-03-16T19:51:04.000095Z

:simple_smile:

frank 2016-03-16T19:51:23.000096Z

ok cool

2016-03-16T19:51:34.000097Z

a pro tip: you can change Dirac extension options on the chrome extensions page, you can instruct it to open as a new window

2016-03-16T19:51:44.000098Z

that way you can open internal devtools to debug dirac itself

2016-03-16T19:51:59.000099Z

there you could spot some extra logging and maybe some errors

frank 2016-03-16T19:52:15.000100Z

ah cool

frank 2016-03-16T19:52:53.000101Z

alright well i guess it's time to update our readme again :simple_smile:

frank 2016-03-16T19:52:59.000102Z

thanks for your help!

2016-03-16T19:53:15.000103Z

no problem