careful-address-89803
03/19/2022, 9:45 PMcareful-address-89803
03/19/2022, 9:51 PMwide-midnight-78598
03/19/2022, 11:52 PMPackage.swift
in swift or package.json
with Node stuff), should those be pulled in and used as a compilation target in lieu of bundling all sources?
I'm not sure if a Slack thread is even the best mechanism for this, as it almost feels like a Pants "evolution" type of question. I'm kinda caught between the two cases, since I don't like duplicating work, but I see the value in going all native Pants too, but, then I think about overreach - and it all spirals in my brain.
To clear up something/anything, what I'm trying to describe would be the difference between the following (noting that in both cases, the entire folder and subfolders would be pulled into a hermetic environ):
a) swift build
in a folder with a Package.swift
which then references the sources/tests
b) swiftc Sources/File1.swift Sources/File2.swift
in the "manual" version which would have a swift_sources
targetflat-zoo-31952
03/21/2022, 5:21 PMpolite-garden-50641
03/22/2022, 4:26 PMflat-zoo-31952
03/22/2022, 8:34 PMFile "/home/jreed/.cache/pants/named_caches/pex_root/venvs/s/ec6445a5/venv/lib64/python3.9/site-packages/_pytest/config/__init__.py", line 1579, in parse_warning_filter
category: Type[Warning] = warnings._getcategory(category_) # type: ignore[attr-defined]
File "/usr/lib64/python3.9/warnings.py", line 262, in _getcategory
raise _OptionError("invalid module name: %r" % (module,)) from None
warnings._OptionError: invalid module name: 'pymysql'
This is the first time i'm trying pytest with pants on this container, wonder if it's possible that something is interferingbitter-ability-32190
03/23/2022, 2:55 PM09:51:09.16 [ERROR] 1 Exception encountered:
AttributeError: 'builtins.Digest' object has no attribute 'digest'
FATAL: exception not rethrown
Aborted (core dumped)
You've upgraded to a version past https://github.com/pantsbuild/pants/pull/14865
Upgrading is easy, input
and output
are now Snapshot
in FmtResult
. The PR includes multiple examples of how to fix your formatter plugin.wide-midnight-78598
03/27/2022, 2:47 PMConfigFilesRequest
the canonical mechanism to grab a config file from a source root? Like a .clang-format
or .eslint.rc
or similar? If so, is there any formal documentation around it outside of source code?careful-address-89803
03/27/2022, 6:52 PME pants.engine.process.BinaryNotFoundError: Was not able to locate a Python interpreter to execute rule code.
E Please ensure that Python is available in one of the locations identified by `[python-bootstrap] search_path`, which currently expands to:
E []
I feel like I've overlooked something obvious, can someone help me out?ambitious-actor-36781
03/28/2022, 4:23 AMdeploy
this to 'the cloud' using a binary blob
5. Run a subset of tests against this code in 'the cloud'
6. also have the ability to deploy
this manually.
of cause, hope to leverage the whole Pants 'don't repeat work' feature to skip steps #1 to #4 if the code doesn't change.
I think I've got a grasp on doing the codegen.
But can't picture how to make the deploy the code as a dependency for tests work
And it's been nearly 6 months since I last used Pants.ambitious-actor-36781
03/30/2022, 10:10 AMpants package
also package the dependencies for a given field-set
• creating a 'manifest' for all targets who did something as a result of pants package
?
I've got pants package
generating the files I need to deploy "a widget" using some union rules (those are neat).
But those things also depend on other "widgets". And then I need to create a manifest file of all the widgets packaged.
Or am I going to have to create a custom goal command to do this?wide-midnight-78598
03/31/2022, 2:57 PMansible_sources
), or just use a files
or resources
field? While ansible execution files are largely yaml, there can be any extension of files which are used as resources or references. There is a semantic difference to be had, but not a practical or functional one I feel.
For example, I can do something like the following:
files(
name="myansiblesources",
sources=["**/*"],
)
or
ansible_sources(
name="myansiblesources",
sources=["**/*"],
)
ansible_deployment(
name="helloansible",
dependencies=[":myansiblesources"],
playbook="playbook.yml",
#inventory="", # TODO: Could this be setup like the Docker registries? in pants.toml
#tags="", # TODO: Might need a different name to not overlap
#timeout="",
)
Or, I could get even more specific by calling out the YAML files and then the supplementary files to help with formatting/linting I guess...
In summary, I'm not sure about the API 🙂
I'm going forward to get something functional, but in terms of something maximally usable/pragmatic + pants-likehappy-kitchen-89482
03/31/2022, 3:09 PMansible_sources
makes sense, it's where you might put any future extra fields you need that apply ansible-specific metadata to those sources (if such a thing becomes relevant)prehistoric-afternoon-67621
03/31/2022, 6:28 PM./pants fmt ::
to run black
over Jupyter Notebooks. Haven't dipped my toes into plugins just yet but feel this might be a decent starting point.wide-midnight-78598
04/04/2022, 2:08 PMmypy
types included with pantsbuild.pants
?
In a custom plugin, I'm running into a bunch of these... Maybe it's a Monday morning thing, but I thought I had fixed these before, but can't recall anymore:
pants-plugins/experimental/fooify/rules.py:4: error: Cannot find implementation or library stub for module named "experimental.fooify.subsystem"
pants-plugins/experimental/fooify/rules.py:5: error: Cannot find implementation or library stub for module named "experimental.fooify.target_types"
pants-plugins/experimental/fooify/rules.py:6: error: Cannot find implementation or library stub for module named "pants.core.goals.package"
pants-plugins/experimental/fooify/rules.py:7: error: Cannot find implementation or library stub for module named "pants.engine.fs"
pants-plugins/experimental/fooify/rules.py:8: error: Cannot find implementation or library stub for module named "pants.engine.rules"
pants-plugins/experimental/fooify/rules.py:9: error: Cannot find implementation or library stub for module named "pants.engine.target"
pants-plugins/experimental/fooify/rules.py:15: error: Cannot find implementation or library stub for module named "pants.engine.unions"
pants-plugins/experimental/fooify/rules.py:16: error: Cannot find implementation or library stub for module named "pants.util.logging"
big-crayon-94763
04/04/2022, 2:21 PMbitter-ability-32190
04/06/2022, 12:53 AMcurved-television-6568
04/07/2022, 9:34 AMpants_requirements()
target on the 2.11.0rc1 release.. 🧵curved-television-6568
04/07/2022, 11:31 AMbig-crayon-94763
04/07/2022, 2:03 PMambitious-actor-36781
04/07/2022, 9:13 PMValueError: empty pattern
When doing a Get(TransitiveTargets, TransitiveTargetsRequest(...)
bitter-ability-32190
04/08/2022, 1:21 PMhappy-kitchen-89482
04/08/2022, 3:03 PMbig-crayon-94763
04/08/2022, 3:56 PMbusy-vase-39202
04/08/2022, 4:33 PMambitious-actor-36781
04/11/2022, 12:35 AMbitter-ability-32190
04/11/2022, 5:38 PMbitter-ability-32190
04/12/2022, 3:09 PMDigestContents
. Python's zipflle
seemingly only works on files on disk. Anyone know how to either materialize the DigestContents
(into a tempdir or something) or parse the zipfile in-memory?bitter-ability-32190
04/12/2022, 3:40 PMpybind11
) and they get inferred, compiled, and included in the dependees' sandbox.
Hop in! 🧵big-crayon-94763
04/12/2022, 8:06 PMpants.base.build_root.BuildRoot.NotFoundError: No build root detected. Pants detects the build root by looking for at least one file from ['pants', 'BUILDROOT', 'BUILD_ROOT'] in the cwd and its ancestors. If you have none of these files, you can create an empty file in your build root.
From the code I would expect setup_tmpdir
to do this for me. I tried adding an empty file called BUILDROOT to the sources in the example but that didn't fix it either.
Is this a known issue? Or am I missing something? I am running 2.11.0.rc2