Menu

Serving Uploaded Media in Production: How a Small PR Became a Hardened Fix in BrightBean Studio
📰

Serving Uploaded Media in Production: How a Small PR Became a Hardened Fix in BrightBean Studio

DEV Community: django·Robert Markovski·about 5 hours ago
#yCFc8xN0
#devtodjango#devto#dev#maintainer#commit
Reading 0:00
15s threshold

A candid look at a fix where the maintainer did most of the work after the first commit.

Short answer

In production, BrightBean Studio wrote uploaded files to disk but answered every request for them with a 404, which also broke publishing. The pull request replaced a DEBUG -only media route with a setting-controlled one. A maintainer then fixed a syntax error in the original commit and pushed three more commits that scoped and hardened the route. The result was merged as PR #156 and closed issue #130 .

The problem

BrightBean Studio is a Django app for managing and publishing social media content. Issue #130 reported a self-hosted Docker deployment using local file storage. The file existed on disk:

-rw-r--r-- 1 root root 10285 Jul 23 17:03 Leads.png

Enter fullscreen mode

Exit fullscreen mode

but the request returned Not Found: /media/media_library/2026/07/Leads.png . The reporter traced it.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.