Web Development with Clojure, Third Edition: correct reference code (page 116)
In general, how do I correctly find the reference code that matches each book topic?
More specifically, I am having problems around page 116 testing that the code still works after setting up shadow-cljs. I tried using the reference code called “guestbook-shadow” and still had the same problems. Maybe I am using the wrong reference code. The problems I see are…
- I don’t always see the “WebSocket connected!” in the browser. I have not figured out yet exactly when this happens.
- GET /api/messages response is always 500 “Internal Server Error”
- The page never gets passed “Loading Messages…”
- Sometimes I get this error about invalid gy flags in xregexp.
- I get some error about protocol_mask partition.
- The browser console shows errors about formatters not being installed and another about custom formatters not being rendered.
- On the positive side, the browser console reports App initilized and components mounted and shadow-cljs ready.
How do I debug this? A server-side unit test of get-messages responds with 200, so I think the problem is in middleware or the websocket config. I was hoping the reference code would help, but assuming I have the right one, it is the same, with exception of some SQL files.
I am enjoying the book very much & looking forward to getting past this hump. Thanks for your hard work.
Regards,
Pete
Popular Pragprog topics










Other popular topics










Latest in Pragprog
Latest (all)
Categories:
My Saved Portals
-
None saved yet
Popular Portals
- /elixir
- /opensuse
- /rust
- /kotlin
- /ruby
- /erlang
- /python
- /clojure
- /react
- /quarkus
- /go
- /vapor
- /v
- /react-native
- /wasm
- /security
- /django
- /nodejs
- /centos
- /haskell
- /rails
- /fable
- /gleam
- /swift
- /js
- /deno
- /assemblyscript
- /tailwind
- /laravel
- /symfony
- /phoenix
- /crystal
- /typescript
- /debian
- /adonisjs
- /julia
- /arch-linux
- /svelte
- /spring
- /preact
- /flutter
- /c-plus-plus
- /actix
- /java
- /angular
- /ocaml
- /zig
- /kubuntu
- /scala
- /zotonic
- /vim
- /rocky
- /lisp
- /html
- /keyboards
- /vuejs
- /nim
- /emacs
- /nerves
- /elm