I’ve been working on learning how to program in Python for what feels like forever. Literally. I’m not even joking.
I first tried to learn how to program like 20 years ago when I was learning Linux (slackware baby!). I read a bunch of stuff and everyone told me Python was where it was at for learning how to script and program. Truth be told, I never really got past print(‘hello, world’).
Why? I couldn’t figure out what I actually needed to learn or what I intended to do with it once I learned something useful.
Now, I’ve come full circle and I’m back to Python and learning some actual programming. Why? It seems like almost job title and position requires some kind of automation, programming, or scripting ability. I’m not looking for a new job, I’m just looking to stay ahead of becoming irrelevant. Programming books today are so much better than they were 20 years ago, or even 10, when I had to a basic computer class in college as a degree requirement.
Last fall, I bought a book that seemed to cover the basics, Python Crash Course, and started working through it. Guess what, it didn’t last long again. I got distracted because I had no plan, no real purpose, no anything beyond “learn to program in Python.”
There were some ephemeral goals like, “learn to automate this task” or “create an interface for that project.” But what I quickly learned is even though Python seems like it is every where and everyone tells you it is the best thing since sliced bread, can cure cancer, solve the climate crisis, and end world hunger… it can’t. Not in my environment. Not today.
I work with Cisco UC servers. Everything in Python that exists today is for networking or Linux servers. What I unfortunately learned when I started back up is even though Cisco servers are technically RedHat Linux, with the interface Cisco created, things are about 20x more difficult.
I had hoped to create a program that would just take my pieces of input and generate a script, login to the servers, execute the script and leave me the rest of the work day to go mess around outside.
I don’t know why I thought I could accomplish this on my own. Cisco hasn’t even really been able to do it with all of their Prime Collaboration and Infrastructure and geniuses they have. Seriously, I think we’ve tried it several times in my organization and the only thing it is good for, upgrading servers.
Anyway, I’ve gotten a little less ambitious the past few weeks. Checked out some books from the library on Python and worked on learning what is actually possible with Python. Breaking down my big ambitious goal of making a program do my work for me to the individual pieces that I find unreliable, tedious, or otherwise wasting time, has been a start.
I’m looking for the low hanging fruits and building those pieces. Some of it has been reinventing the wheel as far things we “automate” today with Excel, but it has been a great way to learn programming skills and things that I find actually useful:
- Collect some data
- Manipulate that data to make it useful
- Take the new useful data and generate a variety of files and folders
- Format the files in a way that is visually meaningful
Our current excel documents have too much logic built into them everywhere, references to multiple other workbooks, sheets, files in other locations, when in the end our Excel documents really need to be static. I get tired of breaking the links to other documents, copying sheets to new workbooks so I can send only the needed information to the people that need it. Too much chance of human error in the process of producing and managing the end results. I also don’t like having to copy a zipfile of documents, praying it’s the latest version and has all the things I need and that everything is correct.
I’m slowly getting there and this weekend I made huge personal breakthroughs on understanding and learning some of the things I need.