uv icon indicating copy to clipboard operation
uv copied to clipboard

Support `--with-requirements script.py` to include inline dependency metadata from another script

Open blueraft opened this issue 8 months ago • 4 comments

Summary

Closes #6542

Test Plan

cargo test

blueraft avatar Apr 08 '25 21:04 blueraft

That was more straight-forward than I assumed! I think we'll need to align on the interface.

zanieb avatar Apr 08 '25 21:04 zanieb

  • Also consider it for uv run: https://github.com/astral-sh/uv/issues/7032

T-256 avatar Apr 09 '25 00:04 T-256

@blueraft I wonder if we can push this forward? I think support in --with-requirements might make sense still, given we read a bunch of other file types there. I wonder if we can just sniff for a PEP 723 inline metadata entry in the script if there's no file extension?

zanieb avatar May 15 '25 14:05 zanieb

I wonder if we can just sniff for a PEP 723 inline metadata entry in the script if there's no file extension?

Yeah, I think we could do that. Let me give that a try!

blueraft avatar May 15 '25 15:05 blueraft

Thank you so much for your patience here!

zanieb avatar Sep 05 '25 16:09 zanieb