mytunes-pro 2.0.6__tar.gz → 2.0.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mytunes-pro
3
- Version: 2.0.6
3
+ Version: 2.0.8
4
4
  Summary: A lightweight, keyboard-centric terminal player for streaming YouTube music.
5
5
  Author-email: loxo <loxo5432@gmail.com>
6
6
  Project-URL: Homepage, https://github.com/postgresql-co-kr/mytunes
@@ -18,9 +18,9 @@ Requires-Dist: yt-dlp
18
18
  Requires-Dist: pusher
19
19
  Dynamic: license-file
20
20
 
21
- # 🎵 MyTunes Pro - Professional TUI Edition v2.0.5
21
+ # 🎵 MyTunes Pro - Professional TUI Edition v2.0.8
22
22
 
23
- ## 🚀 Terminal-based Media Workflow Experiment v2.0.5
23
+ ## 🚀 Terminal-based Media Workflow Experiment v2.0.8
24
24
 
25
25
  > [!IMPORTANT]
26
26
  > **Legal Disclaimer:** This project is a personal, non-commercial research experiment for developer education.
@@ -187,6 +187,7 @@ Executes immediately without worrying about input language status.
187
187
  | **`+`** | **Vol UP** | Volume +5% (Same as `=`) |
188
188
  | **`-`** | **Vol DOWN** | Volume -5% (Same as `_`) |
189
189
  | **`F7`** | **Open YouTube** | View current track in browser |
190
+ | **`E`** | **Equalizer** | Cycle EQ presets (Auto/Flat/Pop/Rock/Jazz/etc.) |
190
191
  | **`6`** | **Back** | Go to previous screen (Same as `Q`, `h`) |
191
192
  | **`L`** | **Forward** | Go forward to previous screen (`Right Arrow`) |
192
193
  | **`ESC`** | **Background** | **Exit without stopping music** (Background Play) |
@@ -215,7 +216,7 @@ Executes immediately without worrying about input language status.
215
216
 
216
217
  # 🎵 MyTunes Pro (Experimental Media Tool - KR)
217
218
 
218
- ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.5
219
+ ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.8
219
220
 
220
221
  > [!IMPORTANT]
221
222
  > **법적 면책 고지:** 본 프로젝트는 개발자 교육 및 연구를 목적으로 하는 개인적, 비상업적 실험입니다.
@@ -360,6 +361,7 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
360
361
  | **`+`** | **볼륨 UP** | 볼륨 +5% (단축키 `=`와 동일) |
361
362
  | **`-`** | **볼륨 DOWN** | 볼륨 -5% (단축키 `_`와 동일) |
362
363
  | **`F7`** | **유튜브 열기** | 현재 곡을 브라우저에서 보기 |
364
+ | **`E`** | **이퀄라이저** | EQ 프리셋 전환 (Auto/Flat/Pop/Rock/Jazz 등) |
363
365
  | **`6`** | **뒤로가기** | 이전 화면으로 이동 (단축키 `Q`, `h`와 동일) |
364
366
  | **`L`** | **앞으로** | 이전 화면에서 앞화면으로 다시 이동 (`Right Arrow`) |
365
367
  | **`ESC`** | **배경재생** | **음악 끄지 않고 나가기** (백그라운드 재생) |
@@ -388,6 +390,22 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
388
390
 
389
391
  ## 🔄 Changelog
390
392
 
