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

hundreds-father-404

04/06/2021, 6:42 AM
--ignore-pants-warnings
expects regex patterns, which can result in surprising behavior like
The option
[isort].config
is not configured
not actually ignoring that warning due to
[]
not being escaped. Are folks using the regex feature? I'd like to simplify with a new option
--ignore-warnings
that is normal strings, and deprecate the old one.
The Python TOML library also doesn't seem to like some of the escaping. You have to use a literal string with
'foo'
instead of
"foo"
, but then we get
[WARN] <string>:1: DeprecationWarning: invalid escape sequence \[
with
\[foo\]
The library hasn't been updated since October 2020, and tomlkit isn't great either, so I don't think us fixing upstream is super realistic Instead, we can circumvent by not getting fancy with regex
Oh, we could maybe have a way to indicate it's a regex? Like
prefix the string with 'regexp: '