high-energy-55500
02/09/2023, 9:42 PM⠓ 1462.31s Building main.pex with 21 requirements: arn<0.2.0,>=0.1.5, backoff<2.0.0,>=1.10.0, boltons<21.0.0,>=20.2.1, boto3<2.0.0,>=1.15, botocore<2.0.0,>=1.21.60, click<9.0.0,>=8.1.3, fsspec<2022.0.0,>=2021.4.0, orjson<3.7.0,>=3.6, pandas<2.0.0,>=1.5.3, protobuf<4,>=3.19
here’s the list of 3rd party dependencies
./pants dependencies --transitive src/my_script:main
//:poetry#arn
//:poetry#backoff
//:poetry#boltons
//:poetry#boto3
//:poetry#botocore
//:poetry#click
//:poetry#fsspec
//:poetry#orjson
//:poetry#pandas
//:poetry#protobuf
//:poetry#psycopg2-binary
//:poetry#pulumi
//:poetry#pulumi-aws
//:poetry#pydantic
//:poetry#ratelimit
//:poetry#redis-py-cluster
//:poetry#requests
//:poetry#s3fs
//:poetry#sentry-sdk
//:poetry#setuptools
//:poetry#tomli
//pyproject.toml:poetry
...
is there something i can/should do differently for pants to run this in a more reasonable timeframe?high-energy-55500
02/09/2023, 9:46 PM//:poetry#fsspec
and/or //:poetry#s3fs
which were added as dependencies of pandascool-yacht-37128
02/09/2023, 9:46 PMpandas
or the underlying dep numpy
. I find that cam take forever.
Is this the first time you have run it? It will cache these dependencies, and memoize previously run tasks that are relevanthigh-energy-55500
02/09/2023, 9:47 PMpoetry_requirements(
name="poetry",
overrides={
"pandas": {
"dependencies": ["//:poetry#fsspec", "//:poetry#s3fs"],
},
},
)
to our root BUILD filehigh-energy-55500
02/09/2023, 9:49 PMrefined-addition-53644
02/09/2023, 9:49 PMenough-analyst-54434
02/09/2023, 9:52 PMhigh-energy-55500
02/09/2023, 9:56 PMhigh-energy-55500
02/09/2023, 9:56 PMenough-analyst-54434
02/09/2023, 9:57 PMhigh-energy-55500
02/09/2023, 9:57 PMenough-analyst-54434
02/09/2023, 9:58 PMgentle-painting-24549
02/09/2023, 10:05 PMboto3
and s3fs
don’t play very nicely together for pip resolving - it downloads and tries every version of boto before finding one that works. Instead, specify s3fs
and aiobotocore[boto3]
and remove boto3
entirely
https://pantsbuild.slack.com/archives/C046T6T9U/p1668528451161329?thread_ts=1668522633.080329&cid=C046T6T9Uhigh-energy-55500
02/09/2023, 10:09 PMgentle-painting-24549
02/09/2023, 10:11 PMgentle-painting-24549
02/09/2023, 10:19 PMs3fs[boto3]
which uses aiobotocore[boto3]
under the hood and will easily resolve which version of boto3/botocore to use https://github.com/fsspec/s3fs/blob/56235491bdc3a89af22fe73a5440b90d1a65ce01/setup.py#L39high-energy-55500
02/10/2023, 1:15 AMhigh-energy-55500
02/10/2023, 1:16 AMhigh-energy-55500
02/10/2023, 1:16 AMenough-analyst-54434
02/10/2023, 2:59 PM[python]
pip_version = "22.3"
That tells Pex to use Pip 22.3 instead of its default 20.3.4. That Pip is 2 years newer and much faster for many lock resolves. You'll have to use Pants 2.16.x to get it though, latest of which is https://pypi.org/project/pantsbuild.pants/2.16.0.dev6/
Besides that, and tightening / adding interpreter_constraints
(Pants default is `>=3.7,<4`which is a huge range that can slow down lock solutions) the only real solution is to invest in https://github.com/pantsbuild/pex/issues/2044enough-analyst-54434
02/10/2023, 3:00 PMhappy to dig in to help figure out what’s going on if i canThank you. This figuring out has already been done and https://github.com/pantsbuild/pex/issues/2044 is the solution.