progress
This commit is contained in:
parent
bb69b75f61
commit
b0cfdf5271
3 changed files with 20 additions and 21 deletions
|
|
@ -676,10 +676,9 @@ class WatchlistScanner:
|
|||
import random
|
||||
|
||||
# Check if we should run (prevents over-polling Spotify)
|
||||
# TEMPORARILY DISABLED FOR TESTING
|
||||
# if not self.database.should_populate_discovery_pool(hours_threshold=24):
|
||||
# logger.info("Discovery pool was populated recently (< 24 hours ago). Skipping to avoid over-polling Spotify.")
|
||||
# return
|
||||
if not self.database.should_populate_discovery_pool(hours_threshold=24):
|
||||
logger.info("Discovery pool was populated recently (< 24 hours ago). Skipping to avoid over-polling Spotify.")
|
||||
return
|
||||
|
||||
logger.info("Populating discovery pool from similar artists...")
|
||||
|
||||
|
|
|
|||
|
|
@ -1665,19 +1665,19 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Release Radar Section -->
|
||||
<!-- Fresh Tape Section -->
|
||||
<div class="discover-section">
|
||||
<div class="discover-section-header">
|
||||
<div>
|
||||
<h2 class="discover-section-title">Release Radar</h2>
|
||||
<p class="discover-section-subtitle">Fresh tracks from new releases</p>
|
||||
<h2 class="discover-section-title">Fresh Tape</h2>
|
||||
<p class="discover-section-subtitle">New drops from recent releases</p>
|
||||
</div>
|
||||
<div class="discover-section-actions">
|
||||
<button class="action-button secondary" onclick="openDownloadModalForDiscoverPlaylist('release_radar', 'Release Radar')" title="Download missing tracks">
|
||||
<button class="action-button secondary" onclick="openDownloadModalForDiscoverPlaylist('release_radar', 'Fresh Tape')" title="Download missing tracks">
|
||||
<span class="button-icon">↓</span>
|
||||
<span class="button-text">Download</span>
|
||||
</button>
|
||||
<button class="action-button primary" id="release-radar-sync-btn" onclick="startDiscoverPlaylistSync('release_radar', 'Release Radar')" title="Sync to media server">
|
||||
<button class="action-button primary" id="release-radar-sync-btn" onclick="startDiscoverPlaylistSync('release_radar', 'Fresh Tape')" title="Sync to media server">
|
||||
<span class="button-icon">⟳</span>
|
||||
<span class="button-text">Sync</span>
|
||||
</button>
|
||||
|
|
@ -1704,24 +1704,24 @@
|
|||
<!-- Content will be populated dynamically -->
|
||||
<div class="discover-loading">
|
||||
<div class="loading-spinner"></div>
|
||||
<p>Loading release radar...</p>
|
||||
<p>Loading fresh tape...</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Discovery Weekly Section -->
|
||||
<!-- The Archives Section -->
|
||||
<div class="discover-section">
|
||||
<div class="discover-section-header">
|
||||
<div>
|
||||
<h2 class="discover-section-title">Discovery Weekly</h2>
|
||||
<p class="discover-section-subtitle">A personalized playlist just for you</p>
|
||||
<h2 class="discover-section-title">The Archives</h2>
|
||||
<p class="discover-section-subtitle">Curated from your collection</p>
|
||||
</div>
|
||||
<div class="discover-section-actions">
|
||||
<button class="action-button secondary" onclick="openDownloadModalForDiscoverPlaylist('discovery_weekly', 'Discovery Weekly')" title="Download missing tracks">
|
||||
<button class="action-button secondary" onclick="openDownloadModalForDiscoverPlaylist('discovery_weekly', 'The Archives')" title="Download missing tracks">
|
||||
<span class="button-icon">↓</span>
|
||||
<span class="button-text">Download</span>
|
||||
</button>
|
||||
<button class="action-button primary" id="discovery-weekly-sync-btn" onclick="startDiscoverPlaylistSync('discovery_weekly', 'Discovery Weekly')" title="Sync to media server">
|
||||
<button class="action-button primary" id="discovery-weekly-sync-btn" onclick="startDiscoverPlaylistSync('discovery_weekly', 'The Archives')" title="Sync to media server">
|
||||
<span class="button-icon">⟳</span>
|
||||
<span class="button-text">Sync</span>
|
||||
</button>
|
||||
|
|
@ -1748,7 +1748,7 @@
|
|||
<!-- Content will be populated dynamically -->
|
||||
<div class="discover-loading">
|
||||
<div class="loading-spinner"></div>
|
||||
<p>Curating your discovery playlist...</p>
|
||||
<p>Loading the archives...</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -24235,13 +24235,13 @@ async function loadDiscoverPage() {
|
|||
}
|
||||
|
||||
async function checkForActiveDiscoverSyncs() {
|
||||
// Check if Release Radar sync is active
|
||||
// Check if Fresh Tape sync is active
|
||||
try {
|
||||
const releaseRadarResponse = await fetch('/api/sync/status/discover_release_radar');
|
||||
if (releaseRadarResponse.ok) {
|
||||
const data = await releaseRadarResponse.json();
|
||||
if (data.status === 'syncing' || data.status === 'starting') {
|
||||
console.log('🔄 Resuming Release Radar sync polling after page refresh');
|
||||
console.log('🔄 Resuming Fresh Tape sync polling after page refresh');
|
||||
|
||||
// Show status display
|
||||
const statusDisplay = document.getElementById('release-radar-sync-status');
|
||||
|
|
@ -24265,13 +24265,13 @@ async function checkForActiveDiscoverSyncs() {
|
|||
// Sync not active, ignore
|
||||
}
|
||||
|
||||
// Check if Discovery Weekly sync is active
|
||||
// Check if The Archives sync is active
|
||||
try {
|
||||
const discoveryWeeklyResponse = await fetch('/api/sync/status/discover_discovery_weekly');
|
||||
if (discoveryWeeklyResponse.ok) {
|
||||
const data = await discoveryWeeklyResponse.json();
|
||||
if (data.status === 'syncing' || data.status === 'starting') {
|
||||
console.log('🔄 Resuming Discovery Weekly sync polling after page refresh');
|
||||
console.log('🔄 Resuming The Archives sync polling after page refresh');
|
||||
|
||||
// Show status display
|
||||
const statusDisplay = document.getElementById('discovery-weekly-sync-status');
|
||||
|
|
@ -24851,7 +24851,7 @@ function startDiscoverSyncPolling(playlistType, virtualPlaylistId) {
|
|||
}
|
||||
|
||||
// Show completion toast
|
||||
showToast(`${playlistType === 'release_radar' ? 'Release Radar' : 'Discovery Weekly'} sync complete!`, 'success');
|
||||
showToast(`${playlistType === 'release_radar' ? 'Fresh Tape' : 'The Archives'} sync complete!`, 'success');
|
||||
|
||||
// Hide status display after 3 seconds
|
||||
setTimeout(() => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue