4 ms·
I don't see what's modern about it. Those tools have been existing for years, and as always with Python, they serve only a subset of the Python users. Not tha
by BiteCode_dev 6y ago
I don't see what's modern about it.
Those tools have been existing for years, and as always with Python, they serve only a subset of the Python users.
Not that it's a bad article. If you don't know about them, give it a read, it's good to know it exists and the post is well written.
But don't think it's the ultimate stack or whatever.
And if you learn Python, you should always strive to master the basics first:
- installing python.org for windows and mac, or apt/yum on Linux (those ones are tricky, it's more than just the "python" package to get pip and venv)
- don't try to get the latest and greatest version (which is 3.8, or 3.9 alpha today). 3.6 is great already and is wildly available. I personnally strive for 3.7 now, but I'm happy with 3.6 if I don't have to use asyncio. So get the most modern version that is easy to install for you.
- be comfortable with "-m", the "py" command on windows, "pip" (-m, --user, install, install -r, freeze), and "-m venv".
- make sure you understand what the PYTHON PATH is and how it works regarding the import system
- know how to configure your favorite editor to work with those
Once you have those basics, you can go and try whatever have you: peotry, pyenv, pew, virtualenvwrapper, pipenv and so on. It will be easy because you will have a solid understanding of where it comes from and how it plugs in into the ecosystem. You will be able to chose if they are worth it or not for you. And more importantly, when you will have to move away from them (because of work, because they don't suit you, because they are abandonned...), you will always be able to fall back to basics.
But franckly, there are so many things that you should be learning before those extras: pdb, black, pylint, zipapps... Or even concepts like generators, decorators, unpacking, etc. They all have a better value for the time you spend on them than learning a new "modern" stack.
Not that it's not useful to have a modern stack. I update my stack all the time.
I'm currently using pip + pew + doit + nox + pytest, and I'm experimenting with dephell.
But it's my full time job. I'm an expert.
Most Python devs have a much limited amount of resource to spent in learning stuff. They have deadlines, and other stuff to care about than Python.
I know because I go from company to administrations to students to train them, and it's always the same: they chose Python because it's an efficient use of their time.
- greenshackle2 6y agoContext is important. Developing applications vs libraries vs scripts is different, developing internal company software vs external software is different. If you're shipping a package on pypi, you will want to develop and automatically test using multiple Python versions and maybe a range of versions of your dependencies. Having good tools to manage multiple sets of Python versions and dependencies and parallel automated testing is a godsend. If you're writing an internal or web application that will run only in a single well-known environment, pip + venv + pytest might well be good enough.
- BiteCode_dev 6y agoSure, but again, there is nothing modern about this. And certainly not, hyper modern. Besides, if you want to develop and automatically test using multiple Python versions and a range of versions of your dependencies, none of the tools from the article will do it. At best they are one of the ways to get dependancies before you use a tool to do it. You can do that with raw pip and venv as well. What you need though, is something like tox, which has existed for years. As mentioned in my comment, I personnally use nox for this, as it is, ironically, more modern to my taste. Nox doesn't care if you use poetry, pew, virtualenv wrapper or venv manually. I would certainly advice to learn something like nox or doit before learning poetry, for example. Now I don't advice against learning poetry, mind you. It's a good tool, well written. Pyenv is another matter entirely. The day one really need what pyenv gives you to the point it's worth investing in it, they can discard all my advices entirely, as they would have the skill and experience to not need my explanations.
- greenshackle2 6y agoNot sure if you've read just the first article, it's a whole series, they cover nox later on. I don't see how this stack is "hypermodern" either, mind you. My point was just that these articles and other like it tend to omit context completely. What is this stack good for? Who should use it? Who shouldn't? Without answering these questions the articles are not all that useful, or even could be harmful, if a dev who doesn't know better apes a complicated stack for no good reason.
- BiteCode_dev 6y agoI missed that it was serie, indeed.