hagsteel / swampdragon

swampdragon
Other
557 stars 73 forks source link

Todo tutorial - route not found #194

Open pektinasen opened 8 years ago

pektinasen commented 8 years ago

I followed the todo tutorial but it just won't work.

redis-server is running (maybe it would be good to state that explicitly in the tutorial that you have to run redis-server).

I created some Todos and TodoItems but the app doesn't get the data. It seems my routers.pydoesn't get discovered.

Running SwampDragon on 127.0.0.1:9999
DRAGON_URL: http://localhost:9999/
Version 0.4.2.2
Debug: True
Quit the server with ctrl+c
---------------------------
ERROR:tornado.general:WebSocket
Traceback (most recent call last):
  File "/usr/local/lib/python3.4/dist-packages/sockjs/tornado/transports/websocket.py", line 60, in on_message
    self.session.on_messages(msg)
  File "/usr/local/lib/python3.4/dist-packages/sockjs/tornado/session.py", line 418, in on_messages
    self.conn.on_message(msg)
  File "/usr/local/lib/python3.4/dist-packages/swampdragon/connections/sockjs_connection.py", line 90, in on_message
    raise e
  File "/usr/local/lib/python3.4/dist-packages/swampdragon/connections/sockjs_connection.py", line 86, in on_message
    handler = route_handler.get_route_handler(data['route'])
  File "/usr/local/lib/python3.4/dist-packages/swampdragon/route_handler.py", line 334, in get_route_handler
    raise RouteException('No route named "{}"'.format(name))
swampdragon.route_handler.RouteException: No route named "todo-item"
abdulwahid24 commented 8 years ago

@pektinasen I am also facing the similar issue, Did you get any solution?

pektinasen commented 8 years ago

Not exactly. I'm not exactly sure what the problem was, but I think it had somethin to do with the ModelRouter. But the chat_example worked out of the box so I used the BaseRouter and some verbs to implement what I needed.