This commit adds inline dependencies which allows for tools like uv to create and manage the venv for you when run like this:
```bash
sudo uv run main.py
```
[Docs of uv on the topic](https://docs.astral.sh/uv/guides/scripts/#declaring-script-dependencies)
copilot-pull-request-reviewer[bot]
(Migrated from github.com)
left a comment
Copy Link
Copy Source
Pull request overview
This PR adds PEP 723-style inline script metadata to main.py so tools like uv can resolve and install the script’s Python dependencies automatically when running the script.
Changes:
Added a # /// script inline metadata block declaring tqdm, requests, and InquirerPy as dependencies.
## Pull request overview
This PR adds PEP 723-style inline script metadata to `main.py` so tools like `uv` can resolve and install the script’s Python dependencies automatically when running the script.
**Changes:**
- Added a `# /// script` inline metadata block declaring `tqdm`, `requests`, and `InquirerPy` as dependencies.
---
💡 <a href="/casualsnek/waydroid_script/new/main?filename=.github/instructions/*.instructions.md" class="Link--inTextBlock" target="_blank" rel="noopener noreferrer">Add Copilot custom instructions</a> for smarter, more guided reviews. <a href="https://docs.github.com/en/copilot/customizing-copilot/adding-repository-custom-instructions-for-github-copilot" class="Link--inTextBlock" target="_blank" rel="noopener noreferrer">Learn how to get started</a>.
The inline # /// script metadata is parsed as TOML (PEP 723 style). In a TOML array, items must be comma-separated; as written, the dependencies = [ block is invalid and tools like uv run --script will fail to parse it. Add commas between the dependency strings (a trailing comma is also fine).
# "InquirerPy",
The inline `# /// script` metadata is parsed as TOML (PEP 723 style). In a TOML array, items must be comma-separated; as written, the `dependencies = [` block is invalid and tools like `uv run --script` will fail to parse it. Add commas between the dependency strings (a trailing comma is also fine).
```suggestion
# "InquirerPy",
```
This introduces a second source of truth for runtime dependencies (inline here and also in requirements.txt). That duplication can drift over time and cause confusing install/runtime mismatches. Consider either generating/deriving one from the other, or documenting which one is authoritative (and when each should be updated).
This introduces a second source of truth for runtime dependencies (inline here and also in `requirements.txt`). That duplication can drift over time and cause confusing install/runtime mismatches. Consider either generating/deriving one from the other, or documenting which one is authoritative (and when each should be updated).
```suggestion
```
Checking for merge conflicts…
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
This commit adds inline dependencies which allows for tools like uv to create and manage the venv for you when run like this:
Docs of uv on the topic
Pull request overview
This PR adds PEP 723-style inline script metadata to
main.pyso tools likeuvcan resolve and install the script’s Python dependencies automatically when running the script.Changes:
# /// scriptinline metadata block declaringtqdm,requests, andInquirerPyas dependencies.💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
@@ -2,0 +6,4 @@# "dbus-python",# "gbinder",# "PyGObject",# "InquirerPy"The inline
# /// scriptmetadata is parsed as TOML (PEP 723 style). In a TOML array, items must be comma-separated; as written, thedependencies = [block is invalid and tools likeuv run --scriptwill fail to parse it. Add commas between the dependency strings (a trailing comma is also fine).@@ -2,0 +8,4 @@# "PyGObject",# "InquirerPy"# ]# ///This introduces a second source of truth for runtime dependencies (inline here and also in
requirements.txt). That duplication can drift over time and cause confusing install/runtime mismatches. Consider either generating/deriving one from the other, or documenting which one is authoritative (and when each should be updated).View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.