The Hitchhiker’s Guide to Python
docs.python-guide.org
docs.python-guide.org
its "grr, use python 2, unless, ugh, if you want to do what everyone recommends the average person do, use python 3 I suppose" which is just silly
The article is talking to me. To paraphrase: Use Python 3 unless you have a good reason to use Python 2.
That advice is solid and not really a recommendation of Python 2.
However I have now submitted to the baying hounds of doom and moved to 3 on most stuff for the reasons of "having a future", security, etc. Was pushed. Didn't jump.
One thing I will give 3 though is the stupidly simple thing that 3/2 = 1.5. Quite often I have to fire up python for a quick and dirty calc and it's much better not to have to remember the integer division quirk.
The most important thing is that I can get a relatively vanilla Python program running on any computer that I bump into, without creating a potential future headache for the person who owns that computer. WinPython is almost like an isolated environment.
But at the very least, if their instructions ensure that you can get an installation to the point of running the tutorial programs successfully, and learning Python rather than fussing with installers, I'm OK with it.
Edit: Aha, Anaconda seems to be tailored towards data analytics and includes R.
I find it's easy for me to port one of my apps to a new computer and get it running quickly. This is handy because I share my stuff with colleagues worldwide, and also am deploying things in our manufacturing plant.
Note that I happen to be in the "scientific Python" camp, and also use Python for controlling scientific instrumentation and test equipment.
> Flask is a “microframework” for Python, and is an excellent choice for building smaller applications, APIs, and web services.
> Flask is default choice for any Python web application that isn’t a good fit for Django.
Not very helpful. What is the threshold between "smaller" and larger applications? What makes an app not "a good fit for Django"? I've never found clear answers to these questions, mostly just vague opinion. This Hitchhiker's Guide, a self-proclaimed opinionated guide, could really take off if it got some opinion and backed it up with real rationale.
I would choose Pyramid over Django if I want to customize and do everything myself. Whereas if I want a very active and very mature community of plugins, I would stick with Django. When it comes to a secure framework out of the box, Django is definitely the winner out of all Python web framework.
My reasoning is that any project that needs as much as Django has built-in is going to need the custom work you put into a Pyramid project anyway, so you might as well start off there and use a nicer API from the get-go. Anything less is Flask territory from my point of view.
I started web development using Django, then tried Pyramid, and finally moved on to Flask. And since picking up Flask, I haven't gone back...and I wouldn't go back to "heavier" frameworks...although I have considered taking a peak at a couple other micro-frameworks.
I have a couple strong (personal) reasons for this (read: YMMV), but the biggest thing for me is I see web development moving towards a strict separation between front-end and back-end (SPA's, web assembly, microservices, etc.) as well as multi-model/multi-storage. Neither of which lend itself well to all-inclusive framework solutions IMO.
At the end of the day I guess the take away is to remember that it's great to have so many strong frameworks each with its own strengths to choose from in the Python ecosystem.
and, when you compare sqlalchemy to django's ORM -- Sqlalchemy is more powerful. i can't give specific reasons why. I think zzzeek is just insanely focused and that beat out design by committee. (mitsuhiko too incidentally). maybe that's wrong, just my intuition. sqlalchemy is probably the best orm in _any_ language.
there's a huge django community that would disagree, but you don't see concrete reasons why django is better than flask, but flask is better than django for the simple reasons i mention.
they're not different meant for large and small apps. everything django can do flask can do better, cleaner, simpler.
More like children of the same era. Django is older.
If you think "golly gosh, maybe some abstraction between the database and the code, hell, maybe even one of those wonderful Model View Controller things, whatever they are, would be great fun" then probably go for django or any other MVC framework
Flask can do all that, but it requires your help to achieve it. You get control over what ties with what. Django is already set up for usage, just put your code in one of three boxes, and done, but you can't decide what those boxes are or how to use them. It brings a standard structure but you lose control.
from __future__ import towel
HTH. HAND."Sigh"... Marvin.