Cleanup quality (#21493)

* Remove mentions of flake8/isort

* Clean up inits

* Deall with all other inits

* Last special rule for dummy files
This commit is contained in:
Sylvain Gugger
2023-02-07 12:27:31 -05:00
committed by GitHub
parent 571fa585b6
commit 67d074874d
220 changed files with 26 additions and 832 deletions

View File

@@ -43,7 +43,7 @@ open-source contribution to Transformers. Along the way, you will:
- understand the design principles of one of the most popular NLP
libraries
- learn how to do efficiently test large NLP models
- learn how to integrate Python utilities like `black`, `isort`,
- learn how to integrate Python utilities like `black`, `ruff`,
`make fix-copies` into a library to always ensure clean and readable
code

View File

@@ -1,7 +1,3 @@
# flake8: noqa
# There's no way to ignore "F401 '...' imported but unused" warnings in this
# module, but to preserve other warnings. So, don't check this module at all.
# Copyright 2020 The HuggingFace Team. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
@@ -17,7 +13,6 @@
# limitations under the License.
from typing import TYPE_CHECKING
# rely on isort to merge the imports
from ...utils import _LazyModule, OptionalDependencyNotAvailable, is_tokenizers_available

View File

@@ -25,7 +25,7 @@ open-source contribution to Transformers. Along the way, you will:
- understand the design principles of one of the most popular NLP
libraries
- learn how to do efficiently test large NLP models
- learn how to integrate Python utilities like `black`, `isort`,
- learn how to integrate Python utilities like `black`, `ruff`,
`make fix-copies` into a library to always ensure clean and readable
code