From 33fa672d3278548e4eb744a40f01c211cb6707ea Mon Sep 17 00:00:00 2001 From: Eric Coissac Date: Tue, 27 Jan 2026 13:52:15 +0100 Subject: [PATCH] Bump version to 0.3.19 and update API endpoint Update version from 0.3.18 to 0.3.19 in Cargo.toml, package-lock.json, and version.txt. Also update the API endpoint in pmoparadise/src/client.rs from `/get_block` to `/play` and remove the `peer` property from several dependencies in package-lock.json. Additionally, update the ARCHITECTURE.md documentation to reflect the change in API endpoint. --- Cargo.lock | 2 +- PMOMusic/Cargo.toml | 2 +- pmoapp/webapp/package-lock.json | 5 ----- pmoparadise/ARCHITECTURE.md | 1 + pmoparadise/src/client.rs | 7 +++---- version.txt | 2 +- 6 files changed, 7 insertions(+), 12 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 48838a9e..3506ff8b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4,7 +4,7 @@ version = 4 [[package]] name = "PMOMusic" -version = "0.3.18" +version = "0.3.19" dependencies = [ "axum 0.8.7", "console-subscriber", diff --git a/PMOMusic/Cargo.toml b/PMOMusic/Cargo.toml index ebc7ba86..e1e52e3f 100644 --- a/PMOMusic/Cargo.toml +++ b/PMOMusic/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "PMOMusic" -version = "0.3.18" +version = "0.3.19" edition = "2024" [dependencies] diff --git a/pmoapp/webapp/package-lock.json b/pmoapp/webapp/package-lock.json index 56cdbd80..617e7ac5 100644 --- a/pmoapp/webapp/package-lock.json +++ b/pmoapp/webapp/package-lock.json @@ -859,7 +859,6 @@ "integrity": "sha512-1N9SBnWYOJTrNZCdh/yJE+t910Y128BoyY+zBLWhL3r0TYzlTmFdXrPwHL9DyFZmlEXNQQolTZh3KHV31QDhyA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "undici-types": "~6.21.0" } @@ -1383,7 +1382,6 @@ "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=12" }, @@ -1550,7 +1548,6 @@ "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", "devOptional": true, "license": "Apache-2.0", - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -1572,7 +1569,6 @@ "integrity": "sha512-VbA8ScMvAISJNJVbRDTJdCwqQoAareR/wutevKanhR2/1EkoXVZVkkORaYm/tNVCjP/UDTKtcw3bAkwOUdedmA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "esbuild": "^0.25.0", "fdir": "^6.5.0", @@ -1654,7 +1650,6 @@ "resolved": "https://registry.npmjs.org/vue/-/vue-3.5.22.tgz", "integrity": "sha512-toaZjQ3a/G/mYaLSbV+QsQhIdMo9x5rrqIpYRObsJ6T/J+RyCSFwN2LHNVH9v8uIcljDNa3QzPVdv3Y6b9hAJQ==", "license": "MIT", - "peer": true, "dependencies": { "@vue/compiler-dom": "3.5.22", "@vue/compiler-sfc": "3.5.22", diff --git a/pmoparadise/ARCHITECTURE.md b/pmoparadise/ARCHITECTURE.md index 6f9b693e..40f52683 100644 --- a/pmoparadise/ARCHITECTURE.md +++ b/pmoparadise/ARCHITECTURE.md @@ -14,6 +14,7 @@ Cette crate fournit deux architectures pour accéder à Radio Paradise : Au lieu de télécharger un gros bloc FLAC contenant plusieurs chansons et de calculer manuellement les bornes de chaque chanson, cette architecture : 1. Récupère le bloc via l'API `get_block` + ==> semble avoir changé en faveur du point REST: `https://api.radioparadise.com/api/play?event=107461&elapsed=1&bitrate=4&action=play&player_id=rp3_c736b87f-3e77-3c4c-761c-ef3ed53af279&info=true&chan=1&episode_id=0&slice_num=6&audio_type=M&source=24` 2. Filtre les chansons : garde uniquement celles où `sched_time_millis + duration >= now()` 3. Télécharge chaque chanson individuellement via son `gapless_url` 4. Stocke les métadonnées (titre, artiste, album, cover) dans le cache audio diff --git a/pmoparadise/src/client.rs b/pmoparadise/src/client.rs index a2aef0a2..601b5a18 100644 --- a/pmoparadise/src/client.rs +++ b/pmoparadise/src/client.rs @@ -4,6 +4,7 @@ use crate::error::{Error, Result}; use crate::models::{Block, EventId, NowPlaying}; use reqwest::Client; use std::time::Duration; +use tracing::debug; use url::Url; /// Default Radio Paradise API base URL @@ -135,7 +136,7 @@ impl RadioParadiseClient { /// # } /// ``` pub async fn get_block(&self, event: Option) -> Result { - let mut url = Url::parse(&format!("{}/get_block", self.api_base))?; + let mut url = Url::parse(&format!("{}/play", self.api_base))?; url.query_pairs_mut() .append_pair("bitrate", "4") // FLAC lossless @@ -148,8 +149,7 @@ impl RadioParadiseClient { .append_pair("event", &event_id.to_string()); } - #[cfg(feature = "logging")] - tracing::debug!("Fetching block: {}", url); + debug!("Fetching block: {}", url); let response = self .client @@ -177,7 +177,6 @@ impl RadioParadiseClient { block.image_base = Some(DEFAULT_IMAGE_BASE.to_string()); } - #[cfg(feature = "logging")] tracing::debug!( "Received block: event={}, songs={}", block.event, diff --git a/version.txt b/version.txt index 8355eafc..9ec8136c 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -0.3.18 +0.3.19