News for hackers. Stuff that matters.
Re:Python Ecosystem - An Introduction by d0mine on Monday November 28, 2011 @01:12PM (#3286903)
A formidable effort.

It might be matter of taste but recommendations given starting from "Understanding the packages" and to "Install packages that need compiling" are almost harmful.

My preference:

* you should not care what is your `sys.path` looks like. You need it for debugging if something goes horribly wrong. A tutorial might mention it but things like `sys.path.insert(0,..)` should be avoided or accompanied with a big disclaimer (don't use nuclear weapons if you care about the future)

* the same goes for `PYTHONPATH`. It is a hack that rarely needed

* don't use `sudo pip`. System packages should be managed by a system packager. Use `pip --user` or create a `virtualenv`

* `pip` can handle tarballs there is no need for `python setup.py install` in this case.

"Code Like a Pythonista: Idiomatic Python" is worth mentioning http://python.net/~goodger/projects/pycon/2007/idiomatic/han...

Some third-party packages that could be listed (it is subjective):

bpython - interactive prompt; something for tests e.g., pytest, tox, selenium; sphinx - docs; lxml - xml/html, werkzeug - if you talking about web-development; SQLAlchemy - sql; Cython - C extension, ~ Python syntax; async. libs e.g., gevent, Twisted.

Re:Python Ecosystem - An Introduction by mnazim on Monday November 28, 2011 @01:30PM (#3286987)
My indented audience was not the pure beginners. I was targeting for developers coming to python from other platforms. Over past 2 years, if I have learned one thing while training interns, trainees and experience devs in Python/Django, it is that packaging confuses people a lot. apt-get vs easy_install vs pip. That is why I choose to spend most time on package management and virtualenv etc. I think, I should have included stronger indications of this.

In general, your feedback is very good and important. Idiomatic Python specifically is an important resource and should have been included.

I will incorporate your feedback as soon as I can squeeze out some time.

Big Thanks!

Re:Python Ecosystem - An Introduction by watmough on Monday November 28, 2011 @07:13PM (#3288314)
Great Pythonesque pun there! indented==intended, I'm sure.
Re:Python Ecosystem - An Introduction by mnazim on Tuesday November 29, 2011 @02:42AM (#3289515)
This happens to me all the time. My most favorite is when I have to type the word "important", my mind spells "I M P O R T A N T" but my fingers instinctively stop at "import".
Re:Python Ecosystem - An Introduction by mgedmin on Thursday December 08, 2011 @04:00PM (#3331099)
My fingers often type "test" when I want to type "text".
Re:Python Ecosystem - An Introduction by jnbiche on Monday November 28, 2011 @03:03PM (#3287370)
Yes, system packages should be managed by a system packager. Unfortunately, for Debian and/or Ubuntu, those packages are often a full version number behind the PyPi version (I'm guessing it's the same for RHL/Fedora). Be very careful using a system packager like apt-get or yum to install a package that is under active development. In that case, it's often better to install from source or use pip/easy_install. But yes, if it's not a system package, don't use sudo for security reasons (although PyPi is pretty safe).
Re:Python Ecosystem - An Introduction by gbog on Tuesday November 29, 2011 @08:06AM (#3290125)
Agree with your points. Would add emphasis on ipython and heavy use of interpreter, pylint instead of pyflakes, "learn and prefer builtin modules" rule, and Python in a Nutshell on the desk.
Re:Python Ecosystem - An Introduction by mgedmin on Thursday December 08, 2011 @11:53AM (#3329846)
My reasons for preferring pyflakes over pylint: * pyflakes are fast * pyflakes is less likely to flood me with false positives

What are your reasons for preferring pylint?

Re:Python Ecosystem - An Introduction by njharman on Monday November 28, 2011 @11:34PM (#3289069)
> System packages should be managed by a system packager.

You shouldn't be using the system Python. Should compile from source and put in /opt/<name of company>/. And that shouldn't be owned by some random user. So, you should be using sudo.

Re:Python Ecosystem - An Introduction by zokier on Tuesday November 29, 2011 @12:52PM (#3291309)
Building your own Python and using system package manager do not exclude each other. On the contrary, I'd even recommend installing your own built software with your systems package manager