Complete v0.6.0 documentation update and review

📚 Documentation Updates:
• Updated CHANGELOG.md with comprehensive v0.6.0 feature list
• Enhanced README.md with new TV processing endpoints and examples
• Updated SETUP.md with required Sonarr API key configuration
• Enhanced TESTING.md with v0.6.0 TV testing procedures
• Updated .env templates with proper Sonarr requirements

🔧 Configuration Updates:
• Mark SONARR_API_KEY as REQUIRED for v0.6.0+ Enhanced TV NFOs
• Updated version examples from 0.5.1 to 0.6.0
• Added JSON response examples for new TV endpoints
• Clarified URL-safe vs URL-encoded endpoint options

📋 Complete File Review:
• Verified all Python imports are consistent across modules
• Confirmed all typing imports (Dict, Any, List, Optional) are present
• Validated configuration templates match actual requirements
• Added comprehensive testing procedures for TV enhancements

 Ready for Production:
• All endpoints documented with examples
• Configuration requirements clearly specified
• Testing procedures comprehensive for troubleshooting
• Backward compatibility maintained throughout
This commit is contained in:
2025-09-11 10:10:05 -04:00
parent 52fa0b6060
commit 01cd31505a
6 changed files with 72 additions and 6 deletions
+1 -1
View File
@@ -21,7 +21,7 @@ OMDB_API_KEY=your_omdb_api_key
# Radarr API key (optional - for fallback only) # Radarr API key (optional - for fallback only)
RADARR_API_KEY=your_radarr_api_key RADARR_API_KEY=your_radarr_api_key
# Sonarr API key (optional - for TV processing) # Sonarr API key (REQUIRED for v0.6.0+ Enhanced TV NFO Generation)
SONARR_API_KEY=your_sonarr_api_key SONARR_API_KEY=your_sonarr_api_key
# Jellyseerr API key (optional) # Jellyseerr API key (optional)
+2 -2
View File
@@ -33,9 +33,9 @@ RADARR_DB_USER=radarr
RADARR_URL=http://radarr:7878 RADARR_URL=http://radarr:7878
# =========================================== # ===========================================
# SONARR API (OPTIONAL) # SONARR API (REQUIRED for Enhanced TV NFOs - v0.6.0+)
# =========================================== # ===========================================
# Only needed for TV processing # Required for TV processing and enhanced NFO generation with metadata
# NOTE: API key should be set in .env.secrets file # NOTE: API key should be set in .env.secrets file
SONARR_URL=http://sonarr:8989 SONARR_URL=http://sonarr:8989
+21 -1
View File
@@ -2,9 +2,29 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## [Unreleased] - v0.6.0 ## [Released] - v0.6.0 - 2025-09-11
### Added ### Added
- **📺 Enhanced TV Show Processing**: Comprehensive single season/episode capabilities
- **Single Season Processing**: `/tv/scan-season` endpoint for targeted season updates
- **Single Episode Processing**: `/tv/scan-episode` endpoint for individual episode handling
- **URL-Safe Endpoints**: JSON-based API calls avoid URL encoding issues with spaces/special characters
- **Enhanced Path Detection**: Automatically detects season directories and episode files
- **Database Integration**: Full episode date tracking and retrieval with `get_episode_date()`
- **🎬 Rich NFO Generation**: Full metadata integration from Sonarr API
- **Episode Titles**: Real episode names from Sonarr instead of generic S01E01 format
- **Plot Summaries**: Episode descriptions for better library browsing experience
- **Runtime Data**: Episode duration information for media players
- **Rating Integration**: IMDb ratings and vote counts for episodes
- **Backwards Compatible**: Existing basic NFOs still work, enhanced when Sonarr API available
- **⏰ NFOGuard Timestamps**: All NFO files now include processing timestamps
- **Creation Tracking**: Shows when NFOGuard created/updated each NFO file
- **Format**: `<!-- managed by NFOGuard at 2025-09-11T13:45:22+00:00 -->`
- **Audit Trail**: Helps track metadata management history
- **🔧 Enhanced TV Manual Scan**: Smart path detection for seasons and episodes
- **Season Detection**: `curl -X POST "manual/scan?path=/media/TV/Series/Season 13"`
- **Episode Detection**: `curl -X POST "manual/scan?path=/media/TV/Series/Season 13/episode.mkv"`
- **Automatic Processing**: Detects context and processes accordingly
- **🔐 Secure Configuration System**: Two-file configuration with automatic API key masking - **🔐 Secure Configuration System**: Two-file configuration with automatic API key masking
- **Main `.env`**: Paths and preferences (safe to share for debugging) - **Main `.env`**: Paths and preferences (safe to share for debugging)
- **Separate `.env.secrets`**: API keys and passwords (never committed to git) - **Separate `.env.secrets`**: API keys and passwords (never committed to git)
+17 -1
View File
@@ -232,7 +232,7 @@ curl "http://localhost:8080/debug/tmdb/tt1674782"
```json ```json
{ {
"status": "healthy", "status": "healthy",
"version": "0.5.1", "version": "0.6.0",
"database_status": "healthy", "database_status": "healthy",
"radarr_database": {"status": "healthy", "movies": 1500} "radarr_database": {"status": "healthy", "movies": 1500}
} }
@@ -264,6 +264,22 @@ curl "http://localhost:8080/debug/tmdb/tt1674782"
} }
``` ```
**TV Season Processing**:
```json
{
"status": "started",
"message": "Season scan started for Season 13"
}
```
**TV Episode Processing**:
```json
{
"status": "started",
"message": "Episode scan started for Chicago Fire (2012)-S13E21-The Bad Guy[WEBDL-1080p][AAC2.0][h264].mkv"
}
```
## 🎯 Date Selection Priority System ## 🎯 Date Selection Priority System
NFOGuard uses a **comprehensive fallback hierarchy** to find the best possible date for each movie: NFOGuard uses a **comprehensive fallback hierarchy** to find the best possible date for each movie:
+3 -1
View File
@@ -49,9 +49,11 @@ RADARR_DB_PASSWORD=your_actual_radarr_password
# TMDB API key (required for release date detection) # TMDB API key (required for release date detection)
TMDB_API_KEY=your_actual_tmdb_api_key TMDB_API_KEY=your_actual_tmdb_api_key
# Sonarr API key (REQUIRED for v0.6.0+ Enhanced TV NFO Generation)
SONARR_API_KEY=your_actual_sonarr_api_key
# Optional API keys # Optional API keys
RADARR_API_KEY=your_radarr_api_key RADARR_API_KEY=your_radarr_api_key
SONARR_API_KEY=your_sonarr_api_key
OMDB_API_KEY=your_omdb_api_key OMDB_API_KEY=your_omdb_api_key
``` ```
+28
View File
@@ -114,6 +114,34 @@ curl -X POST "http://localhost:8080/manual/scan?scan_type=movies"
curl -X POST "http://localhost:8080/bulk/update" curl -X POST "http://localhost:8080/bulk/update"
``` ```
### Step 6: Test Enhanced TV Processing (v0.6.0+)
```bash
# Test Sonarr API integration
curl "http://localhost:8080/health"
# Check that Sonarr connection shows up
# Test single season processing (URL-safe)
curl -X POST "http://localhost:8080/tv/scan-season" \
-H "Content-Type: application/json" \
-d '{
"series_path": "/media/TV/tv/Your Show [imdb-tt1234567]",
"season_name": "Season 01"
}'
# Test single episode processing (URL-safe)
curl -X POST "http://localhost:8080/tv/scan-episode" \
-H "Content-Type: application/json" \
-d '{
"series_path": "/media/TV/tv/Your Show [imdb-tt1234567]",
"season_name": "Season 01",
"episode_name": "S01E01.mkv"
}'
# Verify enhanced NFO was created with metadata
find /media/TV/tv -name "S01E*.nfo" | head -1 | xargs cat
# Should show: <title>, <plot>, <rating>, <runtime>, timestamps
```
## 🛠 Why These Tests Are Needed ## 🛠 Why These Tests Are Needed
1. **Docker Environment Isolation**: Tests run in the same environment as the production app 1. **Docker Environment Isolation**: Tests run in the same environment as the production app