Compliance with Telegram Bot API 6.5
This commit is contained in:
		| @@ -11,7 +11,7 @@ __author__ = "Davide Testa" | ||||
| __email__ = "davide@davte.it" | ||||
| __credits__ = ["Marco Origlia", "Nick Lee @Nickoala"] | ||||
| __license__ = "GNU General Public License v3.0" | ||||
| __version__ = "2.8.12" | ||||
| __version__ = "2.8.13" | ||||
| __maintainer__ = "Davide Testa" | ||||
| __contact__ = "t.me/davte" | ||||
|  | ||||
|   | ||||
| @@ -1091,6 +1091,7 @@ class TelegramBot: | ||||
|  | ||||
|     async def restrictChatMember(self, chat_id: Union[int, str], user_id: int, | ||||
|                                  permissions: Dict[str, bool], | ||||
|                                  use_independent_chat_permissions: bool = None, | ||||
|                                  until_date: Union[datetime.datetime, int] = None): | ||||
|         """Restrict a user in a supergroup. | ||||
|  | ||||
| @@ -1814,7 +1815,8 @@ class TelegramBot: | ||||
|     async def setChatPermissions(self, | ||||
|                                  chat_id: Union[int, str] = None, | ||||
|                                  permissions: Union[ChatPermissions, | ||||
|                                                     dict] = None): | ||||
|                                                     dict] = None, | ||||
|                                  use_independent_chat_permissions: bool = None): | ||||
|         """Set default chat permissions for all members. | ||||
|  | ||||
|         Use this method to set default chat permissions for all members. | ||||
|   | ||||
| @@ -1,10 +0,0 @@ | ||||
| #!/bin/bash | ||||
|  | ||||
| # Merge develop into master and push both branches; checkout to develop at the end. | ||||
|  | ||||
| git checkout master; | ||||
| git merge develop; | ||||
| git checkout develop; | ||||
| git push origin master develop; | ||||
| git push bitbucket master develop; | ||||
| git push github master; | ||||
							
								
								
									
										7
									
								
								push_to_remotes.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								push_to_remotes.sh
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | ||||
| #!/bin/bash | ||||
|  | ||||
| # Merge develop into master and push both branches; checkout to develop at the end. | ||||
|  | ||||
| git push origin main develop; | ||||
| git push bitbucket main develop; | ||||
| git push github main; | ||||
							
								
								
									
										14
									
								
								update_package.sh
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							
							
						
						
									
										14
									
								
								update_package.sh
									
									
									
									
									
										
										
										Normal file → Executable file
									
								
							| @@ -5,20 +5,20 @@ this_script_directory=$(cd "$(dirname "$0")" && pwd) | ||||
| packenv=""; | ||||
|  | ||||
| # Python virtual environment directory: packenv variable in my_config.sh | ||||
| source $this_script_directory/my_config.sh; | ||||
| source "$this_script_directory"/my_config.sh; | ||||
|  | ||||
| # Ensure the success of importing procedure | ||||
| if [ -z ${packenv} ]; | ||||
| if [ -z "${packenv}" ]; | ||||
| then | ||||
|   printf "Please set in ""my_config.sh"" the path to bot python virtual environment\n\nExample:\npackenv=""path/to/virtual/env""\n"; | ||||
|   exit; | ||||
| fi | ||||
|  | ||||
| # Merge, push, build and publish package to pypi.org | ||||
| bash merge_and_push.sh; | ||||
| # Push, build and publish package to pypi.org | ||||
| bash "$this_script_directory"/push_to_remotes.sh; | ||||
| rm -rf "$this_script_directory/build"; | ||||
| rm -rf "$this_script_directory/dist"; | ||||
| rm -rf "$this_script_directory/davtelepot.egg-info"; | ||||
| $packenv/python setup.py sdist; | ||||
| $packenv/pip wheel --no-index --no-deps --wheel-dir dist dist/*.tar.gz; | ||||
| $packenv/twine upload --skip-existing dist/*; | ||||
| "$packenv"/python setup.py sdist; | ||||
| "$packenv"/pip wheel --no-index --no-deps --wheel-dir dist dist/*.tar.gz; | ||||
| "$packenv"/twine upload --skip-existing dist/*; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user