thankful-barista-85113
06/05/2019, 1:37 PMenough-analyst-54434
06/05/2019, 2:32 PM./pants --version
2. Does your python TLS test pass on all pythons on your PATH? which -a python{,2,3}
?
I'm guessing the answer to 2 is no and Pants is picking one of the old TLS pythons to run with, but hopefully you can help confirm.thankful-barista-85113
06/05/2019, 9:31 PMenough-analyst-54434
06/05/2019, 9:32 PMthankful-barista-85113
06/05/2019, 9:39 PMenough-analyst-54434
06/05/2019, 9:43 PM--version
.thankful-barista-85113
06/05/2019, 9:50 PMenough-analyst-54434
06/05/2019, 10:11 PM[python-setup]
# Avoid picking the Apple provided 2.7.10 interpreter that lacks new enough TLS support to interact with pypi.
interpreter_constraints: ["CPython>2.7.10"]
2. Constrain the search path to known good:
[python-setup]
# Ensure we just look at brew managed pythons which have new enough TLS support to interact with pypi.
interpreter_search_paths: ["/usr/local/bin"]
Of the two options I'd personally use the second. Its probably a safer bet that Brew managed pythons will be in better shape than Apple's given historical precedence.thankful-barista-85113
06/05/2019, 11:08 PMenough-analyst-54434
06/06/2019, 3:57 PMclean-all
you had to perform has since been fixed for 1.16+.
BUILD files, or rather the targets you define inside them, can be thought of as primarily demarcating logical units. For BUILD file targets for code, those units tend to map onto packages (or the equivalent structure in whatever underlying language the code is written in). A full software project generally composes many packages that depend on each other in various ways. If you model the software project to Pants with on BUILD file / 1 target, then Pants can only act on the whole project at once. If the project contains 10 production files and 5 test files for example, changing one production file and running ./pants --changed-parent=master test
will run all tests in all 5 test files. This is unfortunate, since it may be the case that only 1 test file depends on the 1 production file that was changed. Since you only let Pants know about the 1 large target, it can (currently) know no better. If, instead, you generally stick to 1 target per package (see 111 advice in the 'Target Granularity' section here: https://www.pantsbuild.org/build_files.html), then Pants can generally do less work.
All that said - in a small python project, 1 BUILD file is probably fine.