Junior Python Developer

Introduction As a Junior Python Developer at InterIntel Technologies Limited, I gained hands-on experience in data modeling and software development, focusing on building robust and scalable data pipelines for analytics. I leveraged open-source technologies to optimize data processing workflows, contributing to efficient, data-driven solutions that supported the company’s analytical capabilities. Below is a summary of some of the projects i worked on. ETL Pipeline Development and Data Integration Designed and developed efficient ETL functions, packages, and pipelines to extract, transform, and load data from multiple sources, enabling seamless data integration, and high-quality data transformations....

A Docker Compose Example (FlaskAPP + PostgreSQL + Traefik)

Introduction Docker Compose is a tool used for defining and running multi-container Docker applications. It allows developers to describe all the services that make up an application in a single YAML file, defining the relationships and configurations between them. Docker Compose then uses this YAML configuration to deploy and manage the application’s containers as a single unit. Docker Compose is particularly useful for development environments, testing, and deploying multi-container applications in a consistent and reproducible manner....

February 9, 2024 · 3 min

Crafting a Docker Image for Your Flask Web App

Introduction🐋 Docker is a revolutionary containerization platform that streamlines software development and deployment. It encapsulates applications and their dependencies, ensuring consistency across different environments. Docker eliminates the “it works on my machine” problem, promoting collaboration and scalability. Its efficient resource utilization and isolation capabilities make it a vital tool for modern software development. Prerequisites 📋 Flask Application. Docker Follow these steps to install docker to your computer. Docker Hub Account create a free account....

January 13, 2024 · 5 min

Python One Liners

Multiple variable assignments name, age, occupation = "fatma", 30, "cook" print(name, age, occupation) # fatma 30 cook HTTP server python -m http.server Swap variables a = "a" b = "b" a, b = b, a print(a, b) # b a Ternary operator yob = 1997 print("hey kid(gen alpha)" if yob >= 2013 else "wassup gen z" if yob >= 1995 else"hello future grandma(millennials)" if yob >= 1980 else "hey grandma(gen x)" if yob >= 1965 else "hello ancestor (baby boomer)") # wassup gen z Variable unpacking users = ['kalama', 'kairetu','munga','mwanaisha'] print(*users) #kalama kairetu munga mwanaisha user1, user2 , *other_users= users print(other_users) #['munga', 'mwanaisha'] Reverse a list z = [10,20,30,40] print(z[::-1]) #[40, 30, 20, 10] Sort a list numbers = [1000000, -500000, 999999999, -1000000000, 123456789] print(sorted(numbers)) # [-1000000000, -500000, 1000000, 123456789, 999999999] Sort a list - reversed numbers = [1000000, -500000, 999999999, -1000000000, 123456789] print(sorted(numbers, reverse=True)) #[999999999, 123456789, 1000000, -500000, -1000000000] Filter from a list numbers = [1,2,3,4,5,6,7,8,9,10] odd = list(filter(lambda x: x%2!...

November 23, 2023 · 2 min

Web Scraping Using Selenium

Introduction Selenium is a framework that many developers use to automate web browsers. It’s an open source tool that offers compatibility, with web browsers and supports programming languages. While its commonly used for testing web applications it’s also handy for tasks like web scraping and automating browser actions. WebDriver, which is a part of Selenium allows developers to control web browsers programmatically. Using Selenium to scrape data Task: Scraping the latest news posts from a popular blog post Please note that to follow along you must have an understanding of basic HTML elements and CSS classes and id selectors as well as python...

October 9, 2023 · 4 min

List & Dictionary Comprehension in Python

List Comprehension Python lists are a fundamental data structure for storing and managing data collections. Lists are adaptable, flexible, and may store a variety of data kinds, including integers, strings, and even other lists. List comprehension lets you make a new list by applying an expression to each item in an existing iterable (such as a list, tuple, or range) and optionally filtering the items depending on a condition. List comprehensions are a more compact and readable means of creating lists than typical for loops....

September 8, 2023 · 2 min

Python Script Automation in Windows

Introduction Sometimes, we need to run Python scripts at regular intervals to complete specific tasks. However, as humans, we often forget or remember too late. Operating systems offer built-in capabilities to schedule the execution of commands or programs when needed. While Linux simplifies task automation through the ‘crontab’ utility, Windows also offers similar functionality. With the right know-how, you can effectively automate tasks in Windows, Windows Task Scheduler Task Scheduler is a built-in utility in Microsoft Windows operating systems that allows users to automate various tasks and processes on their computer....

September 29, 2023 · 3 min

Combine Iterables Together Using Zip Function

Introduction The zip() function in Python is a built-in function that allows you to combine two or more iterables (such as lists, tuples, or other sequences) element-wise. It creates an iterator that generates tuples, where each tuple contains one element from each of the input iterables. The resulting iterator stops when the shortest input iterable is exhausted. This is particularly useful when you want to work with multiple sequences simultaneously....

October 3, 2023 · 1 min