proud-planet-36170
07/12/2024, 2:52 PMpants --keep-sandboxes=on_failure generate-lockfiles --generate-lockfiles-resolve=python-udf-explanatory-prediction
but hitting this (package is in a private repo)
ERROR: Ignored the following versions that require a different python version: 0.1.0 Requires-Python >=3.11,<3.12; 0.1.1 Requires-Python >=3.11,<3.12; 0.1.2 Requires-Python >=3.11,<3.12
ERROR: Could not find a version that satisfies the requirement explanatory-model<0.2.0,>=0.1.2 (from versions: none)
pants.toml
[GLOBAL]
pants_version = "2.21.0"
...
[python]
enable_resolves = true
interpreter_constraints = ['>=3.11']
BUILD
__defaults__(all=dict(resolve="python-udf-explanatory-prediction"))
poetry_requirements(
name="poetry",
)
python_aws_lambda_function(
name="lambda",
runtime="python3.11",
handler="udf_explanatory_prediction/main.py:lambda_handler",
dependencies=[
"udf-explanatory-prediction/udf_explanatory_prediction:udf_explanatory_prediction",
],
)
pyproject.toml
[tool.poetry]
name = "udf-explanatory-prediction"
version = "0.1.0"
description = "..."
authors = ["..."]
readme = "README.md"
[tool.poetry.dependencies]
python = ">=3.11,<4"
explanatory-model = {version = "^0.1.2", source = "data"}
[[tool.poetry.source]]
name = "data"
url = "https://.../pypi/data/simple/"
priority = "supplemental"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
udf_explanatory_prediction/BUILD
python_sources(
dependencies=["udf-engagement-explanatory-prediction:poetry"],
)
python_tests(
name="tests",
)
curved-television-6568
07/12/2024, 5:12 PMinterpreter_constraints = ['>=3.11']
is not compatible with those of explanatory-model
using >=3.11,<3.12
. That is, yours are open ended, rather than capped with <3.12
.proud-planet-36170
07/12/2024, 5:16 PM[tool.poetry.dependencies]
python = ">=3.9"
#explanatory-model = {version = "0.1.4", source = "data"}
explanatory-model = { path = "./explanatory_model-0.1.4-py3-none-any.whl" }
then
ERROR: Ignored the following versions that require a different python version: 1.21.2 Requires-Python >=3.7,<3.11; 1.21.3 Requires-Python >=3.7,<3.11; 1.21.4 Requires-Python >=3.7,<3.11; 1.21.5 Requires-Python >=3.7,<3.11; 1.21.6 Requires-Python >=3.7,<3.11; 1.25.0 Requires-Python >=3.9; 1.25.0rc1 Requires-Python >=3.9; 1.25.1 Requires-Python >=3.9; 1.25.2 Requires-Python >=3.9; 1.26.0 Requires-Python <3.13,>=3.9; 1.26.0b1 Requires-Python <3.13,>=3.9; 1.26.0rc1 Requires-Python <3.13,>=3.9; 1.26.1 Requires-Python <3.13,>=3.9; 1.26.2 Requires-Python >=3.9; 1.26.3 Requires-Python >=3.9; 1.26.4 Requires-Python >=3.9; 1.7.0 Requires-Python >=3.9.0; 1.8.0 Requires-Python >=3.9.0; 2.0.0 Requires-Python >=3.9; 2.0.0b1 Requires-Python >=3.9; 2.0.0rc1 Requires-Python >=3.9; 2.0.0rc2 Requires-Python >=3.9
ERROR: Could not find a version that satisfies the requirement numpy==1.26.4 (from explanatory-model) (from versions: 1.3.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0, 1.6.1, 1.6.2, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.9.1, 1.9.2, 1.9.3, 1.10.0.post2, 1.10.1, 1.10.2, 1.10.4, 1.11.0, 1.11.1, 1.11.2, 1.11.3, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 1.13.3, 1.14.0, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.14.5, 1.14.6, 1.15.0, 1.15.1, 1.15.2, 1.15.3, 1.15.4, 1.16.0, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.16.6, 1.17.0, 1.17.1, 1.17.2, 1.17.3, 1.17.4, 1.17.5, 1.18.0, 1.18.1, 1.18.2, 1.18.3, 1.18.4, 1.18.5, 1.19.0, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.19.5, 1.20.0, 1.20.1, 1.20.2, 1.20.3, 1.21.0, 1.21.1, 1.22.0, 1.22.1, 1.22.2, 1.22.3, 1.22.4, 1.23.0rc1, 1.23.0rc2, 1.23.0rc3, 1.23.0, 1.23.1, 1.23.2, 1.23.3, 1.23.4, 1.23.5, 1.24.0rc1, 1.24.0rc2, 1.24.0, 1.24.1, 1.24.2, 1.24.3, 1.24.4)
ERROR: No matching distribution found for numpy==1.26.4
So problem with numpy, scikit-learn, shap transitives
Are these ML libraries packaged specially (I seem to remember that being required)?proud-planet-36170
07/12/2024, 5:17 PMproud-planet-36170
07/12/2024, 5:36 PM>=3.11,<4
and leaving the ranges open ended on the pants side. I left the interpreter_constraints
open so individual projects can pick their versions with pyproject.toml which seems to work (they're in different resolves). In general, I was trying to avoid constraining Python anywhere except the source module since we control that version (and let everything downstream resolve something that works)curved-television-6568
07/12/2024, 5:56 PMproud-planet-36170
07/15/2024, 12:39 PM