docs: v1.5.0 planning - ADR-062, release plan, and design docs
- ADR-062: Timestamp-based slug format (supersedes ADR-007) - Updated v1.5.0 RELEASE.md with 6-phase plan - Updated BACKLOG.md with deferred N+1 query locations - Developer questions and architect responses for Phase 1 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# StarPunk Backlog
|
||||
|
||||
**Last Updated**: 2025-12-16
|
||||
**Last Updated**: 2025-12-17
|
||||
|
||||
## Recently Completed
|
||||
|
||||
@@ -75,11 +75,24 @@
|
||||
- **Source**: Architect Review (Issue 1.2.3)
|
||||
- **Approach**: Sanitize filename before use: `safe_filename = "".join(c for c in filename if c.isalnum() or c in "._-")[:50]`
|
||||
|
||||
### N+1 Query Pattern in Feed Generation *(Scheduled: v1.5.0)*
|
||||
### N+1 Query Pattern in Feed Generation *(Scheduled: v1.5.0 - Partial)*
|
||||
- **Description**: In `_get_cached_notes()`, media and tags are loaded per-note in separate queries. For 50 notes, this is 100 additional database queries, degrading performance.
|
||||
- **Location**: `starpunk/routes/public.py` lines 68-74
|
||||
- **Source**: Architect Review (Issue 2.2.9)
|
||||
- **Approach**: Implement batch loading function `get_media_for_notes(note_ids: List[int])` using a single query with `WHERE note_id IN (...)`.
|
||||
- **v1.5.0 Scope**: Only `_get_cached_notes()` will be fixed in v1.5.0. Other N+1 patterns deferred (see Low Priority section).
|
||||
|
||||
### N+1 Query Patterns - Deferred Locations
|
||||
- **Description**: N+1 query patterns exist in multiple locations beyond `_get_cached_notes()`. These are lower priority due to lower traffic or single-note contexts.
|
||||
- **Deferred Locations**:
|
||||
1. **Admin Edit Page** (`starpunk/routes/admin.py` line 186): Single note context, low impact
|
||||
2. **Tag Archive Pages** (`starpunk/routes/public.py` lines 243-248, 332): Lower traffic than main feed
|
||||
3. **Individual Note View** (`starpunk/routes/public.py` lines 282-289): Single note, negligible
|
||||
4. **Note Model Property** (`starpunk/models.py` lines 380-381): On-demand loading, acceptable
|
||||
5. **Tag Module** (`starpunk/tags.py` line 197): Internal helper, low volume
|
||||
- **Source**: Architect Review, v1.5.0 scoping decision
|
||||
- **Approach**: Future optimization if performance issues arise. Consider batch loading patterns established in v1.5.0.
|
||||
- **Priority**: Deferred to post-v1.5.0
|
||||
|
||||
### Transaction Not Atomic in Variant Generation *(Scheduled: v1.5.0)*
|
||||
- **Description**: Files are written to disk before database commit. If the database commit fails, orphaned files remain on disk.
|
||||
|
||||
Reference in New Issue
Block a user