-
Notifications
You must be signed in to change notification settings - Fork 847
Open
0 / 40 of 4 issues completedLabels
DEV: backendPython, databases, networking, filesystem...Python, databases, networking, filesystem...
Description
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Overview
Currently, the modality value is stored in the ContentNode options JSONField, which makes filtering operations very inefficient. This tracking issue covers the work to add a dedicated modality field for efficient querying and to resolve related filtering issues.
Implementation approach
Add a modality CharField to the ContentNode model (in models.py as a locally-calculated cached field) with a database index. This field will be populated during content import by extracting the value from options['modality'].
Technical details
- Field type:
CharField(max_length=50, blank=True, null=True, db_index=True, choices=modalities.choices) - Location:
kolibri/core/content/models.py(local field, not exported by Studio) - Annotation: Extract from
options['modality']during channel import (similar to bitmask fields) - Upgrade task: Backfill existing channels
- Expected values: QUIZ, SURVEY, CUSTOM_NAVIGATION, and future additions (5-15 total values anticipated)
🤖 This issue was written by Claude Code, under supervision, review and final edits by @rtibbles 🤖
Sub-issues
Metadata
Metadata
Assignees
Labels
DEV: backendPython, databases, networking, filesystem...Python, databases, networking, filesystem...
