DjangoCon Africa 2023, Almost a Year Later …

The Announcement I only saw Django Conferences happening in European and American countries. From the content and updates shared on X and by speakers/attendees, I realized that these events had serious content to share. I envied that. This right here, the X(tweet 😂) on May 10th. Hello World 👋🏼 We are more than excited to announce the first-ever DjangoCon event in Africa. It will take place this year in Zanzibar, Tanzania, from 6th - 11th November 2023! Please visit https://t.co/qC69TfKnPt to learn more! 1/3 🧵#djangoconAfrica #djcafrica #djangocon pic.twitter.com/gypAJD07hX ...

July 10, 2024 · 4 min · Chris Achinga

Seeding Data in Django Using Faker

Seeding data in a Django project can be essential for development and testing. Faker, a Python library, provides a convenient way to generate placeholder data realistically. This guide will explore how to seed data using Faker in Django. Here is an example model: First, let’s consider an example model consisting of Skill and Category. from django.db import models import uuid class Skill(models.Model): id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False, unique=True) title = models.CharField(max_length=200, unique=True) def __str__(self): return self.title class Category(models.Model): id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False, unique=True) title = models.CharField(max_length=200, unique=True) def __str__(self): return self.title Creating a Seeder Command To seed data easily, we’ll create a custom management command. ...

March 27, 2024 · 2 min · Chris Achinga