<#20947 Values from `__defaults__` are not treated...
# github-notifications
c
#20947 Values from `__defaults__` are not treated the same as builtin field defaults. Issue created by kaos
There is one downside with the current implementation for this, and that is that Pants will now treat the "default" glob for the
sources
field as "user provided", and as such err out for any globs that don't match any files.
This is a pain if used in
__defaults__
to adjust the default sources glob for some target (say I want to have all
factories.py
files owned by
python_test_utils
rather than
python_sources
by default, but that file is not going to exist for all targets but unmatched_build_file_globs is a global option only..)
Originally posted by @kaos in #17614 (comment) * * * The context here is, that source globs provided as field values will err if they match no files, where as source globs from the field default value does not. However, the values provided by
__defaults__
is treated the same as if they were provided directly on the target as a regular value. pantsbuild/pants