Fork me on GitHub
#clojurescript
<
2016-01-28
>
yenda11:01:13

Is there people here with jdk 8u72 ?

yenda11:01:18

Do you have troubles with cljs ? I have different projects with the same client server architecture and bootfile posted in #C053K90BR

yenda11:01:11

When I delete the target dir after java update there is no warning when launching the task

yenda11:01:25

But the console says the app is undefined

yenda11:01:39

Rollback to u66 fixes this

dnolen12:01:22

@yenda haven’t heard anything about JVM version problems, I’m running 8u72 on OS X

yenda12:01:25

@dnolen: java or jdk ? maybe it is boot-cljs

yenda12:01:28

it seems like it compiles but I get I get "ReferenceError: project1 is not defined" in the js console

yenda12:01:44

@dnolen: ok nvm this is not the prolem. Somehow when switching projects on the same port the browser keeps looking for the previous project

yenda12:01:59

in private mode it looks for the right one

yenda12:01:52

I did a reboot after the rollback and the fact that there was a java update right before the problem occurs was a coincidence

yenda12:01:19

simple workaround when working on simultaneous projects is to disable cache -> refresh -> enable cache again

jimmy12:01:03

@yenda: does hard reload ( ctrl/cmd + shift + R ) work for you ?

yenda13:01:03

it's looking at the right project after a hard refresh

yenda13:01:11

but it stilll doesn't find it

bbss14:01:57

I have some trouble using @cemerick 's friend library with slacks oauth2. Following instructions for a oauth2 plug-in here: https://github.com/ddellacosta/friend-oauth2/wiki and it seems that slack has the same mechanism as Google oauth2 with a code and state param that get sent to a redirect url.

bbss14:01:01

I've set-up an ngrok tunnel to my local so I can visit the page and go to slack and authorize the requested scope. The slack page then sends a 302 to the ngrok with code and state params but that seems to do another 302 looping forever. I must have done something wrong with the configuration but I have trouble figuring out what.

bbss14:01:59

Anyone experience with oauth2 that can shine some light?

ddellacosta14:01:35

Sorry bbss, I’ve been terribly neglectful of that library lately

ddellacosta14:01:54

but in any case, if you give me more information about what the problem is, I can help—as it is it’s hard to tell what you are experiencing.

ddellacosta14:01:10

(or try to help at least)

bbss14:01:25

Oh great! Don't worry about it, I am already pretty happy with what it seems to offer

ddellacosta14:01:39

…although, if you aren’t wedded to friend yet I would consider something else, check out buddy too

bbss14:01:13

I can make a snippet of what I have, I am fairly new to ring and such, so no, not wedded to friend.

ddellacosta14:01:30

so, those are two totally different discussions but first of all why don’t you try giving me a gist or whatever of what you have, and describe your problem further, and I’ll see what I can do. BTW this probably belongs in #C03S1KBA2 vs #C03S1L9DN, but we can also take it to DM

ddellacosta14:01:54

looking, will ping you directly

bbss14:01:23

I put it in clojurescript because I figured it might be related to that I am hosting the page as an spa not by server side rendered html.

bbss14:01:41

I don't see any macro magic so far so that's probably not it.

yenda14:01:11

buddy replaces friend now ?

ddellacosta14:01:30

yenda: I don’t want to say anything that sweeping or speak for the Clojure community there. Just my opinion that it’s worth reviewing all the options that are out there.

ddellacosta14:01:44

and having used buddy elsewhere, I like it

yenda14:01:30

I tried friend when I first started clojure but I gave up I had too much to learn first, I'll be needing some auth library soon

roberto14:01:33

I’m in the friend camp

roberto14:01:39

I couldn’t wrap my head around buddy

ddellacosta14:01:34

yeah, I don’t necessarily want to make any claims about which one is better—as I said, good to review both (and anything else that is out there that I’m unfamiliar with) and see what you like

jarodzz15:01:27

hi. guys. do we have anyone maintaining http://clojuredocs.org?

jarodzz15:01:37

when i was checking golang, the sample code on the page is editable and you can change it and run it to see the difference

jarodzz15:01:26

so i am thinking, not sure if it's possble, can we enable clojurescript in the page, we don't even need to eval the code, so it's no risk. we just need to have it translate to js and let js run inside browser

dnolen15:01:25

@jarodzz: far as I know the maintainers of that site do not hang out it here

dnolen16:01:29

Zachary Kims runs it

jarodzz16:01:44

@dnolen, hi, got it. just sharing some thoughts

jaen16:01:04

@yenda: contrary to roberto - I'm in the buddy camp because I couldn't wrap my head around friend.

jaen16:01:07

So it probably depends.

jaen16:01:57

