Skip to content

Commit

Permalink
chore(pylint): Reenable too-many-locals check (#16268)
Browse files Browse the repository at this point in the history
Co-authored-by: John Bodley <john.bodley@airbnb.com>
  • Loading branch information
john-bodley and John Bodley authored Aug 16, 2021
1 parent 7b72443 commit b5c7ed9
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 7 deletions.
1 change: 0 additions & 1 deletion .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ disable=
import-outside-toplevel,
raise-missing-from,
too-few-public-methods,
too-many-locals,
duplicate-code,

[REPORTS]
Expand Down
2 changes: 1 addition & 1 deletion superset/common/query_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def left_join_on_dttm(
df.reset_index(level=0, inplace=True)
return df

def processing_time_offsets(
def processing_time_offsets( # pylint: disable=too-many-locals
self, df: pd.DataFrame, query_object: QueryObject,
) -> CachedTimeOffset:
# ensure query_object is immutable
Expand Down
2 changes: 1 addition & 1 deletion superset/dashboards/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,7 @@ def bulk_delete(self, **kwargs: Any) -> Response:
@event_logger.log_this_with_context(
action=lambda self, *args, **kwargs: f"{self.__class__.__name__}.export",
log_to_statsd=False,
)
) # pylint: disable=too-many-locals
def export(self, **kwargs: Any) -> Response:
"""Export dashboards
---
Expand Down
2 changes: 1 addition & 1 deletion superset/dashboards/commands/importers/v1/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def build_uuid_to_id_map(position: Dict[str, Any]) -> Dict[str, int]:
}


def update_id_refs(
def update_id_refs( # pylint: disable=too-many-locals
config: Dict[str, Any],
chart_ids: Dict[str, int],
dataset_info: Dict[str, Dict[str, Any]],
Expand Down
2 changes: 1 addition & 1 deletion superset/datasets/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ def delete(self, pk: int) -> Response:
@event_logger.log_this_with_context(
action=lambda self, *args, **kwargs: f"{self.__class__.__name__}.export",
log_to_statsd=False,
)
) # pylint: disable=too-many-locals
def export(self, **kwargs: Any) -> Response:
"""Export datasets
---
Expand Down
2 changes: 1 addition & 1 deletion superset/examples/multiformat_time_series.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
)


def load_multiformat_time_series(
def load_multiformat_time_series( # pylint: disable=too-many-locals
only_metadata: bool = False, force: bool = False
) -> None:
"""Loading time series data from a zip file in the repo"""
Expand Down
2 changes: 1 addition & 1 deletion superset/utils/pandas_postprocessing.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ def _append_columns(


@validate_column_args("index", "columns")
def pivot( # pylint: disable=too-many-arguments
def pivot( # pylint: disable=too-many-arguments,too-many-locals
df: DataFrame,
index: List[str],
aggregates: Dict[str, Dict[str, Any]],
Expand Down
1 change: 1 addition & 0 deletions superset/utils/profiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from werkzeug.wrappers import Request, Response

try:
# pylint: disable=import-error
from pyinstrument import Profiler
except ModuleNotFoundError:
Profiler = None
Expand Down

0 comments on commit b5c7ed9

Please sign in to comment.