Skip to content

Instantly share code, notes, and snippets.

@tocttou
Created August 20, 2016 10:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tocttou/c0885ce4077d972765b00c56f79b5445 to your computer and use it in GitHub Desktop.
Save tocttou/c0885ce4077d972765b00c56f79b5445 to your computer and use it in GitHub Desktop.
import cvfy
app = cvfy.register("nongh:0.0.0.0:5237349:5001:8003:localhost")
@cvfy.crossdomain
@app.listen()
def getsizes():
cvfy.sendGraphArray([
[
{ 'x': 'cat', 'y': 2 },
{ 'x': 'dog', 'y': 5 },
{ 'x': 'rabbit', 'y': 8 },
{ 'x': 'mouse', 'y': 9 },
{ 'x': 'horse', 'y': 13 }
],
[
{ 'x': 'cat', 'y': 2 },
{ 'x': 'dog', 'y': 5 },
{ 'x': 'rabbit', 'y': 8 },
{ 'x': 'mouse', 'y': 9 },
{ 'x': 'horse', 'y': 13 }
]
])
return 'OK'
app.run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment