Quantcast
Channel: Planet Python
Viewing all articles
Browse latest Browse all 22462

PyCharm: Interview with Pedro Kroger, Author of Modern Python Development with PyCharm

$
0
0

coverPublished earlier this year, Modern Python Development with PyCharm by Dr. Pedro Kroger reveals the best Python programming practices while using PyCharm. Relying on his 20 years of extensive programming and using different programming tools, in his book Dr. Kroger delves into essential topics of setting up PyCharm for your needs and then get the most out of its numerous development features, ranging from the editor basics and essential shortcuts all the way to specialized tools for remote development, version control and web programming. Modern Python Development with PyCharm is recommended for both beginning Python programmers and those coming to PyCharm from other IDEs or text editors.

Our own Dmitry Filippov seized the opportunity and interviewed Dr. Kroger. Read on to learn more about the man, his programming experience and his vision.

- Hi Pedro, could you tell us a bit about yourself and your day job?

I’m a professor based in Brazil, where I teach music composition, harmony, counterpoint, and music analysis. Although my main background is as a modern classical composer, I’ve been programming for more than 20 years and combining these two skills. For instance, for my Ph.D. I wrote a meta-language for sound synthesis using XML and Tcl. My main research interest these days is to write programs to analyze and understand music. I’ve used Tcl and Lisp in the past, and now I use mainly Python. For example, now I’m writing Python programs to analyze the similarities in Mozart’s, Beethoven’s, and Haydn’s string quartets. It’s a lot of fun!

- Your book says you’ve been using Emacs for more than fifteen years. As a Python programmer, could you tell us why you switched from this great editor over to PyCharm and what it is that still makes PyCharm your IDE of choice?

I still use Emacs a great deal, only less than before. For example, I have yet to find a faster way to rename files in a directory than using dired. At one time I was doing everything using Emacs, including reading email and browsing the web. Although I love its extensibility, Emacs is starting to show its age. This post I wrote years ago shows the length you have to go to get some useful features such as code completion and navigation to work. I love that PyCharm has all these features I mentioned in the post out-of-the-box: all I need to do is to define the Python interpreter and start coding.

- What are your favorite PyCharm features that you can’t imagine working without?

PyCharm has a lot of killer features (fantastic code completion, great debugger, etc.), but I think the biggest selling point for me is the integration of features and languages. Everything works out of the box and in similar ways in Python, JavaScript, HTML, CSS, etc. Also, I have a horrible memory, so code completion and inspection helps a great deal.

- How much time did it take you to learn PyCharm from scratch? Do you think learning tools is a big part of a developer’s trade?

It didn’t take too long, since it has a gentle learning curve. On the other hand, it’s packed with features, so I guess I’m still discovering new things every day.
I think learning tools is essential, even if only to know how things are done on “the other side.” For instance, I’ve been learning Vim to understand how I can be more efficient editing text (and PyCharm has a great Vim plugin!).

- Every serious project is not only about Python. It often involves testing, isolation of environment, deployment, version controlling, database management. How does Pycharm help you manage all this stuff?

I love that PyCharm has support for all these things, but to be honest I use the command line or specialized tools (such as Tower for version control, Fabric for deployment) for most of these tasks. I’ve been using them for so long that they are second nature to me. I do run tests using PyCharm though. I love to see the big green bar :-)

- What other developer tools help you be more productive? Would you recommend any to other Python developers?

It’s hard to make recommendations because everyone has a different need. I guess the best thing is to focus on the basics: learn your shell, version control tool, editor, etc., and try not be religious about it. Use the best tools for the best job.

- There are several Web frameworks backed by Python, including Django, Flask, Pyramid, and Google App Engine. What are your personal and professional preferences?

I’m not much of a web developer, although I have done some small projects using Django and Flask and I like both. If I were going to work professionally as a web developer, I’d pick Django. I like the focus on batteries included, great documentation, and stability.

- Python is an open-source project and everything around it is open source as well. In your opinion, how does the open-source concept influence and shape the enterprise software? Have you used any open-source projects in your professional career? Which ones do you like the most?

I think free/open source is fundamental. Many things we take for granted today (such as Google search) was built using open source. Also, open source is essential for education. I use a lot of open source programs, including Linux, FreeBSD, Music21 for music analysis, LaTex, Pandas, and so on.

- There are two major versions of Python currently co-existing: 2.x and 3.x. What do you think about the current state of Python? What’s your take on the future of the language?

I don’t understand the naysayers. Python 3 is a great language and its future is bright. Unlike some languages that tried to reinvent themselves and never delivered, Python 3 is here now and most big and important libraries have been ported. I think 2016 will be the year of Python 3 :-)

- What do you think makes Python unique as a language?

Python is a great language because it’s super powerful and yet has a gentle learning curve, not to mention loads of libraries and tools. I have taught both Lisp and Python to non-programmers and, although one can learn the basics of both in a few hours, Python wins for having more available out of the box.

- What do you think about Python as a language for teaching and learning programming? How can tools help learners to harness the learning curve?

As I mentioned in the previous answer, Python is a great language for teaching. When I teach, I like to start by using a functional approach (since most people have learned functions in high school) and move to classes afterwards. In same languages you have to start with classes from day one, which in my experience makes things more difficult for the beginners. The main roadblock when I was teaching was finding an appropriate editor for the students. If the tool is too difficult, the student has two things to learn; the language and the tool. I haven’t tried the PyCharm Educational Edition yet, since I’m not teaching programming these days, but it looks great!

- Please recommend two other books on development you enjoyed reading recently or just consider important.

The development books I read these days are specific to what I’m working on. For example, the last book I read was Python for Data Analysis, by Wes McKinney, which is only suitable for those interested in data analysis. Although these are not Python books, I highly recommend Structure and Interpretation of Computer Programs by Harold Abelson and Gerald Jay Sussman and Paradigms of Artificial Intelligence Programming by Peter Norvig. There is a lot of beautiful code in these books.

- Thank you for the interview, Pedro!

You can buy Modern Python development with PyCharm on Dr. Kroger’s website. He also runs his own blog, so don’t forget to check it out!

Dr. Pedro Kroger

I’m a programmer, classical composer, bootstrapper, and class clown who loves teaching and traveling. I live now in colorful Salvador (Brazil). I also lived in Austin, San Francisco (USA), Rome (Italy) and London (UK). more …


Viewing all articles
Browse latest Browse all 22462

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>