Would be nice, by the way, if they could release the source code. Having such an example of a Flask app would be very useful for the community.
Would be nice, by the way, if they could release the source code. Having such an example of a Flask app would be very useful for the community.
Vine didn't use a lot of Flask. The main piece that was used was routing (i.e. @app.route). Everything else was custom. Even flask.g was replaced with something that can propagate context properly across greenlets (the method of concurrency we chose), without a lot of overhead. If you're curious, that piece eventually became https://github.com/mikekap/gbatchy though I can't say that's well supported now.
The main takeaway from that codebase is: async needs to be part of the language. Having it be bolted on leads to...unpleasant hacks. I think Python 3.5+ is heading in the right direction there, but Vine was stuck in 2.7-land forevermore (mostly because we wanted to keep pypy compatibility even though pypy was never rolled out; not the best reason).
Personally I like having a big codebase as an architectural reference when I'm trying to learn a new framework. The Patreon source code (Flask too) is public, by the way.
And you also have here a direct download of the full leak, including the database:
https://archive.org/details/B93B1C2921EFF0846DA268968755D01B...