删除 probe_target.py
This commit is contained in:
@@ -1,21 +0,0 @@
|
|||||||
import sys, json, importlib.util
|
|
||||||
sys.stdout.reconfigure(encoding="utf-8")
|
|
||||||
spec = importlib.util.spec_from_file_location("bridge", r"d:\Atie\Gitea\Thing\src-tauri\src\music\bridge.py")
|
|
||||||
b = importlib.util.module_from_spec(spec); spec.loader.exec_module(b)
|
|
||||||
client = b.get_client(["QQMusicClient"])
|
|
||||||
res = client.search("海阔天空")
|
|
||||||
s = res["QQMusicClient"][0]
|
|
||||||
rs = (s.raw_data or {}).get("search")
|
|
||||||
src = b._get_resolve_client("QQMusicClient")
|
|
||||||
print("raw song:", s.song_name, "| id", s.identifier)
|
|
||||||
# official alone, lossless_quality_is_sufficient=False, no cap
|
|
||||||
from musicdl.modules.utils.data import SongInfo
|
|
||||||
official = src._parsewithofficialapiv1
|
|
||||||
r2 = official(search_result=rs, song_info_flac=SongInfo(source="QQMusicClient"), lossless_quality_is_sufficient=False)
|
|
||||||
print("official-only uncapped -> ext=", getattr(r2,"ext",None), "valid=", getattr(r2,"with_valid_download_url",None))
|
|
||||||
for target in ("", "最高", "无损", "320K", "128K"):
|
|
||||||
r = b._resolve_song(src, rs, target)
|
|
||||||
print("target=%r ->" % target, "ext=", getattr(r,"ext",None), "bitrate=", getattr(r,"bitrate",None), "valid=", getattr(r,"with_valid_download_url",None))
|
|
||||||
# verify constant restored
|
|
||||||
import musicdl.modules.utils.qqutils as qq
|
|
||||||
print("restored SORTED len:", len(qq.SongFileType.SORTED_QUALITIES.value))
|
|
||||||
Reference in New Issue
Block a user