Hello :wave: , Something that’s been annoying me ...
# general
r
Hello 👋 , Something that’s been annoying me lately is that I have these deprecations that I would like to ignore:
Copy code
DEPRECATED: option 'lockfile' in scope 'pytest' is scheduled to be removed in version 2.18.0.dev0.
but the global configuration
ignore_warnings
is not working consistently. If I copy and paste the exact string (e.g.
DEPRECATED: option 'lockfile' in scope 'pytest' is scheduled to be removed in version 2.18.0.dev0.
) into this configuration, then this deprecation warning is not ignored when I run
pants
on the terminal of my x86 Macbook, but it does work when I run
pants
inside a docker container with the ubuntu OS. If I use a broad regex like in the documentation,
$regex$:DEPRECATED
, then it will not be ignored on neither my Macbook terminal, nor in the docker contianer. If I drop the
:
as mentioned here, then it will not be ignored on my Macbook terminal, but will be ignored in the docker container. In all cases I’m using v2.16.0. Overall, it looks like this configuration works when written correctly and running inside of a docker container. but not when I run on my Macbook’s terminal.
h
Huh, is the deprecation warning differently phrased in each platform?
I.e., is this a matching problem, or a bug
r
I’ve been toying with this around a bit now, and I think this may actually be some caching confusion? It looks like some of these deprecation warnings may get cached, but that cache is not invalidated when I change
ignore_warning
.
If I use
--no-local-cache
then the copy & paste list of warnings and
$regex$DEPRECATED
work on my Macbook terminal.
Eh, nevermind,
--no-local-cache
does not seem to be consistent either.
It looks like there are edge-cases where the
ignore_warnings
list is just ignored