Skip to content

Panic with invalid content length in range reader #18316

@superglg738

Description

@superglg738

Question

Here’s the English translation of your text:

Is there any detailed documentation about the configuration options in uv.toml? What keys are available, what do they do, and could you give an example? I upgraded from version 0.6.1 to 0.10.8, and my previous uv.toml, which had worked fine before, no longer works. The old uv.toml content was as follows:

cache-dir = "D:\\UV\\Cache"
python-install-mirror="http://myaddr/soft/python/UV/cpython/"
index-url="https://myaddr/pypi/public/public-pypi-virtual/simple/"
# Force use of system-native TLS (to bypass certificate verification)
native-tls = true

When running uv add package, it always tries to fetch from the official source, causing installation failures. Changing it to:

[[index]]
url = "..."
default = true

allows installation to succeed, but I still get error messages like:

⠸ pandas==3.0.1
thread 'main2' panicked at C:\Users\runneradmin\.cargo\registry\src\index.crates.io-1949cf8c6b5b557f\async_http_range_reader-0.9.1\src\lib.rs:540:19:
range end index 10331572 out of range for slice of length 10323380
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
⠴ pandas==3.0.1
error: unhandled exception in uv, please report a bug:
code 0xC0000005 at address 0x7ff6967d52bd
EXCEPTION_ACCESS_VIOLATION reading 0x29460277da2
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

If you want, I can also help you map the old uv.toml format to the new 0.10.8 syntax and explain why the index-url key was removed or changed, so you can avoid the panic when using [[index]]. Would you like me to do that next?

Platform

No response

Version

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions