Datasets:
task_id stringlengths 6 6 | category stringclasses 5
values | prompt stringlengths 88 323 | api_description stringclasses 1
value | expected_output stringlengths 18 111 |
|---|---|---|---|---|
uv-000 | versions | Sort these versions into PEP 440 order, lowest first: '1.0.0.post1', '1.0.0', '1.0.0rc1', '1.0.0a1', '1.0.0.dev1', '1.0.0b1'. Return one row of the six version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0.0.dev1", "1.0.0a1", "1.0.0b1", "1.0.0rc1", "1.0.0", "1.0.0.post1"]]} |
uv-001 | versions | Are '1.0', '1.0.0' and '1.0.0.0' equal under PEP 440? Give 1 or 0 for each of the comparisons 1.0 == 1.0.0, 1.0.0 == 1.0.0.0 and 1.0 == 1.0.0.0. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 1]]} |
uv-002 | versions | PEP 440 epochs. Sort '2.0', '1!1.0' and '1!0.5' lowest first. Return one row of the three version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["2.0", "1!0.5", "1!1.0"]]} |
uv-003 | versions | Where does a LOCAL version sort? Sort '1.0.0', '1.0.0+local', '1.0.0.post1' and '1.0.0rc1' lowest first. Return one row of the four version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0.0rc1", "1.0.0", "1.0.0+local", "1.0.0.post1"]]} |
uv-004 | versions | Give 1 if the version is a pre-release and 0 if not, for '1.0.0', '1.0.0rc1', '1.0.0.post1', '1.0.0.dev1' and '1.1.0rc1'. Return one row of five values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[0, 1, 0, 1, 1]]} |
uv-005 | versions | Normalise these version strings the way PEP 440 does and give the results: '1.0.0-alpha.1', '1.0.0-rc1', '1.0.0.RELEASE'. If a string cannot be parsed, give the exact word 'invalid' instead. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0.0a1", "1.0.0rc1", "invalid"]]} |
uv-006 | versions | Sort every version of 'epsilon' in the index into PEP 440 order, lowest first, and then give how many of them are pre-releases. Return one row: the version strings followed by the count. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["0.5.0", "1.0.0", "1.1.0rc1", 1]]} |
uv-007 | specifiers | The compatible-release operator. For the specifier '~=1.4.2', give 1 or 0 for whether it matches '1.4.2', '1.4.9', '1.5.0' and '1.4.1'. Return one row of four values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 0, 0]]} |
uv-008 | specifiers | For the specifier '~=1.4', give 1 or 0 for whether it matches '1.4.0', '1.9.0', '2.0.0' and '1.3.0'. Return one row of four values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 0, 0]]} |
uv-009 | specifiers | Wildcard equality. For '==1.4.*', give 1 or 0 for '1.4.0', '1.4.9', '1.5.0' and '1.40.0'. Return one row of four values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 0, 0]]} |
uv-010 | specifiers | THE PRE-RELEASE ASYMMETRY. Using the specifier '>=1.0' and the candidate list ['0.9', '1.0', '1.1.0rc1', '1.1.0', '2.0.0a1'], give (a) how many candidates the `in` operator accepts, and (b) how many SpecifierSet.filter returns with its default settings. Return one row of the two integers. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[4, 2]]} |
uv-011 | specifiers | Continuing the asymmetry: give the versions SpecifierSet('>=1.0').filter returns from ['0.9', '1.0', '1.1.0rc1', '1.1.0', '2.0.0a1'], in the order returned. Then do the same for SpecifierSet('>=1.0rc1'). Return two rows of version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0", "1.1.0"], ["1.0", "1.1.0rc1", "1.1.0", "2.0.0a1"]]} |
uv-012 | specifiers | For the combined specifier '>=1.0,<2.0,!=1.5.0', give 1 or 0 for '1.0.0', '1.5.0', '1.9.9' and '2.0.0'. Return one row of four values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 0, 1, 0]]} |
uv-013 | specifiers | Which versions of 'beta' in the index satisfy '>=1.0,<1.1'? Give them newest first. Return one row of version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0.1", "1.0.0"]]} |
uv-014 | specifiers | Which versions of 'epsilon' in the index satisfy '>=0.5' with pre-releases excluded, and which satisfy '>=1.1.0rc1'? Give each newest first. Return two rows of version strings. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["1.0.0", "0.5.0"], ["1.1.0rc1"]]} |
uv-015 | markers | Evaluate the PEP 508 marker 'python_version >= "3.11"' in each of the environments linux311, win310 and macarm312. Give 1 or 0 for each, in that order. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 0, 1]]} |
uv-016 | markers | Evaluate 'sys_platform == "linux" and platform_machine == "x86_64"' in linux311, win310 and macarm312. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 0, 0]]} |
uv-017 | markers | Evaluate 'sys_platform != "win32" or python_version < "3.11"' in linux311, win310 and macarm312. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 1]]} |
uv-018 | markers | python_version is compared as a VERSION, not lexically. For the marker 'python_version >= "3.9"', give its value in linux311, win310 and macarm312; then give what a NAIVE LEXICAL string comparison of that environment's python_version against "3.9" would give in the same three environments. Return two rows of three valu... | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 1, 1], [0, 0, 0]]} |
uv-019 | markers | How many of the three environments satisfy 'platform_system == "Darwin" and platform_machine == "arm64"', and which one — give its name, or the exact word 'none'. Return one row [count, name]. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, "macarm312"]]} |
uv-020 | markers | Given the requirement list ['gamma>=0.2', 'delta>=2 ; sys_platform == "win32"', 'epsilon>=1 ; python_version >= "3.12"'], give the number of requirements that APPLY in linux311, in win310 and in macarm312. Return one row of three values. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[1, 2, 2]]} |
uv-021 | resolution | Resolve the single requirement 'alpha' against the fixed index under the stated rules. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "2.0.0"], ["beta", "1.1.0"], ["delta", "2.1.0"], ["gamma", "0.3.0"]]} |
uv-022 | resolution | Resolve 'alpha<2'. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "1.2.0"], ["beta", "1.1.0"], ["gamma", "0.3.0"]]} |
uv-023 | resolution | Resolve 'alpha==1.0.0'. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "1.0.0"], ["beta", "1.0.1"], ["gamma", "0.3.0"]]} |
uv-024 | resolution | Resolve the two requirements 'alpha' and 'gamma<0.3' together. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "1.1.0"], ["beta", "1.0.1"], ["gamma", "0.2.0"]]} |
uv-025 | resolution | Resolve 'delta>=2' together with 'gamma>=0.3'. This forces a backtrack: delta 2.0.0 requires gamma<0.3. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["delta", "2.1.0"], ["gamma", "0.3.0"]]} |
uv-026 | resolution | Resolve 'epsilon'. Note the pre-release rule. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["epsilon", "1.0.0"], ["gamma", "0.3.0"]]} |
uv-027 | resolution | Give the number of packages in the resolution of 'alpha', of 'alpha<2', and of 'delta>=2'. Return one row of three integers. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[4, 3, 2]]} |
uv-028 | resolution | Is the requirement pair 'alpha==1.2.0' and 'gamma<0.3' satisfiable? Give 1 or 0, then the number of packages in the resolution (0 if unsatisfiable). Return one row of two integers. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[0, 0]]} |
uv-029 | resolution | Is 'alpha==1.2.0' together with 'gamma==0.1.0' satisfiable? Give 1 or 0, then the number of packages in the resolution (0 if unsatisfiable). Return one row of two integers. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[0, 0]]} |
uv-030 | extras | Resolve 'alpha[plus]<2' — alpha with its 'plus' extra. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "1.2.0"], ["beta", "1.1.0"], ["delta", "2.1.0"], ["epsilon", "1.0.0"], ["gamma", "0.3.0"]]} |
uv-031 | extras | Resolve 'alpha[plus]==2.0.0'. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "2.0.0"], ["beta", "1.1.0"], ["delta", "2.1.0"], ["epsilon", "1.0.0"], ["gamma", "0.3.0"]]} |
uv-032 | extras | How many packages does 'alpha<2' resolve to WITHOUT the plus extra, and how many WITH it? Return one row of two integers. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [[3, 5]]} |
uv-033 | extras | Resolve 'beta[fast]'. Return one row per resolved package, [name, version], sorted by name. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["beta", "1.1.0"], ["delta", "2.1.0"], ["gamma", "0.3.0"]]} |
uv-034 | extras | Give the names of every package in the resolution of 'alpha[plus]<2', sorted alphabetically. Return one row of the names. | The tasks use this FIXED package index. There is no network; these are all the
distributions that exist.
alpha: 1.0.0, 1.1.0, 1.2.0, 2.0.0
beta: 0.9.0, 1.0.0, 1.0.1, 1.1.0
gamma: 0.1.0, 0.2.0, 0.3.0
delta: 1.0.0, 2.0.0, 2.1.0
epsilon: 0.5.0, 1.0.0, 1.1.0rc1
Requirements of each distribution:
alp... | {"rows": [["alpha", "beta", "delta", "epsilon", "gamma"]]} |
uv-tasks-v1
35 Python-packaging tasks for the
uv-env RL
environment: PEP 440 version ordering, PEP 440 specifier matching, PEP 508 environment markers,
extras expansion, and dependency resolution with backtracking over a fixed index.
| field | meaning |
|---|---|
task_id |
uv-000 … uv-034 |
category |
versions / specifiers / markers / resolution / extras |
prompt |
the question and the exact shape of the answer |
api_description |
the fixed package index with every version and requirement, the resolution rules, and the three marker environments |
expected_output |
JSON {"rows": [...]}, computed by executing a reference solution |
Categories: versions 7, specifiers 8, markers 6, resolution 9, extras 5.
Requires packaging>=24.0 in the sandbox; nothing else, and no network.
Why this dataset exists
uv sat unclaimed on the reasoning that "resolution needs the network, so it cannot be made
deterministic." That is only true of resolution against a live index. Everything that makes
uv's behaviour hard to predict is offline semantics — version ordering, specifier matching,
marker evaluation, extras, and the resolver's own backtracking. State the index in the prompt
and the whole thing is a pure function.
The trap, measured rather than assumed
Version("1.1.0rc1") in SpecifierSet(">=1.0") # -> True
SpecifierSet(">=1.0").filter([..., "1.1.0rc1"]) # -> 1.1.0rc1 is EXCLUDED
__contains__ admits pre-releases when prereleases is None; filter excludes them. A
resolver written with in silently installs release candidates and one written with filter
does not — and filter is what uv and pip do.
That single asymmetry is the difference between a correct resolution answer key and a
confidently wrong one. It was found by running both, not by reasoning about the spec, and two
tasks ask about it directly. The builder asserts the two still disagree, so an upstream change
to packaging cannot quietly turn those tasks into tautologies.
Other things the tasks pin down
python_versionis compared as a version, not lexically:"3.10" >= "3.9"isFalseas strings andTrueas versions, and one task shows both side by side.~=1.4.2matches1.4.9but not1.5.0;~=1.4matches1.9.0but not2.0.0.1.0.0+localsorts after1.0.0and before1.0.0.post1.1.0.0.RELEASEis not a valid PEP 440 version at all, while1.0.0-alpha.1normalises to1.0.0a1.- One resolution is deliberately unsatisfiable, and one forces a backtrack off
delta 2.0.0because it requiresgamma<0.3whilebeta 1.1.0requiresgamma>=0.3.
The resolver's own answers are re-validated
A backtracking resolver that is subtly wrong will happily return a subtly wrong answer, so every resolution in the answer key is re-checked from scratch by a separate function that shares no code with the search: every root constraint and every requirement of every chosen distribution must hold against the chosen versions.
Verify with python environments/uv_env/build_tasks.py --verify (35/35).
Source: https://github.com/eltociear/my-molt-agent/tree/main/environments/uv_env
- Downloads last month
- -