Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed python2 compatibility #381

Merged
merged 1 commit into from
Dec 8, 2023
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
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
* Fixed python2 compatibility

## 2.15.0 ##
* Fixed python2 compatibility

Expand Down
3 changes: 0 additions & 3 deletions ydb/_errors.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from dataclasses import dataclass

from . import issues

_errors_retriable_fast_backoff_types = [
Expand Down Expand Up @@ -56,7 +54,6 @@ def check_retriable_error(err, retry_settings, attempt):
return ErrorRetryInfo(False, None)


@dataclass
class ErrorRetryInfo:
def __init__(self, is_retriable, sleep_timeout_seconds=None):
self.is_retriable = is_retriable
Expand Down
4 changes: 0 additions & 4 deletions ydb/scheme.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ class SchemeEntryType(enum.IntEnum):
REPLICATION = 16
TOPIC = 17

@classmethod
def _missing_(cls, value):
return cls.TYPE_UNSPECIFIED

@staticmethod
def is_table(entry):
"""
Expand Down
8 changes: 0 additions & 8 deletions ydb/scheme_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,6 @@ def test_wrap_scheme_entry():
assert (
_wrap_scheme_entry(ydb_scheme.Entry()).type is SchemeEntryType.TYPE_UNSPECIFIED
)
assert (
_wrap_scheme_entry(ydb_scheme.Entry(type=10)).type
is SchemeEntryType.TYPE_UNSPECIFIED
)
assert (
_wrap_scheme_entry(ydb_scheme.Entry(type=1001)).type
is SchemeEntryType.TYPE_UNSPECIFIED
)


def test_wrap_list_directory_response():
Expand Down
Loading