From c9978798584cd3751458c21f230460adb959d23f Mon Sep 17 00:00:00 2001 From: megahomyak Date: Wed, 9 Mar 2022 14:27:52 +0500 Subject: [PATCH 1/3] Infinite request retries are working properly now! --- netschoolapi/async_client_wrapper.py | 6 +-- setup.py | 60 ++++++++++++++-------------- 2 files changed, 33 insertions(+), 33 deletions(-) diff --git a/netschoolapi/async_client_wrapper.py b/netschoolapi/async_client_wrapper.py index 4beae27..504939f 100644 --- a/netschoolapi/async_client_wrapper.py +++ b/netschoolapi/async_client_wrapper.py @@ -22,9 +22,9 @@ def __init__( self, async_client: httpx.AsyncClient, default_requests_timeout: int = None): self.client = async_client - self._default_requests_timeout = ( - default_requests_timeout or DEFAULT_REQUESTS_TIMEOUT - ) + if default_requests_timeout is None: + default_requests_timeout = DEFAULT_REQUESTS_TIMEOUT + self._default_requests_timeout = default_requests_timeout def make_requester(self, requests_timeout: Optional[int]) -> Requester: # noinspection PyTypeChecker diff --git a/setup.py b/setup.py index 5eeffe5..318d8cf 100644 --- a/setup.py +++ b/setup.py @@ -1,30 +1,30 @@ -from setuptools import setup - - -with open('README.md') as readme: - long_description = readme.read() - - -setup( - name='netschoolapi', - version='5.1.1', - description='Асинхронный API-клиент для «Сетевого города»', - long_description=long_description, - long_description_content_type='text/markdown', - author='nm17', - author_email='dannevergame@gmail.com', - maintainer='igorlanov', - maintainer_email='vonalrogi@ya.ru', - url='https://github.com/nm17/netschoolapi/', - packages=['netschoolapi'], - package_data={'netschoolapi': ['py.typed']}, - classifiers=[ - 'License :: OSI Approved :: MIT License', - 'Natural Language :: Russian', - 'Topic :: Communications :: Chat', - 'Topic :: Education', - ], - license='MIT', - install_requires=['httpx', 'marshmallow'], - python_requires='>=3.6', -) +from setuptools import setup + + +with open('README.md') as readme: + long_description = readme.read() + + +setup( + name='netschoolapi', + version='5.1.2', + description='Асинхронный API-клиент для «Сетевого города»', + long_description=long_description, + long_description_content_type='text/markdown', + author='nm17', + author_email='dannevergame@gmail.com', + maintainer='igorlanov', + maintainer_email='vonalrogi@ya.ru', + url='https://github.com/nm17/netschoolapi/', + packages=['netschoolapi'], + package_data={'netschoolapi': ['py.typed']}, + classifiers=[ + 'License :: OSI Approved :: MIT License', + 'Natural Language :: Russian', + 'Topic :: Communications :: Chat', + 'Topic :: Education', + ], + license='MIT', + install_requires=['httpx', 'marshmallow'], + python_requires='>=3.6', +) From 6b92fd4f7873a039410a1ad0bc4903a6832c864c Mon Sep 17 00:00:00 2001 From: megahomyak Date: Wed, 9 Mar 2022 14:29:16 +0500 Subject: [PATCH 2/3] Why the hell it was CRLFed lol --- setup.py | 60 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/setup.py b/setup.py index 318d8cf..29933b6 100644 --- a/setup.py +++ b/setup.py @@ -1,30 +1,30 @@ -from setuptools import setup - - -with open('README.md') as readme: - long_description = readme.read() - - -setup( - name='netschoolapi', - version='5.1.2', - description='Асинхронный API-клиент для «Сетевого города»', - long_description=long_description, - long_description_content_type='text/markdown', - author='nm17', - author_email='dannevergame@gmail.com', - maintainer='igorlanov', - maintainer_email='vonalrogi@ya.ru', - url='https://github.com/nm17/netschoolapi/', - packages=['netschoolapi'], - package_data={'netschoolapi': ['py.typed']}, - classifiers=[ - 'License :: OSI Approved :: MIT License', - 'Natural Language :: Russian', - 'Topic :: Communications :: Chat', - 'Topic :: Education', - ], - license='MIT', - install_requires=['httpx', 'marshmallow'], - python_requires='>=3.6', -) +from setuptools import setup + + +with open('README.md') as readme: + long_description = readme.read() + + +setup( + name='netschoolapi', + version='5.1.2', + description='Асинхронный API-клиент для «Сетевого города»', + long_description=long_description, + long_description_content_type='text/markdown', + author='nm17', + author_email='dannevergame@gmail.com', + maintainer='igorlanov', + maintainer_email='vonalrogi@ya.ru', + url='https://github.com/nm17/netschoolapi/', + packages=['netschoolapi'], + package_data={'netschoolapi': ['py.typed']}, + classifiers=[ + 'License :: OSI Approved :: MIT License', + 'Natural Language :: Russian', + 'Topic :: Communications :: Chat', + 'Topic :: Education', + ], + license='MIT', + install_requires=['httpx', 'marshmallow'], + python_requires='>=3.6', +) From d15b9822b3556d99680ec5116e73e53c77ce9685 Mon Sep 17 00:00:00 2001 From: megahomyak Date: Wed, 9 Mar 2022 14:36:44 +0500 Subject: [PATCH 3/3] Versioning problems... --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 29933b6..6ce1878 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name='netschoolapi', - version='5.1.2', + version='7.1.1', description='Асинхронный API-клиент для «Сетевого города»', long_description=long_description, long_description_content_type='text/markdown',