Skip to content

Commit

Permalink
[-next] october tools bump (#37878)
Browse files Browse the repository at this point in the history
* bump next

* update

* update

* space

* pylint changes

* black

* pylint eh

* pylint

* fix pylint

* black
  • Loading branch information
l0lawrence authored Oct 16, 2024
1 parent ae7bdfb commit 7577685
Show file tree
Hide file tree
Showing 10 changed files with 14 additions and 13 deletions.
8 changes: 4 additions & 4 deletions eng/tox/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ commands =

[testenv:pylint]
description=Lints a package with pylint (version {[testenv:pylint]pylint_version})
pylint_version=3.1.0
pylint_version=3.2.5
skipsdist = true
skip_install = true
usedevelop = false
Expand All @@ -101,7 +101,7 @@ commands =

[testenv:next-pylint]
description=Lints a package with pylint (version {[testenv:next-pylint]pylint_version})
pylint_version=3.2.5
pylint_version=3.2.7
skipsdist = true
skip_install = true
usedevelop = false
Expand Down Expand Up @@ -145,7 +145,7 @@ commands =

[testenv:mypy]
description=Typechecks a package with mypy (version {[testenv:mypy]mypy_version})
mypy_version=1.9.0
mypy_version=1.10.1
skipsdist = true
skip_install = true
usedevelop = true
Expand Down Expand Up @@ -197,7 +197,7 @@ commands =

[testenv:pyright]
description=Typechecks a package with pyright (version {[testenv:pyright]pyright_version})
pyright_version=1.1.359
pyright_version=1.1.371
skipsdist = true
skip_install = true
usedevelop = true
Expand Down
2 changes: 1 addition & 1 deletion pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ load-plugins=pylint_guidelines_checker
# Let's black deal with bad-continuation

# Added disables from super-with-arguments
disable=useless-object-inheritance,missing-docstring,locally-disabled,fixme,cyclic-import,too-many-arguments,invalid-name,duplicate-code,too-few-public-methods,consider-using-f-string,super-with-arguments,redefined-builtin,import-outside-toplevel,client-suffix-needed,unnecessary-dunder-call,unnecessary-ellipsis,client-paging-methods-use-list,docstring-keyword-should-match-keyword-only,docstring-type-do-not-use-class,consider-using-max-builtin,too-many-lines
disable=useless-object-inheritance,missing-docstring,locally-disabled,fixme,cyclic-import,too-many-arguments,invalid-name,duplicate-code,too-few-public-methods,consider-using-f-string,super-with-arguments,redefined-builtin,import-outside-toplevel,client-suffix-needed,unnecessary-dunder-call,unnecessary-ellipsis,client-paging-methods-use-list,docstring-keyword-should-match-keyword-only,docstring-type-do-not-use-class,consider-using-max-builtin,too-many-lines,possibly-used-before-assignment

[FORMAT]
max-line-length=120
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -219,4 +219,6 @@ def send(self, request: Union[HttpRequest, LegacyHttpRequest], **kwargs) -> Http
except httpx.RequestError as err:
raise ServiceRequestError(err, error=err) from err

return HttpXTransportResponse(request, response, stream_contextmanager=stream_ctx)
return HttpXTransportResponse(
request, response, stream_contextmanager=stream_ctx # pylint: disable=used-before-assignment
)
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,6 @@ def _incoming_end(self, channel: int, frame: Tuple[Any, ...]) -> None:
"END frame received on invalid channel. Closing connection.",
extra=self._network_trace_params
)
return

def _process_incoming_frame(self, channel: int, frame: Optional[Union[bytes, Tuple[Any,...]]]) -> bool: # pylint:disable=too-many-return-statements
"""Process an incoming frame, either directly or by passing to the necessary Session.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ def _try_build_local_code(self) -> Iterable[Code]:

tmp_code_dir: Path
# origin code value of internal component will never be None. check _get_origin_code_value for details
with self._generate_additional_includes_obj().merge_local_code_and_additional_includes() as tmp_code_dir:
with self._generate_additional_includes_obj().merge_local_code_and_additional_includes() as tmp_code_dir: # pylint:disable=contextmanager-generator-missing-cleanup
# use absolute path in case temp folder & work dir are in different drive
tmp_code_dir = tmp_code_dir.absolute()

Expand Down
2 changes: 1 addition & 1 deletion sdk/ml/azure-ai-ml/azure/ai/ml/_telemetry/activity.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def error_preprocess(activityLogger, exception):


@contextlib.contextmanager
def log_activity(
def log_activity( # pylint:disable=useless-return
logger,
activity_name,
activity_type=ActivityType.INTERNALCALL,
Expand Down
2 changes: 1 addition & 1 deletion sdk/ml/azure-ai-ml/azure/ai/ml/entities/_component/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ def _build_code(self) -> Generator:
yield Code(path=origin_code_value)
elif code_type in [CodeType.LOCAL, CodeType.NONE]:
code: Any
with self._try_build_local_code() as code:
with self._try_build_local_code() as code: # pylint:disable=contextmanager-generator-missing-cleanup
yield code
else:
# arm id, None and unknown need no extra resolution
Expand Down
2 changes: 1 addition & 1 deletion sdk/ml/azure-ai-ml/azure/ai/ml/entities/_component/flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -530,7 +530,7 @@ def _fill_back_code_value(self, value: str) -> None:

@contextlib.contextmanager
def _try_build_local_code(self) -> Generator:
with super()._try_build_local_code() as code:
with super()._try_build_local_code() as code: # pylint:disable=contextmanager-generator-missing-cleanup
if not code or not code.path:
yield code
return
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
}


class ParameterizedSweep:
class ParameterizedSweep: # pylint:disable=too-many-instance-attributes
"""Shared logic for standalone and pipeline sweep job."""

def __init__(
Expand Down Expand Up @@ -205,6 +205,7 @@ def set_limits(
:keyword trial_timeout: timeout in seconds for each trial
:paramtype trial_timeout: int
"""
# pylint:disable=attribute-defined-outside-init
if self._limits is None:
self._limits = SweepJobLimits(
max_concurrent_trials=max_concurrent_trials,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,6 @@ def _incoming_end(self, channel: int, frame: Tuple[Any, ...]) -> None:
"END frame received on invalid channel. Closing connection.",
extra=self._network_trace_params
)
return

def _process_incoming_frame(self, channel: int, frame: Optional[Union[bytes, Tuple[Any,...]]]) -> bool: # pylint:disable=too-many-return-statements
"""Process an incoming frame, either directly or by passing to the necessary Session.
Expand Down

0 comments on commit 7577685

Please sign in to comment.