Skip to content
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

Docformatter inconsistency #598

Closed
pedropgusmao opened this issue Jan 18, 2021 · 1 comment
Closed

Docformatter inconsistency #598

pedropgusmao opened this issue Jan 18, 2021 · 1 comment

Comments

@pedropgusmao
Copy link
Contributor

There seems to be a conflict between docformatter and linter.s

When running dev/fnt.sh with the following code snipped the linter will complain that the code has an extra whitespace before ':'.
However, if the whitespace is manually removed from the source-code, then it is put back by the document formatter.

266     list_samples_per_class: List[List[np.ndarray]] = [
267         x_l[boundaries[idx] : boundaries[idx + 1]] for idx in range(num_classes)
268     ]

Running dev/fnt.sh:

Format code and run all test scripts
Fixing /home/pedro/repos/flower_2/src/py/flwr_example/pytorch_save_weights/client.py
Skipped 1 files
=== test.sh ===
- clang-format: done
Skipped 1 files
- isort:  done
All done! ✨ 🍰 ✨
58 files would be left unchanged.
- black:  done
- docformatter:  done
Success: no issues found in 154 source files
- mypy:   done

--------------------------------------------------------------------
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)

- pylint: done
src/py/flwr/dataset/utils/common.py:267:28: E203 whitespace before ':'
@pedropgusmao
Copy link
Contributor Author

Related: psf/black#279

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant