helpful-lunch-92084
01/28/2021, 5:17 PM--test-debug
then it completes. albeit with the test failures
3. When I get the tests to pass running w/out --test-debug
worksearly-toothbrush-63898
01/28/2021, 5:18 PMhelpful-lunch-92084
01/28/2021, 5:18 PMplain-librarian-97976
01/29/2021, 10:22 AMechoing-manchester-70122
01/29/2021, 11:13 PMException message: Package SourcePackage('file:///mnt/workspace/.pants.d/python-setup/resolved_requirements/CPython-2.7.17/watchdog-1.0.2.tar.gz') is not translateable by ChainedTranslator(WheelTranslator, EggTranslator, SourceTranslator)
echoing-manchester-70122
01/29/2021, 11:13 PMechoing-manchester-70122
01/29/2021, 11:18 PMclean-all
target)helpful-lunch-92084
01/30/2021, 6:51 PMhelpful-lunch-92084
02/01/2021, 5:28 PMuser
02/01/2021, 7:54 PMuser
02/01/2021, 11:01 PMhigh-egg-2153
02/02/2021, 2:24 PM*python_library*(
name = "lib",
)
*resources*(
name = "translations",
sources = ["translations/**"],
)
*pex_binary*(
name = "bin",
entry_point = "<http://dash_campaign_status_report.app|dash_campaign_status_report.app>",
dependencies = [
":lib",
":translations",
"lib_dash:lib",
"lib_dash_security:lib",
]
)
If I run dependencies on the bin target I get:
dash_campaign_status_report/app.py:lib
dash_campaign_status_report/translations/en/LC_MESSAGES/messages.mo:../../../translations
dash_campaign_status_report/translations/en/LC_MESSAGES/messages.po:../../../translations
dash_campaign_status_report/translations/fr/LC_MESSAGES/messages.mo:../../../translations
dash_campaign_status_report/translations/fr/LC_MESSAGES/messages.po:../../../translations
dash_campaign_status_report/translations/messages.pot:../translation
happy-kitchen-89482
02/03/2021, 5:46 AM./pants init
goal, that generates BUILD file targets for files that don't belong to any target: https://github.com/pantsbuild/pants/pull/11517brash-baker-91190
02/03/2021, 6:26 PMpython_source_root
to the protobuf_library
target (https://www.pantsbuild.org/docs/protobuf#protobuf-and-source-roots). The documentation suggests that this will put the generated code in the specified source root; however, in practice it looks like it just creates that directory structure under dist/codegen
.
Additionally, dependency resolution for code that's using the generated *_pb2
modules doesn't appear to be working (as judged by the output of ./pants dependencies path/to/the/file/that/uses/protobufs.py
Another wrinkle is that we'd like to create a Python distribution containing just the generated protobuf code, but I'm not even sure how to express that in Pants notation... particularly with the need to have __init__.py
files created as well.
There seem to be a lot of moving parts here, and I'm not sure if there's a bug or (more likely) some incomplete understanding on my part, possibly coupled with some inconsistent file layout choices in this repository.
That's a lot of information, and I can provide more as needed... I just wanted to lay out my perception of the high-level issues as a way to hopefully start a discussion. Thanks in advance for any advice folks may have.brash-baker-91190
02/03/2021, 10:27 PMpytest.ini
when running ./pants test ::
? Or, failing that, a way to specify custom markers to the pytest run?happy-kitchen-89482
02/03/2021, 11:46 PMinit
, generates BUILD file boilerplate for you, and in the future may also suggest some pants.toml config, based on heuristics. @witty-crayon-22786 mentioned that init
makes it sound like you'd only run this once, when you first integrate Pants, but in reality it's designed to be run in ongoing fashion, to generate BUILD file boilerplate for new and changed code as needed. So the bikeshed is, what is a good name for this goal? You'd run it as ./pants <name>
with no other arguments.happy-kitchen-89482
02/03/2021, 11:46 PM./pants init
is what it would currently behappy-kitchen-89482
02/03/2021, 11:46 PMhappy-kitchen-89482
02/03/2021, 11:46 PM./pants configure
happy-kitchen-89482
02/03/2021, 11:46 PM./pants buildgen
average-vr-56795
02/03/2021, 11:48 PM./pants gen
?average-vr-56795
02/03/2021, 11:49 PM./pants setup
?helpful-lunch-92084
02/03/2021, 11:54 PMautopants
but yah i think i mapped it to the buildgen goal namehundreds-breakfast-49010
02/03/2021, 11:55 PM./pants boilerplate
?average-vr-56795
02/04/2021, 12:04 AM./pants wizard
?loud-stone-83419
02/04/2021, 12:24 AM./pants t-shirt
<- now fully clothedwitty-crayon-22786
02/04/2021, 12:31 AM./pants apply
witty-crayon-22786
02/04/2021, 12:33 AMloud-stone-83419
02/04/2021, 12:34 AM./pants fix
<- inspired by the scalafix projecthappy-kitchen-89482
02/04/2021, 1:03 AM./pants belt
, ./pants suspenders
, ./pants fly
...