I recently reflected on the popularity of Python and how it increasingly crops up in my day job.
Over the last few years, I’ve started writing more Python scripts for infrastructure automation and several personal projects. I’ve also worked with developer teams and AI engineers, for which Python was their primary language.
Is this just my perception, or is Python becoming more prevalent?
The latest TIOBE index appears to support this theory. Python’s usage has been steadily increasing since 2018, with a significant spike in 2024 -
Significantly, this year, Python has now overtaken Java as the most used language on GitHub -
Microsoft even presented at PyCon US 24 this year.
One of the main reasons for Python’s popularity is its versatility. It’s used across a wide number of industries and use cases, e.g. -
AI / Machine Learning
Data analytics and processing
General software development, e.g. API and backend services, frontend web services (Django, Flask)
Automation and scripting
Embedded Systems and IoT
DevOps and automation
Microsoft Azure is where I spend most of my time, so as a fun exercise, I thought I’d investigate just how well-supported Python is across Azure’s multitude of services.
I’ve allocated each service to a particular job role. This isn’t a strict segregation; in reality, engineers and developers will often use various services to achieve a specific outcome.
Hopefully, this serves as a useful indication of the variety of services available.
Python Software Developers
Azure App Service
Azure Functions
Serverless Functions: Write Python code to run as event-driven serverless functions.
Containers
Azure Kubernetes Service (AKS) - Containerize Python applications using Docker images and deploy them on Azure Kubernetes Service
Container Apps - same as AKS
Azure Container Instances - same as AKS
Azure Virtual Machines (VMs)
Python scripts and applications can be run within Azure VM’s
Many Azure Marketplace VM images already come with Python preinstalled
Data and AI Engineers
Given Python’s historically high usage within the data and machine learning communities, it’s no surprise that these job roles are well supported.
Okay, deep breath, here are the Data and AI-related Azure services that support Python -
Azure Batch
Run large-scale parallel and high-performance computing (HPC) applications efficiently in Python. Useful for batch processing jobs.
Azure Data Science Virtual Machines
Azure Machine Learning
Develop and train machine learning models using Python. Supports Jupyter notebooks for interactive development and experimentation.
Azure Synapse Analytics
Azure Databricks
Azure IoT Edge
Azure Data Studio
Azure AI Search
Platform Engineer and DevOps
Azure Cloud Shell
Upload your Python scripts and run python from the command prompt
Azure CLI
Fun fact! - the Azure CLI is written in Python
“Built using Python, the Azure Command-Line Interface (CLI) allows you to manage Azure resources and services using command-line commands”
Azure SDK for Python
This can be an alternative to using Bicep / Terraform, especially if you prefer a programming approach over a declarative one. Whilst useful for some scenarios, you’d have to be committed to using this as your default option for deploying resources!
Azure Automation Runbooks
Integration with DevOps Pipelines
Python scripts can be part of CI/CD pipelines that deploy Azure resources using Bicep / Terraform. For instance, you can use Python to handle pre-deployment checks, validation, and coordination of the deployment process.
Summary
I hope you found this post interesting. Please let me know your comments below. Have you seen any other interesting use cases for running Python within Azure?
It's worth pointing out that from a developer's perspective, other popular languages, such as .NET, Java, etc., are also well supported within Azure. However, Python is certainly more prevalent, including data engineering, AI, and automation.
If you'd like to get started with Python on Azure, check out Microsoft's landing page for Python developers.
Also worth checking out is Microsoft's Python Pulse series of webcasts on YouTube.
Python is also cropping up in other areas of the Microsoft ecosystem. This neat video shows Python code running in Excel along with Microsoft 365 Copilot!
Comments