Fork me on GitHub
#beginners
<
2015-07-28
>
grounded_sage12:07:42

Does anyone have the 'Web development with Clojure' book? I've hit a wall pretty quick in the book where I can't get the results from the exercise.

colin.yates12:07:45

I think so, let me check - what is the wall?

colin.yates12:07:15

@grounded_sage: yep - shoot

grounded_sage13:07:52

@colin.yates: Chapter 1 -> Your first Project -> Adding some functionality. The println's are not occurring when submitting a comment.

surreal.analysis13:07:26

Can you copy / paste the code as you have it?

colin.yates13:07:43

are you seeing any printlns_? Can you add some (printlns) in the main (server side) handler and ensure they appear (to make sure you are looking in the right place)

grounded_sage13:07:36

@colin.yates: not quite sure where to put the printlns in the handler haha

colin.yates13:07:42

so put a (println “I CAN SEE THIS”) at line 5

colin.yates13:07:48

then restart the server

grounded_sage13:07:22

It just says this after hitting the comment button - Navigated to http://localhost:8080/

mj_langford13:07:16

consider a println atop save-message

mj_langford13:07:21

line 34 before the cond

mj_langford13:07:54

(println {:name name :message message})

grounded_sage13:07:00

@colin.yates: @mj_langford not seeing any printlns at all

grounded_sage13:07:31

I'm suspecting that is is the 'form-to' on line 23

mj_langford13:07:07

You’re not seing any printlns if you do our suggested tests

grounded_sage13:07:10

I was getting errors evaluating the form in lighttable earlier but it seems to have decided that it's fine now

mj_langford13:07:12

or with the code you presented?

grounded_sage13:07:30

with the suggested tests

mj_langford13:07:20

is the project code downloadable somewhere?

mj_langford13:07:33

I may own the book, but if you know it’s on github somewhere, checking out what’s up would be easier

grounded_sage13:07:54

oh hang on a sec

grounded_sage13:07:48

never mind me. I was looking in the wrong place. Feel like such a noob now haha. Definitely need some sleep 😛

mj_langford13:07:13

sleep is the power animal for learning

mj_langford13:07:21

glad you’re right side up now

grounded_sage13:07:31

I can sleep now simple_smile

colin.yates13:07:08

@grounded_sage: I have learnt many many times to assume it is my fault first and check the basics, hence the println to check the assumptions simple_smile Glad it’s working now.

chris13:07:06

if I remember that it’s always my fault, occasionally it’s not my fault. If I forget that it’s always my fault it’s always my fault

colin.yates14:07:27

@chris - and that’s the recipe for a great marriage as well (or so my wife tells me!)