If you're familiar with Ruby ecosystem a good comparison would be that friend is more like devise (tries to everything) while buddy is more like sorcery (a set of building blocks for auth).

jaen16:01:15

But that's just how it appears to me personally. Buddy just feels simpler to use.

scottbale16:01:17

Running thru the quickstart. Is there any reason the browser repl wouldn't work over the internet (as opposed to via localhost)? I'm attempting to start the repl on an ec2 instance. I'm at the point where my browser is successfully fetching every resource except this one (according to chrome dev console) : http://<ip address>:8080/repl?xpc=<...omitted...>robots.txt%22%7D console points to crosspagechannel.js:486 Meanwhile the repl just hangs with the message Waiting for browser to connect ... This is Java 8, cljs 1.7.228. I'm using a nonstandard port (8080) for the repl.

jaen16:01:03

First hunch would be - what do you bind to? localhost / 127.0.0.1 or 0.0.0.0?

scottbale16:01:46

@jaen not sure, checking… but wouldn’t the fact that the browser is able to retrieve all other resources indicate it’s not a problem with binding?

jaen16:01:21

Hm, fair point

jaen16:01:40

Also looking at the source I can't seem to find an option to specify hostname to bind to.

scottbale16:01:13

@jaen so perhaps crosspagechannel.js is just implicitly hardcoded to localhost? (I’m just beginning to browse through that file.)

jaen16:01:22

so maybe try (assoc (cljs.repl.browser/repl-env) :host "0.0.0.0") for your browser REPL?

jaen16:01:27

Kidn of a shot in the dark, but maybe

scottbale16:01:44

@jaen will try, thanks, this gives me something to go on at least! simple_smile

scottbale17:01:40

It was user error all along! (Meaning, I had mistyped an IP address.) Increment the stupid counter. (Thanks again @jaen)

kamn18:01:33

On the State of Clojure(script) summary it mentions that a lot of people feel it is hard to debug generated JS but doesn't source maps solve that? I have not had major difficulties. Or at least it is not any harder than normal js

jaen18:01:38

Maybe they didn't know about cljs-devtools : D

dnolen18:01:10

@kamn yeah as @jaen is alluding - I think they don’t mean step debugging they mean JS printing of CLJS values

kamn18:01:08

Ah, that makes more sense

jaredly19:01:11

the source-maps don’t respond well to breakpoints too

dnolen19:01:12

@jaredly: they work OK and can probably be enhanced a bit

dnolen19:01:20

the main issue is that Clojure isn’t line oriented

dnolen19:01:05

the other issue is fancy macros like core.async

jaredly19:01:15

there are a ton of lines that I can’t put a breakpoint on though 😕

dnolen19:01:20

the former would be surmountable if JS source map support in browsers actually respected column information

dnolen19:01:07

@jaredly I suspect there are a couple of simple enhancements that can be made - somebody just has to do it

dnolen19:01:19

I already sunk way to much time into myself

jaredly19:01:30

cool maybe I’ll look into it

dnolen19:01:00

all the really boring stuff has already been done

dnolen19:01:25

I think this would mostly be an issue of not emitting enough source map info at key points

jaredly19:01:40

ok cool (gif didn’t work)

dnolen19:01:43

@jaredly: yeah definitely encountered cases like that before

dnolen19:01:27

@jaredly another thing to be careful of is difference between browsers

dnolen19:01:38

I’ve seen cases where it works in browser X but not browser Y

dnolen19:01:04

and it should be determined whether that is a bug in a browser X or Y or a friendly attempt at guessing in browser X or Y

dnolen19:01:49

which is why I haven’t looked at it myself - quite of bit of sleuthing to do that doesn’t have much to do with writing code

spinningtopsofdoom22:01:20

@dnolen: Are there JIRA stories for source map enhancement?

dnolen22:01:01

@spinningtopsofdoom: there aren’t since nobody has actually done the research to actually describe some specific task(s)

dnolen22:01:42

happy to see someone do the leg work necessary to actually enumerate all the various ways in which source mapping is going wrong

dnolen22:01:56

then tickets for each reasonably sized task

spinningtopsofdoom22:01:04

I'd be happy to work on fixing source maps but haven't run into any problems myself. @jaredly I'd be happy to help you if you could give me broken source map examples

jaredly22:01:19

I’ll see if I can come up with a smallish example

dnolen22:01:39

more than happy to point out all the relevant places in the compiler

dnolen22:01:00

there’s really not that much code involved here though

dnolen22:01:01

searching for *source-map-data*

dnolen22:01:15

will point out all the places where we record location information

dnolen22:01:29

everything else is just the standard source map v3 transformation stuff

dnolen22:01:34

(assuming there aren’t bugs in that of course)

spinningtopsofdoom22:01:37

Thanks I always thought it was more involved then that