-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
DOC: Command to run flake8 on diff? #16755
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
Comments
No it shouldn't. It calls
as pandas does is likely preferable and is cross-plaftorm unlike our script. Although it assumes that contributors have registered the upstream remote. One solution is also to recommend that when cloning same as done in pandas guide. +1 to change the docs. |
Registering the upstream remote is mentioned above:
And it's an important step if you want to open more than one PR (even for a single PR to solve eventual merge conflicts if the PR takes a while?). Waiting for another point of view and opening a PR if there is an agreement :) |
yeah we do have it in the docs, but not maybe in the most clear way. Open to suggestions. @rth we should also probably only run the "check unused improts" only on the changed files? Now the |
Running it on the diff wouldn't work, because some imports not touched by the diff get unused as a result of the diff. There is also mypy which would add 30s or so https://github.com/scikit-learn/scikit-learn/ . There are likely workarounds to make that CI faster. |
@johannfaouzi feel free to open a PR to improve it. |
then I guess I wouldn't even mind having the |
Note that makefile is not cross-plaform, so we shouldn't recommend using makefile in the contribution docs IMO. A lot of potential contributors are on windows. |
I agree we shouldn't recommend using it for windows users, but it doesn't mean we shouldn't have it for our own sake. We could have it but not recommend it. Although I kinda find it somewhat deeply problematic or ironic that for a lot of our contributing guides it's not what we actually do. I guess we don't have the bandwidth to do it, but it'd be nice to have a contributing guide for everybody, and one for people with a POSIX system. |
Describe the issue linked to the documentation
In the Contributing code section of the Contributing page, it is stated that:
I've never been able to run the
make flake8-diff
command on MacOS. Does it require to install the flake8-diff Python package? The documentation of flake8 states that one can use the following command:which works for me.
So I'm maybe asking a dumb question but what are the core devs using currently?
The text was updated successfully, but these errors were encountered: