New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add alias clarification to deprecation warning #7829
Conversation
Hi @mmarinez, Can you clarify why the clarification is needed? |
Can you elaborate on why this is needed? I don't see how it'd be relevant for users how the private implementation of the underlying function is called. Also FWIW the tests are failing, but I don't see why this would be needed at all. |
Related to #7815? |
@mmarinez Thanks for the clarification! In the future, please clarify the context of a PR as part of the PR message when you open it - you can even use something like "Closes #7815" so that the issue is closed automatically when the PR is merged. This makes it easier for people to keep track of things, as there are a lot of stuff going on in parallel in a project like this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't really understand #7815 (though I only took a quick look), so I'll let someone else take a closer look at this. However, note that test_fillfuncargs_is_deprecated
in testing/deprecated_test.py
will need adjustments to fix the tests.
Got it, thanks for letting me know, I'll be checking that out. |
LGTM once CI passes, thanks @mmarinez. |
0a00349
to
7955b6f
Compare
7955b6f
to
5381e1c
Compare
Hi @mmarinez, Thanks for working on this. I took the liberty of updating the PR a bit:
With this change: import pytest
def test1():
pytest._fillfuncargs(mock.Mock()) Produces this warning:
Which I think is better. 👍 @bluetech can you please take another look? @mmarinez for the record, the test was failling previously because |
@nicoddemus The idea is to eventually remove the |
I understand, but let me make a few points why I think the current PR is better, but if you still prefer to keep
If we had a better alternative to point to (specially a new, public usage), I would agree 100% with you, but pointing to WDYT? |
Hey, it's ok thank. I was actually struggling a bit trying to run the tests locally and not push every change trying to figure why were the tests failing |
Right, although there are plugins which use it.
Right.
But that's fine? I mean this is clearly entirely private, so if someone is using that they can't expect it to be stable. A better alternative is to use
I agree |
Hehehe I meant the latter. No worries, I will re-add the deprecation warning and improve the message. 👍 |
Done! 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mmarinez @nicoddemus.
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
Backport: #7867 |
@Zac-HD Yes, this is related to the issue #7815. I could come up with a better format for the warning if it is needed.