
Top Python libraries of 2016 - jonbaer
https://tryolabs.com/blog/2016/12/20/top-10-python-libraries-of-2016/
======
gtirloni
_" According to the Sanic author’s benchmark, uvloop could power this beast to
handle more than 33k requests/s which is just insane (and faster than
node.js)."_

I keep looking for excuses to focus on Python instead of Go and claims like
this one make me happy. However, when I check the benchmarks I get confused:

[http://www.techempower.com/benchmarks/#section=data-r13&hw=p...](http://www.techempower.com/benchmarks/#section=data-r13&hw=ph&test=fortune&b=2&s=1&l=4ft3pb)

Of course this looks amazing:

[https://magic.io/blog/uvloop-blazing-fast-python-
networking/](https://magic.io/blog/uvloop-blazing-fast-python-networking/)

But, even if in the request/second area Python might be doing great now, won't
there be problem down the line with the GIL? That is, isn't async/await an
island of good performance?

~~~
dom0
> won't there be problem down the line with the GIL?

If you want _parallelism_ in _pure_ Python code, you don't use multiple
threads.

~~~
xapata
Unless you're on Jython or the parallelism is for I/O.

~~~
dom0
I/O isn't pure code.

~~~
xapata
That's certainly one way to interpret "pure Python" but many people use that
phrase to describe code that is using only builtins and standard library as
opposed to community-supplied C extensions.

~~~
dom0
I honestly disagree, but I do recognize how one could see it that way.

~~~
xapata
Yeah, it's a bit of a leaky abstraction since many modules in the standard
library are implemented in C. And the interpreter itself.

------
danso
spaCy going from AGPL to MIT was exciting to me but I see that actually
happened in late 2015
[https://github.com/explosion/spaCy](https://github.com/explosion/spaCy)

~~~
nl
I love Spacy, and recently discovered Textacy: "higher-level NLP built on
Spacy"[1].

It's pretty good.

[1] [https://github.com/chartbeat-labs/textacy](https://github.com/chartbeat-
labs/textacy)

------
rcarmo
I've been using sanic+uvloop+aiozmq (current public draft:
[https://github.com/rcarmo/newsfeed-
corpus](https://github.com/rcarmo/newsfeed-corpus)) and am quite pleased with
this setup for building fast (for Python) asynchronous apps.

The async/await thing is still a bit half-baked (I can't wait for 3.6 to
arrive with more bits, including async generators), but I can see myself using
this more and more -- just don't expect Go-like performance from this setup
for anything but simple processing, since Python is still slow (and 3.x all
the more so until PyPy 3 becomes a reality).

As to the rest of the libraries mentioned, I can't really fault the selection.
I'm still using Python largely because of the ecosystem and sane deployment
options, so I'm always happy to find new, decent libraries.

------
sfilargi
I am wondering why python community focus seems to be shifting away from
gevent and towards the asyncio framework.

Am I the only one who finds the programming style of using async/await
inferior to that of gevent?

~~~
EDevil
You're not the only one. I too am fond of the implicit context switching that
we can have with gevent.

~~~
nine_k
"Explicit is better than implicit", you know.

------
sheraz
Nice list! I did not know about hug. Here's hoping I can remember it next time
I need a basic API.

Is that an issue for anyone else -- that you can't remember all these
libraries exist when you need them?

I guess that what awesome-{python, PHP, golang, etc} are for, right?

~~~
danso
I don't get a lot out of those awesome lists. Not enough is done to filter
them...what would greatly help is to arrange the list as a table, with Github
stars, number of issues, committers, and weeks since last update.

I'm teaching a Python class in winter and put down all the libraries I could
think of that I might need (on top of Anaconda 4.x)...probably will serialize
this later:
[https://gist.github.com/dannguyen/9e5082ac6a80590bfe1541952f...](https://gist.github.com/dannguyen/9e5082ac6a80590bfe1541952fcf5212)

Planning to use AWS significantly this quarter, so awscli and boto3 are at the
top of my list.

~~~
toyg
There are a bunch of apps who can manage your github stars (i can't remember
which one i use, something like "night sky" maybe? Am on mobile). I
periodically review and tag them so they're easy to find when i start a new
project. Then I check my Pinboard.

I wish someone would make an app that merged Github, Bitbucket, Gitlab,
Pinboard and similar dev-oriented collections.

~~~
toyg
Late edit: the app I use is Astral:
[https://astralapp.com/](https://astralapp.com/)

Pretty good for a non-native app ;)

------
pablobaz
It's telling that at least three of these are python 3 only.

------
xarope
Thanks, quite a lot of libraries I wasn't aware of (probably coz I haven't
needed them yet! I still prefer perl for quite-n-dirty scripts, but one of
these days I should try to do the same with python instead).

Anybody want to volunteer to start a resource page for python, kind of like
this one for elasticsearch? [https://github.com/dzharii/awesome-
elasticsearch](https://github.com/dzharii/awesome-elasticsearch)

~~~
modernerd
Like this? [https://github.com/vinta/awesome-
python](https://github.com/vinta/awesome-python)

------
shakna
hug is great fun to work with, and with just a little abuse works great for a
normal website frontend too - but provides you with a canonical endpoint list,
and decent typing.

~~~
njharman
hug (like Falcon) has way lot of "magic". It seems to be a trend (at least in
python webdev world). I have mixed feelings about this.

Hug appears to be one of those things that is great when all you're doing is
very simple but quickly turn into morass of fighting the opinions and magic of
framework when doing anything "real".

Also (good) CLI is so different than HTTP that I see only sadness in mashing
them into same interface. like having to repeat large amounts of boilerplate
decorators to get it to do what you need. The chaining seems it would help
with boilerplate at least.

Still, I hope I'm wrong. I want to have a hug. Falcon's lack of validation and
documentation means it solves only about 10% of the problem.

~~~
mhd
Is that really a trend? I remember web2py getting a lot of flack because of
the amount of magic it used.

~~~
bjt
Feels more like a pendulum. I remember one of the big pre-1.0 branches of
Django was called "removing-the-magic".

------
red2awn
Bokeh and Sanic+uvloop is pretty interesting.

