Can't Get Working Install on Debian Due to Gevent Incompatibility

267 views
Skip to first unread message

BSigns

unread,
Dec 9, 2013, 2:10:49 PM12/9/13
to plivo...@googlegroups.com
I'm having trouble getting a working install of the Plivo framework due to issues between Plivo and Gevent.

The install itself works, and plivo is up and running. However, if I try to handle an inbound call that touches Plivo in any way, I get this in plivo-outbound.log:

>> 2013-12-09 12:41:48,416 plivo-outbound[7312]: ERROR: (1) AssertionError: Impossible to call blocking function in the event loop callback

This appears to be related to an issue where plivo won't work with recent versions of Gevent.  See this issue: https://github.com/plivo/plivoframework/issues/96

No problem, right?  I just need to install an older version of Gevent?

Well, the problem is that plivo_install.sh script already tries to do that, but it gets thwarted.  These lines:

># force installation of gevent 1.03a

Don't actually install that older version.  it appears, instead, to install the latest version of gevent.  Here's a cut and paste from what the install script outputs:

>  Downloading/unpacking gevent
>  Downloading gevent-1.0.tar.gz (1.4MB): 1.4MB downloaded
>  Running setup.py egg_info for package gevent

I did try changing that "pip install" line, but it runs into an unrelated issues...installing gevent directly from github requires cython, which then fails for another unrelated reason (cython complains about encoding in some of the base plivo files).

And, to cut to the chase:

Is there some simple modification I can make to the plivo_install.sh script to get it to install the older version of gevent?

Things I've tried:
- Removing --upgrade from the pip install command.  It still installs the newest version of gevent
- Changing the url to an older version of gevent on github. I tried this, but installing from github invokes the cython dependency and subsequent failure. (see https://github.com/surfly/gevent/issues/258)
- I also considered doing it by hand, but Plivo leverages python virtual environments, and there's a fairly complex chain of variables in the script that have to be set correctly for that to work.

Lastly, FWIW, as far as I can tell, this means that nobody can run the simple "Get Started" instructions and get a working install of the Plivo framework.





 




BSigns

unread,
Dec 9, 2013, 3:42:24 PM12/9/13
to plivo...@googlegroups.com
I finally hit on something that worked.

I replaced this line in plivo_install.sh


>pip install  --upgrade -f http://gevent.googlecode.com/files/gevent-1.0a3.tar.gz gevent

With this:

>pip uninstall gevent

And re-ran the installer.  It does prompt me for confirmation during the install, but everything is working now, no "AssertionError: Impossible to call blocking function in the event loop callback" problems with inbound calls.


BSigns

unread,
Dec 9, 2013, 3:52:47 PM12/9/13
to plivo...@googlegroups.com
Note that in this:

>pip uninstall gevent

The -Iv switch is "dash capital I  lowercase v".   The I looks like a lowercase L, but it's not.    'I' and 'l', unfortunately, look the same in the groups.google.com default font. Changed it to courier above so it's more clear.

Mike

unread,
Dec 9, 2013, 3:55:05 PM12/9/13
to plivo...@googlegroups.com
Thanks for sharing the details .

So you are doing in plivo_install.sh :

pip uninstall gevent
pip install -e git+${PLIVO_GIT_REPO}@${BRANCH}#egg=plivo


--
You received this message because you are subscribed to the Google Groups "Plivo Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to plivo-users...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



--
--

Michael Ricordeau
Co-Founder Plivo

mi...@plivo.com
http://www.plivo.com
twitter @mricordeau
linkedin http://fr.linkedin.com/in/michaelricordeau

BSigns

unread,
Dec 9, 2013, 5:00:02 PM12/9/13
to plivo...@googlegroups.com
Yes, that's correct.  If it were a patch, it would look like:
   
  # force installation of gevent 1.03a
- pip install  --upgrade -f http://gevent.googlecode.com/files/gevent-1.0a3.tar.gz gevent
+ pip uninstall gevent
  pip install -e git+${PLIVO_GIT_REPO}@${BRANCH}#egg=plivo

Mike

unread,
Dec 9, 2013, 6:11:00 PM12/9/13
to plivo...@googlegroups.com
added the patch in last commit !

jyoti....@emreach.com

unread,
Sep 23, 2014, 8:41:01 AM9/23/14
to plivo...@googlegroups.com
I just did a fresh install of plivo on 23/09/2014 and the problem is still there. Should i manually do the changes and install again.

Sann Min Win

unread,
Sep 11, 2017, 1:16:48 PM9/11/17
to Plivo Opensource Users
Reply all
Reply to author
Forward
0 new messages