Just had a very tedious incident caused by a missi...
# general
a
Just had a very tedious incident caused by a missing file in a pex_binary. There was a warning, can't find an owner for an import, but the package built and deployed. Am I missing a way to make that fail the build? ignore_errors isn't set to True anywhere that I can see.
c
❤️ 1
a
Thanks!
c
we think error is the sane thing to do, but it’s warn due to being backwards compatible for when the option didn’t exist, IIRC
a
I googled around, but it was sort of hard to find the exact place in the docs where that info is recorded
1
c
might be a good time to revisit that default value.
sorry you had to learn this the hard way
a
No bother! I was just confused about whether I'd done this to myself
I low key love Pants, so my tolerance for the unexpected is high
❤️ 6
h
We could deprecate the default - we can detect if you're relying on it and warn that you must set it explicitly to continue to get that behavior
It's probably time
a
As in flip the default and provide a useful error if there's no value set?
That sounds like a PR within my limited capabilities.
❤️ 3
b
Cool! We love it having new contributors. ❤️
h
Well, this would be a two-parter. Part one - use our deprecation mechanism to warn you if you're relying on the default. The warning would state that in, say, 2.18.0.dev0 the default will switch. Then, after we cut the 2.17.x release branch, a second PR will change the default and remove the warning.
For the first part, you can use is_default() to check if the value is being provided by the default (it's not enough to check the value, because that could have been explicitly set to the same as the default), and the warning should state that you must set it explicitly if you want to continue to use that value.
We'd love a PR!
a
Might do this as a warmup before I try and tackle excluding transitive deps.
👍 1
🙏 1
b
Have fun! Reach out if you run into trouble. Maintainers are happy to help.