393
+ ### v2.0.8 (2026-02-02)
394
+ - **Windows/WSL Socket Recovery**: Fixed UI freezing when mpv socket disconnects during window switching.
395
+ - **IPC Resilience**: Added socket pre-check and failure counter to prevent blocking on broken connections.
396
+ - **Automatic Recovery**: New playback automatically restarts mpv if socket is unhealthy.
397
+
398
+ ### v2.0.7 (2026-02-02)
399
+ - **Performance Optimization**: Improved keyboard responsiveness on Windows/WSL by implementing EQ detection caching.
400
+ - **Data Management**: Limited resume data to 500 entries with automatic FIFO cleanup to prevent JSON bloat.
401
+ - **Cache System**: Added 200-entry EQ genre cache to skip redundant keyword matching for repeated tracks.
402
+
403
+ ### v2.0.6 (2026-02-02)
404
+ - **10-Band Equalizer**: Added professional-grade 10-band EQ with presets (Flat, Pop, Rock, Jazz, Classical, Full Bass, Dance, Club, Live, Soft).
405
+ - **Auto EQ Detection**: Intelligent genre detection from track title/channel info automatically applies optimal EQ preset.
406
+ - **Keyboard Shortcut**: Press `E` to cycle through EQ presets in real-time without interrupting playback.
407
+ - **Multilingual Genre Keywords**: Auto EQ supports genre detection in 12 languages including Korean, Japanese, Chinese, Spanish, and more.
408
+
391
409
  ### v2.0.5 (2026-02-01)
392
410
  - **Input Feedback Refinement**: Transitioned from blinking warnings to a static Bold Yellow status message for better accessibility and premium feel.
393
411
  - **Auto-clear Optimization**: Implemented a 5-second auto-clear timer for all transient status messages.
@@ -1,6 +1,6 @@
1
- # 🎵 MyTunes Pro - Professional TUI Edition v2.0.5
1
+ # 🎵 MyTunes Pro - Professional TUI Edition v2.0.8
2
2
 
3
- ## 🚀 Terminal-based Media Workflow Experiment v2.0.5
3
+ ## 🚀 Terminal-based Media Workflow Experiment v2.0.8
4
4
 
5
5
  > [!IMPORTANT]
6
6
  > **Legal Disclaimer:** This project is a personal, non-commercial research experiment for developer education.
@@ -167,6 +167,7 @@ Executes immediately without worrying about input language status.
167
167
  | **`+`** | **Vol UP** | Volume +5% (Same as `=`) |
168
168
  | **`-`** | **Vol DOWN** | Volume -5% (Same as `_`) |
169
169
  | **`F7`** | **Open YouTube** | View current track in browser |
170
+ | **`E`** | **Equalizer** | Cycle EQ presets (Auto/Flat/Pop/Rock/Jazz/etc.) |
170
171
  | **`6`** | **Back** | Go to previous screen (Same as `Q`, `h`) |
171
172
  | **`L`** | **Forward** | Go forward to previous screen (`Right Arrow`) |
172
173
  | **`ESC`** | **Background** | **Exit without stopping music** (Background Play) |
@@ -195,7 +196,7 @@ Executes immediately without worrying about input language status.
195
196
 
196
197
  # 🎵 MyTunes Pro (Experimental Media Tool - KR)
197
198
 
198
- ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.5
199
+ ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.8
199
200
 
200
201
  > [!IMPORTANT]
201
202
  > **법적 면책 고지:** 본 프로젝트는 개발자 교육 및 연구를 목적으로 하는 개인적, 비상업적 실험입니다.
@@ -340,6 +341,7 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
340
341
  | **`+`** | **볼륨 UP** | 볼륨 +5% (단축키 `=`와 동일) |
341
342
  | **`-`** | **볼륨 DOWN** | 볼륨 -5% (단축키 `_`와 동일) |
342
343
  | **`F7`** | **유튜브 열기** | 현재 곡을 브라우저에서 보기 |
344
+ | **`E`** | **이퀄라이저** | EQ 프리셋 전환 (Auto/Flat/Pop/Rock/Jazz 등) |
343
345
  | **`6`** | **뒤로가기** | 이전 화면으로 이동 (단축키 `Q`, `h`와 동일) |
344
346
  | **`L`** | **앞으로** | 이전 화면에서 앞화면으로 다시 이동 (`Right Arrow`) |
345
347
  | **`ESC`** | **배경재생** | **음악 끄지 않고 나가기** (백그라운드 재생) |
@@ -368,6 +370,22 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
368
370
 
369
371
  ## 🔄 Changelog
370
372
 
