{"record":{"id":"a4ce12921df2c8a8","repo":"astral-sh/uv","slug":"pip-compile-s-max-rounds-is-unsupported-uv-al","errorCode":null,"errorMessage":"pip-compile's `--max-rounds` is unsupported (uv always resolves until convergence)","messagePattern":"pip-compile's `--max-rounds` is unsupported \\(uv always resolves until convergence\\)","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/uv-cli/src/compat.rs","lineNumber":105,"sourceCode":"        }\n\n        if let Some(resolver) = self.resolver {\n            match resolver {\n                Resolver::Backtracking => {\n                    warn_user!(\n                        \"pip-compile's `--resolver=backtracking` has no effect (uv always backtracks)\"\n                    );\n                }\n                Resolver::Legacy => {\n                    return Err(anyhow!(\n                        \"pip-compile's `--resolver=legacy` is unsupported (uv always backtracks)\"\n                    ));\n                }\n            }\n        }\n\n        if self.max_rounds.is_some() {\n            return Err(anyhow!(\n                \"pip-compile's `--max-rounds` is unsupported (uv always resolves until convergence)\"\n            ));\n        }\n\n        if self.client_cert.is_some() {\n            return Err(anyhow!(\n                \"pip-compile's `--client-cert` is unsupported (uv doesn't support dedicated client certificates)\"\n            ));\n        }\n\n        if self.emit_trusted_host {\n            return Err(anyhow!(\n                \"pip-compile's `--emit-trusted-host` is unsupported\"\n            ));\n        }\n\n        if self.no_emit_trusted_host {\n            warn_user!(","sourceCodeStart":87,"sourceCodeEnd":123,"githubUrl":"https://github.com/astral-sh/uv/blob/f1a42680ff5272232d65748acf338b19778dde24/crates/uv-cli/src/compat.rs#L87-L123","documentation":"pip-tools' `--max-rounds N` caps the number of iterative resolution rounds pip-compile performs before giving up. uv's resolver is not round-based — it resolves until convergence in one pass — so `PipCompileCompatArgs::validate()` rejects any `Some(max_rounds)` value instead of pretending a limit exists.","triggerScenarios":"`uv pip compile --max-rounds 10 requirements.in` (any integer value triggers it, including pip-compile's old default `--max-rounds 10` written out explicitly in scripts).","commonSituations":"CI jobs that copied verbose pip-compile invocations including the default round limit; teams raising/lowering rounds to work around old pip-tools non-convergence who then switch to uv.","solutions":["Remove `--max-rounds` from the command; uv resolves until it converges or fails on its own.","If you hit genuine non-convergence with uv, report it as a uv bug rather than re-adding the flag.","Clean up other unsupported pip-compile flags in the same script in one pass."],"exampleFix":"# before\nuv pip compile --max-rounds 10 requirements.in\n\n# after\nuv pip compile requirements.in","handlingStrategy":"validation","validationCode":"import re\n\ndef assert_no_round_limits(argv: list[str]) -> None:\n    if any(re.match(r\"--max-rounds(=|$)\", a) for a in argv):\n        raise ValueError(\"uv pip compile has no round limit; remove --max-rounds\")","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Strip pip-compile defaults like `--max-rounds 10` when migrating scripts.","Rely on uv's own convergence reporting instead of round budgets.","Keep migrated command lines in reviewable config files so dead flags are caught in code review."],"tags":["cli","pip-tools","compatibility","resolver","compile"],"backgroundTag":null,"analyzedSha":"f1a42680ff5272232d65748acf338b19778dde24","analyzedAt":"2026-08-16T04:51:47.599Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}