Skip to content

Commit

Permalink
Enable RUF100 to disallow unused noqa comments (#11219)
Browse files Browse the repository at this point in the history
Signed-off-by: harupy <17039389+harupy@users.noreply.github.com>
  • Loading branch information
harupy committed Feb 22, 2024
1 parent ee4f510 commit 191365d
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions mlflow/legacy_databricks_cli/configure/provider.py
Expand Up @@ -14,7 +14,7 @@
CONFIG_FILE_ENV_VAR = "DATABRICKS_CONFIG_FILE"
HOST = "host"
USERNAME = "username"
PASSWORD = "password" # NOQA
PASSWORD = "password"
TOKEN = "token"
REFRESH_TOKEN = "refresh_token"
INSECURE = "insecure"
Expand Down Expand Up @@ -299,7 +299,7 @@ def __init__(
refresh_token=None,
insecure=None,
jobs_api_version=None,
): # noqa
):
self.host = host
self.username = username
self.password = password
Expand Down
2 changes: 1 addition & 1 deletion mlflow/promptlab/__init__.py
Expand Up @@ -5,7 +5,7 @@
import yaml

from mlflow.exceptions import MlflowException
from mlflow.version import VERSION as __version__ # noqa: F401
from mlflow.version import VERSION as __version__


class _PromptlabModel:
Expand Down
2 changes: 1 addition & 1 deletion mlflow/utils/promptlab_utils.py
Expand Up @@ -10,7 +10,7 @@
from mlflow.entities.run_tag import RunTag
from mlflow.utils.file_utils import make_containing_dirs, write_to
from mlflow.utils.mlflow_tags import MLFLOW_LOGGED_ARTIFACTS, MLFLOW_RUN_SOURCE_TYPE
from mlflow.version import VERSION as __version__ # noqa: F401
from mlflow.version import VERSION as __version__


def create_eval_results_json(prompt_parameters, model_input, model_output_parameters, model_output):
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Expand Up @@ -51,6 +51,7 @@ select = [
"RET504", # unnecessary-assign
"RUF010", # explicit-f-string-type-conversion
"RUF013", # implicit-optional
"RUF100", # unused-noqa
"S307", # suspicious-eval-usage
"S324", # hashlib-insecure-hash-function
"SIM101", # duplicate-isinstance-call
Expand Down
2 changes: 1 addition & 1 deletion tests/pyfunc/docker/test_docker_flavors.py
Expand Up @@ -39,7 +39,7 @@
test_data,
)
from tests.prophet.test_prophet_model_export import prophet_model as prophet_raw_model # noqa: F401
from tests.pyfunc.docker.conftest import ( # noqa: F401
from tests.pyfunc.docker.conftest import (
MLFLOW_ROOT,
TEST_IMAGE_NAME,
docker_client,
Expand Down

0 comments on commit 191365d

Please sign in to comment.