[FEAT] Automatic update logic for yt-dlp pip package#58
Conversation
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 10 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| [sys.executable, "-m", "pip", "install", "--upgrade", "--target", LIB_PATH, "yt-dlp"], | ||
| ["python", "-m", "pip", "install", "--upgrade", "--target", LIB_PATH, "yt-dlp"], | ||
| ["pip", "install", "--upgrade", "--target", LIB_PATH, "yt-dlp"], | ||
| ] |
There was a problem hiding this comment.
While the lib folder is in sys.path (as seen in run.py), installing yt-dlp with --target to the lib folder can create version conflicts. Since sys.path has lib before the system site-packages, the updated version in lib will take precedence. However, if yt-dlp is already installed system-wide (as indicated by requirements.txt), you could end up with duplicate installations. Additionally, --target doesn't handle dependencies the same way as normal pip install, which could lead to missing or conflicting dependency versions. Consider using pip install --upgrade without --target to upgrade the system installation, or ensure the lib folder is the only source of yt-dlp packages.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This feature will ensure the yt-dlp Python package is updated every 5 days, so users always have the latest version.