Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
I like https://effectivepython.com/ Also just reading Norvig’s annual Advent of Code implementations usually provides some insight on how to write elegant and concise Python code.
Think Python, 3rd Edition
71–80 of 126 posts
Re: Think Python, 3rd Edition
#72Re: Think Python, 3rd Edition
#73Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
Re: Think Python, 3rd Edition
#74Earlier quoted context omitted.
That is correct. Honestly I’m not sure this is a good use case for Python but it’s definitely possible. I’ve used the RabbitMQ + gevent + multiprocessing pattern in the past and it works but I find the code extremely hard to reason about. If I were doing it again from scratch I’d probably choose another language with better concurrency primitives.
> Honestly I’m not sure this is a good use case for Python but it’s definitely possible It definitely isn't, but this is a new role with a rushed timeline in a place dominated by Python. > and it works but I find the code extremely hard to reason about This is also a major concern of mine.
It may feel limiting but my advice would be to keep all the celery job queue stuff isolated from your server, especially if you are using an async web framework. Have your web server just put all the jobs in the celery queue and let it handle executing them, regardless of whether they’re cpu or io-bound. If you try to optimize too much by doing something like leaning on celery for cpu-bound tasks but letting your web server handle the io-bound ones you’re going to be in for a world of hurt when it comes to both debugging and enforcing the order of execution. Celery has its warts but you’ll at least know where in the system your problem is and have reasonably good control over the pipeline.
Re: Think Python, 3rd Edition
#75Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
Re: Think Python, 3rd Edition
#76Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
Re: Think Python, 3rd Edition
#77Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
I learned Python starting with 1.5.2 from the official documentation and think it's a good resource. https://docs.python.org/3/tutorial/index.html https://docs.python.org/3/library/index.html Whenever a new version is released, I read its What's New documentation. Beyond that, I like to read source code, both for the stdlib and popular third-party packages. This advice generally applies when I'm learning any new lang…
Python official docs are not completely horrible, but compared to most other popular languages (Kotlin, Scala, Rust, Go at least), the Python official docs are kind of meh.
I suppose Python docs beat C and C++ which do not have official docs besides the spec. (not counting K&R and Bjarne's books).
Also I guess Javascript does not have official docs (ie MDN is not official)
Re: Think Python, 3rd Edition
#78Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
Fluent Python is good book at that level, and works as a good reference book while working too.
Re: Think Python, 3rd Edition
#79Apologies for changing the subject, but aside from real world experience (which I have and am getting at work), is there a resource of similar quality for more intermediate/advanced Python programmers? I always feel like there's a big chunk of the language or stdlib I do not know.
Re: Think Python, 3rd Edition
#80What is a good book for learning Python when you already now some/many other languages?
Just follow the tutorial (yes, really) https://docs.python.org/3/tutorial/index.html