[PR #30] [MERGED] Refactor IPC codes #1522

Closed
opened 2026-03-14 15:18:40 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/aome510/spotify-player/pull/30
Author: @aome510
Created: 2/12/2022
Status: Merged
Merged: 2/16/2022
Merged by: @aome510

Base: masterHead: refactor-ipc-codes


📝 Commits (10+)

  • 3aaa960 refactor client::spotify structures
  • 0cf4e36 rename the connect module to spirc
  • 243e87b implement handling logics for spirc reconnect request
  • 16c9f79 mark feature="streaming" for spirc-related codes
  • f747cbd use tokio::sync::mpsc in main.rs and client module
  • f1e0c85 replace std:🧵:spawn with tokio::task::spawn
  • fe124e3 use tokio::sync::mpsc in ui codes
  • c091ff6 use tokio::sync::mpsc in event/mod.rs
  • 15a6fb3 use tokio::sync::mpsc in event::popup.rs
  • e796ede use tokio::sync::mpsc in event::window.rs

📊 Changes

12 files changed (+322 additions, -258 deletions)

View changed files

📝 README.md (+38 -37)
📝 spotify_player/src/client/handlers.rs (+35 -23)
📝 spotify_player/src/client/mod.rs (+35 -8)
📝 spotify_player/src/client/spotify.rs (+28 -44)
📝 spotify_player/src/command.rs (+3 -0)
📝 spotify_player/src/config/keymap.rs (+4 -0)
📝 spotify_player/src/event/mod.rs (+50 -46)
📝 spotify_player/src/event/popup.rs (+26 -21)
📝 spotify_player/src/event/window.rs (+23 -23)
📝 spotify_player/src/main.rs (+39 -33)
📝 spotify_player/src/spirc.rs (+22 -11)
📝 spotify_player/src/ui/mod.rs (+19 -12)

📄 Description

Brief description of changes

  • use tokio::sync::mpsc instead of std::sync::mpsc. Rename send, recv as channel variable to client_pub, client_sub
  • add ClientRequest::NewSpircConnection and Command::ReconnectIntegratedClient that restarts a spirc connection
  • cleanup the client::spotify code

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/aome510/spotify-player/pull/30 **Author:** [@aome510](https://github.com/aome510) **Created:** 2/12/2022 **Status:** ✅ Merged **Merged:** 2/16/2022 **Merged by:** [@aome510](https://github.com/aome510) **Base:** `master` ← **Head:** `refactor-ipc-codes` --- ### 📝 Commits (10+) - [`3aaa960`](https://github.com/aome510/spotify-player/commit/3aaa960cd8b1e102d5a6963e6d8e879b374113c6) refactor client::spotify structures - [`0cf4e36`](https://github.com/aome510/spotify-player/commit/0cf4e36a46d6a2a671010a5206861ac31732b1f9) rename the `connect` module to `spirc` - [`243e87b`](https://github.com/aome510/spotify-player/commit/243e87ba0db42f8e3696df058ff2e86243652413) implement handling logics for spirc reconnect request - [`16c9f79`](https://github.com/aome510/spotify-player/commit/16c9f792d2eaa4ec02a04e252784467f4e242d40) mark feature="streaming" for spirc-related codes - [`f747cbd`](https://github.com/aome510/spotify-player/commit/f747cbd8272f7aa1827c07fe681bc527cc226acc) use tokio::sync::mpsc in `main.rs` and `client` module - [`f1e0c85`](https://github.com/aome510/spotify-player/commit/f1e0c85880bf79b16a267de731978e349a1cac0b) replace std::thread::spawn with tokio::task::spawn - [`fe124e3`](https://github.com/aome510/spotify-player/commit/fe124e362852b76e2c64b36ee97efec7554b7b57) use `tokio::sync::mpsc` in `ui` codes - [`c091ff6`](https://github.com/aome510/spotify-player/commit/c091ff69b289a7f036ef48ce998930b7773a2b22) use `tokio::sync::mpsc` in `event/mod.rs` - [`15a6fb3`](https://github.com/aome510/spotify-player/commit/15a6fb33770d47c9e63c67b234426d66f458bca3) use `tokio::sync::mpsc` in `event::popup.rs` - [`e796ede`](https://github.com/aome510/spotify-player/commit/e796ede321737ca5dddd9faedc82d11bf9292e3a) use `tokio::sync::mpsc` in `event::window.rs` ### 📊 Changes **12 files changed** (+322 additions, -258 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+38 -37) 📝 `spotify_player/src/client/handlers.rs` (+35 -23) 📝 `spotify_player/src/client/mod.rs` (+35 -8) 📝 `spotify_player/src/client/spotify.rs` (+28 -44) 📝 `spotify_player/src/command.rs` (+3 -0) 📝 `spotify_player/src/config/keymap.rs` (+4 -0) 📝 `spotify_player/src/event/mod.rs` (+50 -46) 📝 `spotify_player/src/event/popup.rs` (+26 -21) 📝 `spotify_player/src/event/window.rs` (+23 -23) 📝 `spotify_player/src/main.rs` (+39 -33) 📝 `spotify_player/src/spirc.rs` (+22 -11) 📝 `spotify_player/src/ui/mod.rs` (+19 -12) </details> ### 📄 Description ## Brief description of changes - use `tokio::sync::mpsc` instead of `std::sync::mpsc`. Rename `send, recv` as channel variable to `client_pub, client_sub` - add `ClientRequest::NewSpircConnection` and `Command::ReconnectIntegratedClient` that restarts a spirc connection - cleanup the `client::spotify` code --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-14 15:18:40 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-player#1522
No description provided.