chilly-tailor-75063
11/02/2022, 7:32 PM[tool.pylint]
rcfile = ?
brash-student-40401
11/02/2022, 9:29 PMrequirements.txt
and regenerating the lockfile, but it seems to put things in alphabetical order. I've got them ordered "correctly" in my dependencies
too. How can I make sure that Numpy is installing first?sparse-lifeguard-95737
11/03/2022, 12:46 AM__defaults__
apply before or after target generation? i.e. can I get away with only listing defaults for python_source
and python_test
, or do I need to use (python_sources, python_source)
and (python_tests, python_test)
to be sure I cover everything?bitter-ability-32190
11/03/2022, 1:59 PMBUILD
files that aren't relevant for a command? Or to ignore errors when parsing?cold-vr-15232
11/03/2022, 2:08 PMfuture-oxygen-10553
11/03/2022, 3:34 PMbitter-ability-32190
11/03/2022, 5:56 PMERROR: Package 'pkglocker' requires a different Python: 3.9.7 not in '==3.8.*'
Coming from:
python_sources()
pex_binary(
name="pkglocker-binary",
entry_point="pkglocker.py",
layout="packed",
)
python_distribution(
name="pkglocker-dist",
dependencies=["./pkglocker.py"],
provides=python_artifact(name="pkglocker", version="0.0.1"),
)
pyoxidizer_binary(
name="pkglocker-pyox",
dependencies=[":pkglocker-dist"],
entry_point="pkglocker.py",
)
pants.toml
has:
[python]
interpreter_constraints = ["CPython==3.8.*"]
But Pants itself is using 3.9
I think.
So I'm guessing we are running something in Pants' env instead of a materialized one? Or I'm missing something 🙂freezing-lamp-12123
11/04/2022, 7:55 AM--env
on a subsystem that there’s some hidden default which is all environment variables ? — if i add with a string default, the current value seems to be the full dump of my environment 😂 …
PANTS_MY_SUBSYSTEM_ENV
env
default: my-default
current value: namespace(__CFBundleI ..... continues with a full dump of my environment)
curved-manchester-66006
11/04/2022, 3:00 PMrequirements.txt
file. I think I can gather my python files together by having pants make a tarball or sdist. But I'm not sure how to generate a requirements.txt
style file to go along with them. (I know about /pants dependencies
but now how to make it output in requirements.txt style nor include it with the tarball/sdist)chilly-tailor-75063
11/04/2022, 3:11 PM[tool.poetry.group.dev.dependencies]
because Pants will pull them in as necessary. Is this correct?bitter-ability-32190
11/04/2022, 4:20 PMpex_binary
whose resolve
is set to B
, but none of my `python_source`s support resolve B
. Surprisingly it builds and just fails to find the entry_point
.
Seems like a very weird behavior 😕incalculable-hydrogen-44003
11/04/2022, 4:28 PMchilly-tailor-75063
11/04/2022, 4:58 PMBUILD
files scattered about my project be included in my git repository?chilly-tailor-75063
11/04/2022, 5:09 PM./pants fmt ::
Bootstrapping Pants using /opt/homebrew/bin/python3.8
Installing pantsbuild.pants==2.14.0 into a virtual environment at /Users/dfarrell/.cache/pants/setup/bootstrap-Darwin-arm64/2.14.0_py38
ERROR: Could not find a version that satisfies the requirement pantsbuild.pants==2.14.0 (from versions: 0.0.17, 0.0.18, 0.0.20, 0.0.21, 0.0.22, 0.0.23, 0.0.24, 0.0.25, 0.0.26, 0.0.27, 0.0.28, 0.0.29, 0.0.30, 0.0.31, 0.0.32, 0.0.33, 0.0.34, 0.0.35, 0.0.36, 0.0.37, 0.0.38, 0.0.39, 0.0.40, 0.0.41, 0.0.42, 0.0.43, 0.0.44, 0.0.45, 0.0.46, 0.0.47, 0.0.48, 0.0.49, 0.0.50, 0.0.51, 0.0.52, 0.0.53, 0.0.54, 0.0.55, 0.0.56, 0.0.57, 0.0.58, 0.0.59, 0.0.60, 0.0.61, 0.0.62, 0.0.63, 0.0.64, 0.0.65, 0.0.66, 0.0.67, 0.0.68, 0.0.69, 0.0.70, 0.0.71, 0.0.72, 0.0.73, 0.0.74, 0.0.75, 0.0.76, 0.0.77, 0.0.79, 0.0.80, 0.0.81, 0.0.82, 1.0.0, 1.0.1, 1.1.0, 1.2.0, 1.2.1, 1.3.0, 1.4.0, 1.5.0, 1.6.0, 1.7.0)
ERROR: No matching distribution found for pantsbuild.pants==2.14.0
Is 3.10.8 not supported, or am I missing something?chilly-tailor-75063
11/04/2022, 8:34 PMNo name 'BaseModel' in module 'pydantic' (no-name-in-module)
from pylint in my project, but I’m having no luck. No change to my pyproject.toml or pants.toml or .pylintrc file seems to make any difference.
Got any suggestions where to look? To be honest I’m not sure pylint is using my .pylintrc file… 😞fierce-crowd-57292
11/05/2022, 6:35 AM[build-system]
requires = ["setuptools", "setuptools-scm"]
build-backend = "setuptools.build_meta"
[project]
name = "tool"
readme = "README.md"
requires-python = ">=3.7"
dynamic = ["version"]
dependencies = [
"boto3",
"requests",
]
...
fierce-crowd-57292
11/05/2022, 8:35 AM├── README.md
├── pants
├── pants.toml
└── projectdir
├── BUILD
├── requirements.txt
└── tool
├── BUILD
├── __main__.py
└── backend.py
projectdir/requirements.txt
specify dependenceis, used in projectdir/tool/backend.py
The projectbuild/BUILD
has
python_requirements(
name="reqs",
)
That should parse requireements.txt.
But if query the dependencies from projectdir/tool/backend.py
it’s nothing there../pants dependencies --transitive projectdir/tool/backend.py
I’ve create very simple repo that demonstrates it.
https://github.com/golovasteek/pants_sample_project
How do I ensure that dependencies in the projectdir/tool
are properly inferred with respect to projectdir/requirements.txt
?high-yak-85899
11/05/2022, 9:24 PM# pants: no-infer-dep
directive. Is there something like # pants: allow-missing-dep
?careful-address-89803
11/06/2022, 4:34 AM.run_goal_rule
?delightful-napkin-51999
11/06/2022, 8:13 AMshy-advantage-49800
11/06/2022, 12:06 PMpyproject.toml
with pants to build wheels? - I want to see an example, not the docs 👀chilly-tailor-75063
11/06/2022, 4:34 PMshy-advantage-49800
11/06/2022, 4:54 PMuvicorn_trailers
with main.py
and __init__.py
folder appear on the wheel?shy-advantage-49800
11/06/2022, 5:06 PMbored-energy-25252
11/07/2022, 7:25 AMrhythmic-morning-87313
11/07/2022, 7:33 AMrequirements.txt
.... What is the proper way to fix these?curved-television-6568
11/07/2022, 3:57 PMcareful-address-89803
11/07/2022, 4:05 PMscalene your_prog.py
. I tried creating a new pex_binary and setting script
or entry_point
to "scalene", but I can't seem to pass arguments to it?shy-advantage-49800
11/07/2022, 4:39 PMrefined-gigabyte-6122
11/07/2022, 5:44 PMpython_requirement
documentation, but don’t see any obvious way to influence the build for an individual dependency (or all dependencies, which would also work).