🏗️ Building the Backbone: From Python Classes to Persistent Data "The best way to learn is to build, break, and fix. 🛠️ Over the last few days, I’ve been architecting the backend for my FastAPI TodoApp. It’s been a journey of connecting the dots: Defining the Schema: Using SQLAlchemy to turn Python classes into database tables. Establishing the Link: Setting up the engine and SessionLocal to bridge the gap between my app and SQLite. Overcoming Hurdles: Navigating Windows environment variables and mastering the SQLite3 CLI to verify data integrity. The foundation is now officially set. By calling models.Base.metadata.create_all(engine), my app now automatically generates its own database environment on startup. Next stop: Developing the CRUD API endpoints to bring this data to life! 🚀" #Python #FastAPI #SQLAlchemy #BackendDevelopment #CleanCode #SoftwareEngineering
Building FastAPI Backend with SQLAlchemy
More Relevant Posts
-
Built a small Python utility to refresh core fundamentals and structure. Built a CLI-based Contact Management system with: • Full CRUD operations • JSON-based persistent storage • Modular function design The idea wasn’t complexity, but to reinforce clean logic, data handling, and building systems from scratch without relying on frameworks. Planning to extend this further towards API-based and AI-driven workflows. GitHub: https://lnkd.in/gW8BXbKP #Python #SoftwareDevelopment #Backend #ContinuousLearning
To view or add a comment, sign in
-
Been spending my weekends on a Python side project and finally have something worth sharing. Built CareTrack API from scratch, a REST API for managing patient and provider records. It uses FastAPI, PostgreSQL, and JWT authentication, with a full CI/CD pipeline on GitHub Actions and a live deployment on Render. Tech stack: Python · FastAPI · PostgreSQL · SQLAlchemy · Alembic · JWT · GitHub Actions Live API docs: https://lnkd.in/e9beFYgM GitHub: https://lnkd.in/e53nQi9S Feedback always welcome. #Python #SideProject #BackendDevelopment #API
To view or add a comment, sign in
-
-
🚀 Day 11 of #111DaysOfLearningForChange – Code for Change Built a GitHub Trending CLI Tool to discover popular repositories 🌐💻 📌 What I learned today: • Advanced API usage with query parameters • Building flexible CLI tools using argparse • Filtering data based on time (day, week, month, year) • Handling API responses and errors effectively 🛠️ What I built: A CLI tool that: • Fetches trending GitHub repositories 📈 • Filters results by duration (day/week/month/year) • Displays repo details (name, stars, language, link) ✨ Example usage: python trending.py --duration week --limit 5 ✨ Key takeaway: Combining APIs with CLI tools can create powerful and practical developer utilities ⚡ Challenge faced: Constructing correct API queries and handling different response cases #111DaysOfLearningForChange #CodeForChange #Python #CLI #API #GitHub #LearningInPublic https://lnkd.in/gNBy3eiN
To view or add a comment, sign in
-
-
Just deployed my first data app and honestly it felt like a whole journey 🚀 I built a Product Information Quality Dashboard using Python and Streamlit that analyzes how complete product data is and flags items that might confuse customers. Some of the skills I got to work with: 🐍 Python 🗄️ SQLAlchemy & SQLite for database management 📊 Pandas for data handling and exports ⚙️ Streamlit for building the interactive dashboard 🔧 Git & GitHub for version control ☁️ Deployed live on Streamlit Community Cloud Still learning and building every day — but seeing something you built actually live on the internet hits different 💪 Feedback always welcome! Check it out 👇 🔗 Live App: https://lnkd.in/gaiu6Src 💻 GitHub: https://lnkd.in/gm-TeghV #Python #DataScience #Streamlit #buildinpublic #DataAnalytics #LearningInPublic
To view or add a comment, sign in
-
-
💡 Imagine this... You send ₹1000 to your friend, money is deducted from your account… but your friend never receives it ❌ Scary right? This is where Django’s "transaction.atomic()" comes in 🔥 It ensures: ✅ Either all database operations succeed ❌ Or everything is rolled back When you wrap code inside transaction.atomic(): ✅ All database queries succeed → changes are saved ❌ Any error happens → everything is rolled back No partial updates. No broken data. That’s why I’m learning and using this in my Django projects 🚀 #django #python #backenddevelopment #webdevelopment #learning
To view or add a comment, sign in
-
-
One of the most common FastAPI mistakes is reusing SQLAlchemy models as Pydantic response schemas. This doesn't just couple your layers—it makes it easy to accidentally expose fields like hashed passwords. In my latest post, I share 8 Sections of battle-tested patterns for structuring your FastAPI applications: 1️⃣ Centralized Config: Using pydantic-settings instead of scattered os.environ calls. 2️⃣ Dependency Injection: Leveraging Depends() for cleaner auth and DB sessions. 3️⃣ Business Logic: Moving core logic into pure Python service functions for easier unit testing. 4️⃣ Error Handling: Using app-level exception handlers to remove "try/except" noise from routes. Swipe through the PDF for the code examples and folder structures! ➡️ #FastAPI #Python #BackendDevelopment #WebDevelopment #CleanCode
To view or add a comment, sign in
-
Day 30 of #100DaysOfPython 𝐔𝐩𝐠𝐫𝐚𝐝𝐞𝐝 𝐭𝐡𝐞 𝐏𝐚𝐬𝐬𝐰𝐨𝐫𝐝 𝐌𝐚𝐧𝐚𝐠𝐞𝐫 𝐀𝐩𝐩 𝐭𝐨𝐝𝐚𝐲. I moved from saving data in a text file to using JSON, which makes the data more structured and easier to manage. I also added a search feature to retrieve saved credentials. 𝐖𝐡𝐚𝐭 𝐈 𝐢𝐦𝐩𝐫𝐨𝐯𝐞𝐝: 𝑺𝒘𝒊𝒕𝒄𝒉𝒆𝒅 𝒕𝒐 𝑱𝑺𝑶𝑵 𝒇𝒐𝒓 𝒔𝒕𝒓𝒖𝒄𝒕𝒖𝒓𝒆𝒅 𝒅𝒂𝒕𝒂 𝒔𝒕𝒐𝒓𝒂𝒈𝒆 𝑰𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕𝒆𝒅 𝒔𝒆𝒂𝒓𝒄𝒉 𝒇𝒖𝒏𝒄𝒕𝒊𝒐𝒏𝒂𝒍𝒊𝒕𝒚 𝒇𝒐𝒓 𝒔𝒂𝒗𝒆𝒅 𝒑𝒂𝒔𝒔𝒘𝒐𝒓𝒅𝒔 𝑯𝒂𝒏𝒅𝒍𝒆𝒅 𝒆𝒓𝒓𝒐𝒓𝒔 𝒖𝒔𝒊𝒏𝒈 𝒕𝒓𝒚/𝒆𝒙𝒄𝒆𝒑𝒕 (𝒎𝒊𝒔𝒔𝒊𝒏𝒈 𝒇𝒊𝒍𝒆, 𝒎𝒊𝒔𝒔𝒊𝒏𝒈 𝒅𝒂𝒕𝒂, 𝒆𝒎𝒑𝒕𝒚 𝑱𝑺𝑶𝑵) 𝑰𝒎𝒑𝒓𝒐𝒗𝒆𝒅 𝒐𝒗𝒆𝒓𝒂𝒍𝒍 𝒖𝒔𝒆𝒓 𝒆𝒙𝒑𝒆𝒓𝒊𝒆𝒏𝒄𝒆 𝒊𝒏 𝒕𝒉𝒆 𝑮𝑼𝑰 This version feels much closer to a real application. Managing data properly and handling edge cases made a big difference. Also a good reminder that writing code is one thing, but making it robust and user-friendly is another level. #100DaysOfCode #100DaysOfPython #Python #Tkinter #PasswordManager #JSON #ErrorHandling #PythonProjects #LearningToCode #CodingJourney #BuildInPublic
To view or add a comment, sign in
-
From "It Works on My Machine" to Shipping Code That Works Everywhere! Most data projects don't fail because of bad code. They fail because of broken environments. Library version mismatches. Pipelines that break overnight. Onboarding that takes days instead of minutes. Docker solves all of that by packaging your code, Python version, and dependencies into a single container that runs identically anywhere. I wrote a full breakdown of the business and technical impact, and what it looks like in a real data project: 👉 https://lnkd.in/gh8-r3Bj #Docker #BusinessIntelligence #BI #DataScience #Python
To view or add a comment, sign in
-
I’m pleased to share my recent project: a Distributed Caching System in Python, designed to improve application performance by reducing database dependency and network latency. The system leverages core data structures (LRU using HashMap and Doubly Linked List) along with object-oriented design principles to deliver efficient in-memory data retrieval. It also includes multi-node distribution, TTL-based expiration, REST API endpoints, and a Python SDK for seamless integration. Additional features such as rate limiting, logging, and a SQL-backed demo were implemented to simulate real-world backend scenarios. Through benchmarking, the system demonstrates a clear improvement in response time, with repeated requests being served from cache instead of querying the database. https://lnkd.in/d2-EGs7v This project was a valuable exercise in backend system design, performance optimization, and building production-oriented solutions. #Python #BackendEngineering #SystemDesign #Caching #APIs #SoftwareDevelopment #DistributedSystems
To view or add a comment, sign in
-
🎯 Tech Learning Journey - Day 03: Web APIs & Requests - Talk to the Internet! Web APIs are how your Python code talks to websites and online services. You send a request, just like asking for information, and the API sends back data that you can use in your application. import requests # Get data from a public API response = requests.get\('https://lnkd.in/gUpgfHqa) data = response.json\(\) print\(f"User: \{data\['login'\]\}"\) print\(f"Repos: \{data\['public\_repos'\]\}"\) Where I use this: Fetching weather updates, getting user data from databases, and integrating third-party services into my apps. #Python #Coding #Programming #WebAPI
To view or add a comment, sign in
-
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development