27 lines
1.4 KiB
Markdown
27 lines
1.4 KiB
Markdown
This is a Django-based web application that has an API, but primarily functions
|
|
with traditional Django views with HTML templates to display data that mostly
|
|
constitutes "scrobbled" items. The app started as a way to track a user's
|
|
watched videos via a Jellyfin server, but has since grown to keep track of a
|
|
number of media types: music tracks, tasks, videos, web pages, food, life
|
|
events, sports events, podcasts, video games, board games, beers, brick (lego)
|
|
sets, puzzles, books and geolocations.
|
|
|
|
The project is written in Python and prefers to use "fat" models where logical
|
|
methods are contained in either instance methods on instatiated data models, or
|
|
classmethods on the Django model class itself. When logic grows too complex,
|
|
helper functions should be pulled out into utils.py files and the model instance
|
|
ro class method should call the utility function.
|
|
|
|
Be sure to check pyproject.toml for project defaults. Specifically for black and
|
|
isort expectations.
|
|
|
|
Imports in python files should always be top level if possible.
|
|
|
|
All tasks live in the PROJECT.org file and include an org ID that is a uuid to make them unique.
|
|
|
|
In local development, environment variables for various sensitive values live in a .envrc file
|
|
|
|
The .envrc file can be loaded into a shell environment to allow access to most third party services
|
|
|
|
Care should be taken when using .envrc that we do not spam services we use in production with requests
|