Release v1.3.0: Multi-source downloads, audio analyzer resilience, mobile improvements
Major Features: - Multi-source download system (Soulseek/Lidarr with fallback) - Configurable enrichment speed control (1-5x) - Mobile touch drag support for seek sliders - iOS PWA media controls (Control Center, Lock Screen) - Artist name alias resolution via Last.fm - Circuit breaker pattern for audio analysis Critical Fixes: - Audio analyzer stability (non-ASCII, BrokenProcessPool, OOM) - Discovery system race conditions and import failures - Radio decade categorization using originalYear - LastFM API response normalization - Mood bucket infinite loop prevention Security: - Bull Board admin authentication - Lidarr webhook signature verification - JWT token expiration and refresh - Encryption key validation on startup Closes #2, #6, #9, #13, #21, #26, #31, #34, #35, #37, #40, #43
This commit is contained in:
@@ -13,19 +13,34 @@ interface AIServicesSectionProps {
|
||||
}
|
||||
|
||||
export function AIServicesSection({ settings, onUpdate, onTest, isTesting }: AIServicesSectionProps) {
|
||||
const [testStatus, setTestStatus] = useState<StatusType>("idle");
|
||||
const [testMessage, setTestMessage] = useState("");
|
||||
const [fanartTestStatus, setFanartTestStatus] = useState<StatusType>("idle");
|
||||
const [fanartTestMessage, setFanartTestMessage] = useState("");
|
||||
const [lastfmTestStatus, setLastfmTestStatus] = useState<StatusType>("idle");
|
||||
const [lastfmTestMessage, setLastfmTestMessage] = useState("");
|
||||
|
||||
const handleTest = async () => {
|
||||
setTestStatus("loading");
|
||||
setTestMessage("Testing...");
|
||||
const handleFanartTest = async () => {
|
||||
setFanartTestStatus("loading");
|
||||
setFanartTestMessage("Testing...");
|
||||
const result = await onTest("fanart");
|
||||
if (result.success) {
|
||||
setTestStatus("success");
|
||||
setTestMessage("Connected");
|
||||
setFanartTestStatus("success");
|
||||
setFanartTestMessage("Connected");
|
||||
} else {
|
||||
setTestStatus("error");
|
||||
setTestMessage(result.error || "Failed");
|
||||
setFanartTestStatus("error");
|
||||
setFanartTestMessage(result.error || "Failed");
|
||||
}
|
||||
};
|
||||
|
||||
const handleLastfmTest = async () => {
|
||||
setLastfmTestStatus("loading");
|
||||
setLastfmTestMessage("Testing...");
|
||||
const result = await onTest("lastfm");
|
||||
if (result.success) {
|
||||
setLastfmTestStatus("success");
|
||||
setLastfmTestMessage("Connected");
|
||||
} else {
|
||||
setLastfmTestStatus("error");
|
||||
setLastfmTestMessage(result.error || "Failed");
|
||||
}
|
||||
};
|
||||
|
||||
@@ -63,22 +78,61 @@ export function AIServicesSection({ settings, onUpdate, onTest, isTesting }: AIS
|
||||
<div className="pt-2">
|
||||
<div className="inline-flex items-center gap-3">
|
||||
<button
|
||||
onClick={handleTest}
|
||||
onClick={handleFanartTest}
|
||||
disabled={isTesting || !settings.fanartApiKey}
|
||||
className="px-4 py-1.5 text-sm bg-[#333] text-white rounded-full
|
||||
hover:bg-[#404040] disabled:opacity-50 disabled:cursor-not-allowed transition-colors"
|
||||
>
|
||||
{testStatus === "loading" ? "Testing..." : "Test Connection"}
|
||||
{fanartTestStatus === "loading" ? "Testing..." : "Test Connection"}
|
||||
</button>
|
||||
<InlineStatus
|
||||
status={testStatus}
|
||||
message={testMessage}
|
||||
onClear={() => setTestStatus("idle")}
|
||||
<InlineStatus
|
||||
status={fanartTestStatus}
|
||||
message={fanartTestMessage}
|
||||
onClear={() => setFanartTestStatus("idle")}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
|
||||
{/* Last.fm */}
|
||||
<div className="mt-6 pt-6 border-t border-white/5">
|
||||
<div className="mb-4">
|
||||
<p className="text-sm text-white/60">
|
||||
Last.fm is pre-configured with a default key. Add your own for higher rate limits.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<SettingsRow label="Last.fm API Key (Optional)">
|
||||
<SettingsInput
|
||||
type="password"
|
||||
value={settings.lastfmApiKey || ""}
|
||||
onChange={(v) => onUpdate({ lastfmApiKey: v })}
|
||||
placeholder="Optional: Your Last.fm API key"
|
||||
className="w-64"
|
||||
/>
|
||||
</SettingsRow>
|
||||
|
||||
{settings.lastfmApiKey && (
|
||||
<div className="pt-2">
|
||||
<div className="inline-flex items-center gap-3">
|
||||
<button
|
||||
onClick={handleLastfmTest}
|
||||
disabled={isTesting}
|
||||
className="px-4 py-1.5 text-sm bg-[#333] text-white rounded-full
|
||||
hover:bg-[#404040] disabled:opacity-50 disabled:cursor-not-allowed transition-colors"
|
||||
>
|
||||
{lastfmTestStatus === "loading" ? "Testing..." : "Test Connection"}
|
||||
</button>
|
||||
<InlineStatus
|
||||
status={lastfmTestStatus}
|
||||
message={lastfmTestMessage}
|
||||
onClear={() => setLastfmTestStatus("idle")}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
</SettingsSection>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user