astral-uv:konsti/rockwren

Last commit made on 2024-02-21
Get this branch:
git clone -b konsti/rockwren https://git.launchpad.net/astral-uv

Branch merges

Branch information

Name:
konsti/rockwren
Repository:
lp:astral-uv

Recent commits

b314b8b... by konstin

.

5d53040... by Charlie Marsh <email address hidden>

Stream zip archive when fetching non-range-request metadata (#1792)

## Summary

If a registry doesn't support range requests, then today, we download
the entire wheel to disk and then read the metadata from the downloaded
archive. This PR instead modifies the registry client to stream the
zipfile and stop as soon as it's seen the metadata, which should be more
efficient.

Closes https://github.com/astral-sh/uv/issues/1596.

## Test Plan

Made this the _only_ path for downloading metadata; verified that the
test suite passed.

31752bf... by Evgeniy

feat: Implement `--annotation-style` parameter for `uv pip compile` (#1679)

## Summary

Hello there! The motivation for this feature is described here #1678

## Test Plan

I've added unit tests and also tested this manually on my work project
by comparing it to the original `pip-compile` output - it looks much
like the `pip-compile` generated lock file.

3cd51ff... by Zanie Blue <email address hidden>

Support setting request timeout with `UV_HTTP_TIMEOUT` and `HTTP_TIMEOUT` (#1780)

Follow-up to #1694 matching Cargo's environment variable names

https://doc.rust-lang.org/nightly/cargo/reference/config.html#httptimeout

d07b587... by Zanie Blue <email address hidden>

Retain passwords in Git URLs (#1717)

Fixes handling of GitHub PATs in HTTPS URLs, which were otherwise
dropped. We now supporting the following authentication schemes:

```
git+https://<user>:<token>/...
git+https://<token>/...
```

On Windows, the username is required. We can consider adding a
special-case for this in the future, but this just matches libgit2's
behavior.

I tested with fine-grained tokens, OAuth tokens, and "classic" tokens.
There's test coverage for fine-grained tokens in CI where we use a real
private repository and PAT. Yes, the PAT is committed to make this test
usable by anyone. It has read-only permissions to the single repository,
expires Feb 1 2025, and is in an isolated organization and GitHub
account.

Does not yet address SSH authentication.

Related:
- https://github.com/astral-sh/uv/issues/1514
- https://github.com/astral-sh/uv/issues/1452

2e60c1d... by =?utf-8?q?Edgar_Ram=C3=ADrez_Mondrag=C3=B3n?= <email address hidden>

Use the right marker for the `implementation` field of `pyvenv.cfg` (#1785)

## Summary

The generated `pyvenv.cfg` file hardcodes `implementation = CPython`
even for PyPy venvs, created with `uv venv venv --python pypy3.10`, for
example.

```ini
home = /path/to/.pyenv/versions/pypy3.10-7.3.15/bin
implementation = CPython
version_info = 3.10
gourgeist = 0.0.4
include-system-site-packages = false
base-prefix = /path/to/.pyenv/versions/pypy3.10-7.3.15
base-exec-prefix = /path/to/.pyenv/versions/pypy3.10-7.3.15
base-executable = /path/to/.pyenv/versions/pypy3.10-7.3.15/bin/pypy3.10
```

## Test Plan

Manually verified that `pyvenv.cfg` now contains `implementation =
PyPy`. I can try refactoring `create_bare_venv` to make it more easily
testable, though.

f13d0ad... by Charlie Marsh <email address hidden>

Ensure that builds within the cache aren't considered Git repositories (#1782)

## Summary

Some packages encode logic to embed the current commit SHA in the
version tag, when built within a Git repo. This typically results in an
invalid (non-compliant) version. Here's an example from `pylzma`:
https://github.com/fancycode/pylzma/blob/ccb0e7cff3f6ecd5d38e73e9ca35502d7d670176/version.py#L45.

This PR adds a phony, empty `.git` to the cache root, to ensure that any
`git` commands fail.

Closes https://github.com/astral-sh/uv/issues/1768.

## Test Plan

- Create a tag on the current commit, like `v0.5.0`.
- Build `pylzma`, using a cache _within_ the repo:

```
rm -rf foo
cargo run venv
cargo run pip install "pylzma @ https://files.pythonhosted.org/packages/03/d8/10ef072c3cd4301a65a1b762b09eefa02baf8da23b9ea77ebe9546499975/pylzma-0.5.0.tar.gz" --verbose --cache-dir bar
```

d5a2a5f... by Charlie Marsh <email address hidden>

Add support for `>dev` specifier (#1776)

## Summary

Not a fan of this one but we don't have a clear policy on it yet so
feels weird to discriminate.

Closes https://github.com/astral-sh/uv/issues/1686.

8df48f0... by Charlie Marsh <email address hidden>

Fix pep508-rs tests without features (#1778)

2928c6e... by konstin

Backport changes from publish crates (#1739)

Backport of changes for the published new versions of pep440_rs and
pep508_rs to make it easier to keep them in sync.