Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ persistent=yes
# Specify a configuration file.
#rcfile=

# When enabled, pylint would attempt to guess common misconfiguration and emit
# user-friendly hints instead of false-positive error messages.
suggestion-mode=yes

# Allow loading of arbitrary C extensions. Extensions are imported into the
# active Python interpreter and may run arbitrary code.
unsafe-load-any-extension=no
Expand Down
2 changes: 1 addition & 1 deletion dev-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
pylint==3.3.4
pylint==4.0.9
griffe==1.15.0
httpretty==1.1.4
inline-snapshot==0.34.2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from collections.abc import Mapping
from dataclasses import MISSING, fields, is_dataclass
from enum import Enum
from types import UnionType
from types import NoneType, UnionType
from typing import Any, TypeVar, Union, get_args, get_origin, get_type_hints

_T = TypeVar("_T")
Expand All @@ -27,7 +27,7 @@ def _unwrap_optional(type_hint: Any) -> Any:
"""
origin = get_origin(type_hint)
if origin is UnionType or origin is Union:
non_none = [t for t in get_args(type_hint) if t is not type(None)]
non_none = [t for t in get_args(type_hint) if t is not NoneType]
if len(non_none) == 1:
return non_none[0]
return type_hint
Expand Down
4 changes: 0 additions & 4 deletions opentelemetry-semantic-conventions/.pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ persistent=yes
# Specify a configuration file.
#rcfile=

# When enabled, pylint would attempt to guess common misconfiguration and emit
# user-friendly hints instead of false-positive error messages.
suggestion-mode=yes

# Allow loading of arbitrary C extensions. Extensions are imported into the
# active Python interpreter and may run arbitrary code.
unsafe-load-any-extension=no
Expand Down
Loading