https://pantsbuild.org/ logo
#development
Title
# development
w

wide-midnight-78598

09/04/2022, 6:13 PM
It's been a while since I did this, but should every item being emitted in a BuiltPackage also have a corresponding BuiltPackageArtifact?
I recall being told that the artifacts are strictly logging-centric, while the actual emitted material is the digest. This looks correct from what I've seen and the code, just want to confirm they're not used elsewhere
I only noted this because during my unit tests, my digests were correct, but all my assertions (based on artifacts) were failing 🤦‍♂️
f

fast-nail-55400

09/04/2022, 10:22 PM
BuiltPackageArtifact
is used by some goals to figure out what the relative path of an artifact in the
Digest
is. For example, when trying to run a pex, the relevant rule looks at the first entry in ``BuiltPackage.artifacts` to find the pex: https://github.com/pantsbuild/pants/blob/96c066c68d4b7de0d98a47d6c3ddf3a4e96bf4d1/src/python/pants/backend/python/goals/run_pex_binary.py#L32
👍 1