Rubka 4.4.19__tar.gz → 4.4.20__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. {rubka-4.4.19 → rubka-4.4.20}/PKG-INFO +1 -1
  2. {rubka-4.4.19 → rubka-4.4.20}/Rubka.egg-info/PKG-INFO +1 -1
  3. {rubka-4.4.19 → rubka-4.4.20}/rubka/api.py +16 -13
  4. {rubka-4.4.19 → rubka-4.4.20}/setup.py +1 -1
  5. {rubka-4.4.19 → rubka-4.4.20}/README.md +0 -0
  6. {rubka-4.4.19 → rubka-4.4.20}/Rubka.egg-info/SOURCES.txt +0 -0
  7. {rubka-4.4.19 → rubka-4.4.20}/Rubka.egg-info/dependency_links.txt +0 -0
  8. {rubka-4.4.19 → rubka-4.4.20}/Rubka.egg-info/requires.txt +0 -0
  9. {rubka-4.4.19 → rubka-4.4.20}/Rubka.egg-info/top_level.txt +0 -0
  10. {rubka-4.4.19 → rubka-4.4.20}/rubka/__init__.py +0 -0
  11. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/__init__.py +0 -0
  12. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/client/__init__.py +0 -0
  13. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/client/client.py +0 -0
  14. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/crypto/__init__.py +0 -0
  15. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/crypto/crypto.py +0 -0
  16. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/enums.py +0 -0
  17. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/exceptions.py +0 -0
  18. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/methods/__init__.py +0 -0
  19. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/methods/methods.py +0 -0
  20. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/network/__init__.py +0 -0
  21. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/network/helper.py +0 -0
  22. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/network/network.py +0 -0
  23. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/network/socket.py +0 -0
  24. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/sessions/__init__.py +0 -0
  25. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/sessions/sessions.py +0 -0
  26. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/types/__init__.py +0 -0
  27. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/types/socket/__init__.py +0 -0
  28. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/types/socket/message.py +0 -0
  29. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/utils/__init__.py +0 -0
  30. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/utils/configs.py +0 -0
  31. {rubka-4.4.19 → rubka-4.4.20}/rubka/adaptorrubka/utils/utils.py +0 -0
  32. {rubka-4.4.19 → rubka-4.4.20}/rubka/button.py +0 -0
  33. {rubka-4.4.19 → rubka-4.4.20}/rubka/config.py +0 -0
  34. {rubka-4.4.19 → rubka-4.4.20}/rubka/context.py +0 -0
  35. {rubka-4.4.19 → rubka-4.4.20}/rubka/decorators.py +0 -0
  36. {rubka-4.4.19 → rubka-4.4.20}/rubka/exceptions.py +0 -0
  37. {rubka-4.4.19 → rubka-4.4.20}/rubka/jobs.py +0 -0
  38. {rubka-4.4.19 → rubka-4.4.20}/rubka/keyboards.py +0 -0
  39. {rubka-4.4.19 → rubka-4.4.20}/rubka/keypad.py +0 -0
  40. {rubka-4.4.19 → rubka-4.4.20}/rubka/logger.py +0 -0
  41. {rubka-4.4.19 → rubka-4.4.20}/rubka/rubino.py +0 -0
  42. {rubka-4.4.19 → rubka-4.4.20}/rubka/utils.py +0 -0
  43. {rubka-4.4.19 → rubka-4.4.20}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Rubka
3
- Version: 4.4.19
3
+ Version: 4.4.20
4
4
  Summary: A Python library for interacting with Rubika Bot API.
5
5
  Home-page: https://github.com/Mahdy-Ahmadi/Rubka
6
6
  Download-URL: https://github.com/Mahdy-Ahmadi/rubka/blob/main/project_library.zip
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Rubka
3
- Version: 4.4.19
3
+ Version: 4.4.20
4
4
  Summary: A Python library for interacting with Rubika Bot API.
5
5
  Home-page: https://github.com/Mahdy-Ahmadi/Rubka
6
6
  Download-URL: https://github.com/Mahdy-Ahmadi/rubka/blob/main/project_library.zip
@@ -115,11 +115,23 @@ class Robot:
115
115
  self._inline_query_handler = None
116
116
  self._callback_handlers = None
117
117
  self._callback_handlers = [] # ✅ این خط مهمه
118
- json_url = requests.get(web_hook).json()['url']
119
118
  if web_hook:
120
- for endpoint_type in ["ReceiveUpdate", "ReceiveInlineMessage", "ReceiveQuery", "GetSelectionItem", "SearchSelectionItems"]:
121
- print(self.update_bot_endpoint(web_hook, endpoint_type))
122
- self.web_hook = json_url
119
+ try:
120
+ json_url = requests.get(web_hook, timeout=self.timeout).json().get('url', web_hook)
121
+ for endpoint_type in [
122
+ "ReceiveUpdate",
123
+ "ReceiveInlineMessage",
124
+ "ReceiveQuery",
125
+ "GetSelectionItem",
126
+ "SearchSelectionItems"
127
+ ]:
128
+ print(self.update_bot_endpoint(self.web_hook, endpoint_type))
129
+ self.web_hook = json_url
130
+ except Exception as e:
131
+ logger.error(f"Failed to set webhook from {web_hook}: {e}")
132
+ else:
133
+ self.web_hook = None
134
+
123
135
 
124
136
 
125
137
  logger.info(f"Initialized RubikaBot with token: {token[:8]}***")
@@ -366,15 +378,6 @@ class Robot:
366
378
 
367
379
  except Exception as e:
368
380
  print(f"❌ Error in run loop: {e}")
369
-
370
-
371
-
372
-
373
-
374
-
375
-
376
-
377
-
378
381
  def send_message(
379
382
  self,
380
383
  chat_id: str,
@@ -8,7 +8,7 @@ except FileNotFoundError:
8
8
 
9
9
  setup(
10
10
  name='Rubka',
11
- version='4.4.19',
11
+ version='4.4.20',
12
12
  description='A Python library for interacting with Rubika Bot API.',
13
13
  long_description=long_description,
14
14
  long_description_content_type='text/markdown',
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes