Skip to content

Instantly share code, notes, and snippets.

@gdw2
gdw2 / flask_geventwebsocket_example.py
Created March 29, 2012 16:19 — forked from lrvick/flask_geventwebsocket_example.py
Simple Websocket echo client/server with Flask and gevent / gevent-websocket
from geventwebsocket.handler import WebSocketHandler
from gevent.pywsgi import WSGIServer
from flask import Flask, request, render_template
app = Flask(__name__)
@app.route('/')
def index():
return render_template('index.html')