373
+ ### v2.0.8 (2026-02-02)
374
+ - **Windows/WSL Socket Recovery**: Fixed UI freezing when mpv socket disconnects during window switching.
375
+ - **IPC Resilience**: Added socket pre-check and failure counter to prevent blocking on broken connections.
376
+ - **Automatic Recovery**: New playback automatically restarts mpv if socket is unhealthy.
377
+
378
+ ### v2.0.7 (2026-02-02)
379
+ - **Performance Optimization**: Improved keyboard responsiveness on Windows/WSL by implementing EQ detection caching.
380
+ - **Data Management**: Limited resume data to 500 entries with automatic FIFO cleanup to prevent JSON bloat.
381
+ - **Cache System**: Added 200-entry EQ genre cache to skip redundant keyword matching for repeated tracks.
382
+
383
+ ### v2.0.6 (2026-02-02)
384
+ - **10-Band Equalizer**: Added professional-grade 10-band EQ with presets (Flat, Pop, Rock, Jazz, Classical, Full Bass, Dance, Club, Live, Soft).
385
+ - **Auto EQ Detection**: Intelligent genre detection from track title/channel info automatically applies optimal EQ preset.
386
+ - **Keyboard Shortcut**: Press `E` to cycle through EQ presets in real-time without interrupting playback.
387
+ - **Multilingual Genre Keywords**: Auto EQ supports genre detection in 12 languages including Korean, Japanese, Chinese, Spanish, and more.
388
+
371
389
  ### v2.0.5 (2026-02-01)
372
390
  - **Input Feedback Refinement**: Transitioned from blinking warnings to a static Bold Yellow status message for better accessibility and premium feel.
373
391
  - **Auto-clear Optimization**: Implemented a 5-second auto-clear timer for all transient status messages.
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "mytunes-pro"
7
- version = "2.0.6"
7
+ version = "2.0.8"
8
8
  authors = [
9
9
  { name = "loxo", email = "loxo5432@gmail.com" },
10
10
  ]
@@ -44,7 +44,7 @@ MPV_SOCKET = "/tmp/mpv_socket"
44
44
  LOG_FILE = "/tmp/mytunes_mpv.log"
45
45
  PID_FILE = "/tmp/mytunes_mpv.pid"
46
46
  APP_NAME = "MyTunes Pro"
47
- APP_VERSION = "2.0.6"
47
+ APP_VERSION = "2.0.8"
48
48
 
49
49
  # === [Strings & Localization] ===
