Skip to content

Latest commit

 

History

History
50 lines (44 loc) · 1.04 KB

README.md

File metadata and controls

50 lines (44 loc) · 1.04 KB

Flask-SocketIO

##create virtual env

	virtualenv --no-site-packages  env   
	cd env   
	source env/bin/activate   

##exit env

	deactivate   

##install

	pip install --upgrade pip   
	pip install flask-socketio   
	pip install gevent-websocket   
	pip install flask   
	pip install socketIO-client   
	pip install flask-debugtoolbar
	pip install flask_restful

##test

###Server namespace = 'test' file : server/app/templates/index.html server/app/socket_even.py

	cd server
	python app.py  

###client namespace = 'test' file : client/client.py

	python client.py   
	DEBUG:root:localhost:5000/socket.io [transport selected] websocket   
	DEBUG:root:localhost:5000/socket.io [heartbeat reset]   
	socketIO init done   
	DEBUG:root:localhost:5000/socket.io [engine.io noop]   
	DEBUG:root:localhost:5000/socket.io [engine.io pong]   
	DEBUG:root:localhost:5000/socket.io [engine.io pong]