heroku-python / flask-sockets

[DEPRECATED] Alternative: https://github.com/miguelgrinberg/flask-sock
MIT License
1.74k stars 167 forks source link

Segmentation Fault #35

Open lagosnomad opened 8 years ago

lagosnomad commented 8 years ago

Hi, i'm completely new to flask sockets and sockets in general. I installed flask_sockets successfully, copied the example code from the readme i got a segmentation error when i ran it. screenshot from 2016-06-07 11-43-11

kennethreitz commented 8 years ago

This is very strange, and I suspect an issue with gevent. Perhaps update to the latest version of gevent / play around with an older version if needed and see if the problem persists.


P.S. That's a crazy terminal font! I don't think I'd be able to get any work done with that at all. Is it a dyslexic-easing typeface? Doesn't look monospaced at first glance, but I think it actually is. Interesting.

lagosnomad commented 8 years ago

My gevent is up to date -- says pip. I'll play around with older versions. You mind suggesting any particular version? screenshot from 2016-06-09 11-00-21

Also, here's a link to my font. I see you are interested in it "too". Hangyaboly - http://www.dafont.com/hangyaboly.font

bcollazo commented 7 years ago

This also happened to me. Downgrading from gevent 1.2.0 to gevent 1.0.2 made the segment fault go away. This happened only on my MacBook Air (not on some other Ubuntu computer I own).

The original problem for me was that using the flask_sockets.worker gunicorn worker made gunicorn to keep binding/creating workers indefinitely (with new pids each). That is, 'gunicorn -k flask_sockets.worker app:app' would spam 'Binding worker ....', while 'gunicorn app:app' would correctly only bind 1 worker. Again, this only happened on my Mac (on my Ubuntu gevent 1.2.0 worked fine).

Anyhow, not sure what the real problem is, just thought I'd share my experience! I'm staying on gevent 1.0.2 for the time being.