50
50
  STRINGS = {
@@ -171,6 +171,12 @@ class DataManager:
171
171
  def set_progress(self, url, time_pos):
172
172
  if "resume" not in self.data: self.data["resume"] = {}
173
173
  self.data["resume"][url] = time_pos
174
+ # Limit resume data to 500 entries (FIFO cleanup)
175
+ if len(self.data["resume"]) > 500:
176
+ # Remove oldest entries (first 100)
177
+ keys = list(self.data["resume"].keys())
178
+ for k in keys[:100]:
179
+ del self.data["resume"][k]
174
180
 
175
181
  def add_history(self, item):
176
182
  self.data['history'] = [h for h in self.data['history'] if h['url'] != item['url']]
@@ -298,6 +304,8 @@ class Player:
298
304
  self.current_proc = None
299
305
  self.loading = False
300
306
  self.loading_ts = 0
307
+ self.socket_fail_count = 0 # Track consecutive IPC failures
308
+ self.socket_ok = True # Socket health flag
301
309
 
302
310
  # Cleanup pre-existing instance if any
303
311
  # self.cleanup_orphaned_mpv() # Moved to play() per user request
@@ -333,6 +341,9 @@ class Player:
333
341
 
334
342
  # 2. Fallback: Clean up and start fresh (Aggressive)
335
343
  self.cleanup_orphaned_mpv()
344
+ # Reset socket health for fresh start
345
+ self.socket_fail_count = 0
346
+ self.socket_ok = True
336
347
 
337
348
  self.stop()
338
349
  self.loading = True
@@ -418,6 +429,12 @@ class Player:
418
429
 
419
430
  def send_cmd(self, command):
420
431
  """Send raw command list to MPV via JSON IPC."""
432
+ # Pre-check: Skip if socket file doesn't exist (Windows/WSL resilience)
433
+ if not os.path.exists(MPV_SOCKET):
434
+ self.socket_fail_count += 1
435
+ self.socket_ok = False
436
+ return None
437
+
421
438
  try:
422
439
  client = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
423
440
  client.settimeout(0.5) # Fast timeout (Optimization for Sleep/Wake resilience)
@@ -434,8 +451,14 @@ class Player:
434
451
  if b"\n" in chunk: break
435
452
 
436
453
  client.close()
454
+ # Success: Reset failure counter
455
+ self.socket_fail_count = 0
456
+ self.socket_ok = True
437
457
  return json.loads(response.decode('utf-8'))
438
458
  except:
459
+ self.socket_fail_count += 1
460
+ if self.socket_fail_count >= 3:
461
+ self.socket_ok = False
439
462
  return None
440
463
 
441
464
  def get_property(self, prop):
@@ -515,6 +538,7 @@ class MyTunesApp:
515
538
  self.last_save_time = time.time()
516
539
  self.status_set_time = 0
517
540
  self.auto_preset_name = "Pop" # Default Auto detected genre
541
+ self._eq_cache = {} # Cache: {url: detected_genre} to avoid re-computation
518
542
 
519
543
  # Throttling Counters
520
544
  self.loop_count = 0
@@ -895,6 +919,20 @@ class MyTunesApp:
895
919
  Smart genre detection using weighted scoring.
896
920
  Analyzes Title and Author for keywords.
897
921
  """
922
+ # Cache check: return cached result if available
923
+ if not isinstance(item, str):
924
+ url = item.get('url', '')
925
+ if url and url in self._eq_cache:
926
+ cached = self._eq_cache[url]
927
+ self.auto_preset_name = cached
928
+ return cached
929
+ # Limit cache size to 200 entries
930
+ if len(self._eq_cache) > 200:
931
+ # Remove first 50 entries
932
+ keys = list(self._eq_cache.keys())
933
+ for k in keys[:50]:
934
+ del self._eq_cache[k]
935
+
898
936
  # Prepare texts
899
937
  title_text = ""
900
938
  extra_text = ""
@@ -1059,10 +1097,16 @@ class MyTunesApp:
1059
1097
 
1060
1098
  if scores[best_genre] > 0:
1061
1099
  self.auto_preset_name = best_genre
1100
+ # Save to cache
1101
+ if not isinstance(item, str) and item.get('url'):
1102
+ self._eq_cache[item['url']] = best_genre
1062
1103
  return best_genre
1063
1104
 
1064
1105
  # Default Fallback
1065
1106
  self.auto_preset_name = "Pop"
1107
+ # Cache fallback too
1108
+ if not isinstance(item, str) and item.get('url'):
1109
+ self._eq_cache[item['url']] = "Pop"
1066
1110
  return "Pop"
1067
1111
 
1068
1112
  def play_music(self, item, interactive=True, preserve_queue=False):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mytunes-pro
3
- Version: 2.0.6
3
+ Version: 2.0.8
4
4
  Summary: A lightweight, keyboard-centric terminal player for streaming YouTube music.
5
5
  Author-email: loxo <loxo5432@gmail.com>
6
6
  Project-URL: Homepage, https://github.com/postgresql-co-kr/mytunes
@@ -18,9 +18,9 @@ Requires-Dist: yt-dlp
18
18
  Requires-Dist: pusher
19
19
  Dynamic: license-file
20
20
 
21
- # 🎵 MyTunes Pro - Professional TUI Edition v2.0.5
21
+ # 🎵 MyTunes Pro - Professional TUI Edition v2.0.8
22
22
 
23
- ## 🚀 Terminal-based Media Workflow Experiment v2.0.5
23
+ ## 🚀 Terminal-based Media Workflow Experiment v2.0.8
24
24
 
25
25
  > [!IMPORTANT]
26
26
  > **Legal Disclaimer:** This project is a personal, non-commercial research experiment for developer education.
@@ -187,6 +187,7 @@ Executes immediately without worrying about input language status.
187
187
  | **`+`** | **Vol UP** | Volume +5% (Same as `=`) |
188
188
  | **`-`** | **Vol DOWN** | Volume -5% (Same as `_`) |
189
189
  | **`F7`** | **Open YouTube** | View current track in browser |
190
+ | **`E`** | **Equalizer** | Cycle EQ presets (Auto/Flat/Pop/Rock/Jazz/etc.) |
190
191
  | **`6`** | **Back** | Go to previous screen (Same as `Q`, `h`) |
191
192
  | **`L`** | **Forward** | Go forward to previous screen (`Right Arrow`) |
192
193
  | **`ESC`** | **Background** | **Exit without stopping music** (Background Play) |
@@ -215,7 +216,7 @@ Executes immediately without worrying about input language status.
215
216
 
216
217
  # 🎵 MyTunes Pro (Experimental Media Tool - KR)
217
218
 
218
- ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.5
219
+ ## 🚀 터미널 기반 미디어 워크플로우 실험 v2.0.8
219
220
 
220
221
  > [!IMPORTANT]
221
222
  > **법적 면책 고지:** 본 프로젝트는 개발자 교육 및 연구를 목적으로 하는 개인적, 비상업적 실험입니다.
@@ -360,6 +361,7 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
360
361
  | **`+`** | **볼륨 UP** | 볼륨 +5% (단축키 `=`와 동일) |
361
362
  | **`-`** | **볼륨 DOWN** | 볼륨 -5% (단축키 `_`와 동일) |
362
363
  | **`F7`** | **유튜브 열기** | 현재 곡을 브라우저에서 보기 |
364
+ | **`E`** | **이퀄라이저** | EQ 프리셋 전환 (Auto/Flat/Pop/Rock/Jazz 등) |
363
365
  | **`6`** | **뒤로가기** | 이전 화면으로 이동 (단축키 `Q`, `h`와 동일) |
364
366
  | **`L`** | **앞으로** | 이전 화면에서 앞화면으로 다시 이동 (`Right Arrow`) |
365
367
  | **`ESC`** | **배경재생** | **음악 끄지 않고 나가기** (백그라운드 재생) |
@@ -388,6 +390,22 @@ Windows 환경에서 한글 검색이 안 되거나 설치가 어려운 분들
388
390
 
389
391
  ## 🔄 Changelog
390
392
 
393
+ ### v2.0.8 (2026-02-02)
394
+ - **Windows/WSL Socket Recovery**: Fixed UI freezing when mpv socket disconnects during window switching.
395
+ - **IPC Resilience**: Added socket pre-check and failure counter to prevent blocking on broken connections.
396
+ - **Automatic Recovery**: New playback automatically restarts mpv if socket is unhealthy.
397
+
398
+ ### v2.0.7 (2026-02-02)
399
+ - **Performance Optimization**: Improved keyboard responsiveness on Windows/WSL by implementing EQ detection caching.
400
+ - **Data Management**: Limited resume data to 500 entries with automatic FIFO cleanup to prevent JSON bloat.
401
+ - **Cache System**: Added 200-entry EQ genre cache to skip redundant keyword matching for repeated tracks.
402
+
403
+ ### v2.0.6 (2026-02-02)
404
+ - **10-Band Equalizer**: Added professional-grade 10-band EQ with presets (Flat, Pop, Rock, Jazz, Classical, Full Bass, Dance, Club, Live, Soft).
405
+ - **Auto EQ Detection**: Intelligent genre detection from track title/channel info automatically applies optimal EQ preset.
406
+ - **Keyboard Shortcut**: Press `E` to cycle through EQ presets in real-time without interrupting playback.
407
+ - **Multilingual Genre Keywords**: Auto EQ supports genre detection in 12 languages including Korean, Japanese, Chinese, Spanish, and more.
408
+
391
409
  ### v2.0.5 (2026-02-01)
392
410
  - **Input Feedback Refinement**: Transitioned from blinking warnings to a static Bold Yellow status message for better accessibility and premium feel.
393
411
  - **Auto-clear Optimization**: Implemented a 5-second auto-clear timer for all transient status messages.
File without changes
File without changes