APScheduler Jobs How-To Guide: Mastering Model Edit, Delete, and Update Events python by komal swami - January 4, 2025January 4, 20250 As developers, we often encounter use cases where tasks need to run periodically—be it sending email notifications, cleaning up stale data, or monitoring devices. This is where a robust task scheduler like APScheduler shines. In this blog, we'll dive into integrating APScheduler with Django REST Framework (DRF), debugging common issues, and demonstrate how to create scheduled jobs to automate tasks in short APScheduler Jobs How-To Guide: Mastering Model Edit, Delete, and Update Events What is APScheduler? APScheduler (Advanced Python Scheduler) is a lightweight Python library for scheduling jobs. It supports multiple backends, such as in-memory, database, or external queues. Its flexible API makes it an excellent choice for Django-based projects. Why Use APScheduler in DRF? Automate repetitive tasks (e.g., device monitoring, report generation). Replace
Mastering APScheduler in Django: A Instant Maggi Guide to Background Task Scheduling python by komal swami - December 31, 2024December 31, 20240 In this post, I’ll walk you through an intricate debugging process I faced while integrating APScheduler into a Django REST Framework project and this post came to life "Mastering APScheduler in Django: A Quick Guide aka Instant Maggi Guide to Background Task Scheduling". It all started with the seemingly simple goal of running a background task scheduler, but the journey took several unexpected turns. If you’ve ever faced issues like "Apps aren’t loaded yet" or struggled with initializing schedulers in Django, this post might save you a few hours (or days) of effort. Problem Context We aimed to set up a background scheduler using APScheduler in a Django REST Framework application. The goal was to execute recurring tasks at regular intervals by
No Audio With Systemd Command Service on Raspberry Pi Raspberry by komal swami - September 26, 2024September 26, 20240 while working on integrating sound playback into a flask service on an RPI. I encountered this issue where No Audio With Systemd Command Service on Raspberry Pi. Th issue where sound would play when running the Python script manually but when running it as a systems systemd service. After troubleshooting, I managed to solve the issue by making adjustments to the system's service file and sound configuration. here's a step-by-step guide. The solution was into basics, as you know there is thin line between, process context switch, process state switch and process mode switch. Context switch occurs between two different process while process mode switch occurs between two modes of same process but in these two 'context' is saved. Process
Push Notification Delivery To Specific User in Flutter with OneSignal python Solved by komal swami - June 20, 2024June 20, 20240 Introduction In today’s mobile-first world, push notifications are essential for user engagement. However, managing push notifications across multiple devices and sessions can be challenging. In this blog post, we'll explore a common issue where users do not receive notifications after logging out and logging back in, especially on different devices or accounts. To ensure seamless notification delivery, we'll share a comprehensive solution using OneSignal, Flutter, and Django REST API. The Problem We encountered a significant issue where users were not receiving notifications consistently. Specifically, the problem arose when users logged out and logged in again on different devices or with other accounts. This inconsistency led to a poor user experience and reduced engagement. Root Cause AnalysisThe primary issue was the improper handling of OneSignal’s
Disallowed Host Error On Django AWS EC2 python by komal swami - November 7, 2023November 7, 20230 Django (Name of Guitarist) is one of the famous web framework follows MVT(Model View Template) architecture. Means you get most of the things required to develop client server application. In this article we have explained in short how to solve disallowed Host Error On Django AWS EC2. Lets see, How to fix disallowed host Django. We have developed application on local system and we need to test and deploy a Django application on AWS EC2 instance. For this we have created virtual environment on AWS, installed python. With this we get pip(python package installer like npm - node package manager in java). pip is used to get packages in this virtual environment. $pip install django create new Django project