TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #175 · 30 окт.

В прошлом посте говоря "Все вызовы теперь одинаковы" я несколько слукавил. Всё-таки есть в этом зоопарке версий некоторая несовместимость вызов которой просто так не унифицировать. Эти моменты вынесены в отдельный модуль QtCompat (compatibility). Там не так много функций но они довольно полезны. Этот модуль содержит унификаци модуля shiboken2, функций loadUi, translate и несколько переименованных функций классов или изменённую сигнатуру аргументов и возвращаемых значений. Это единственное исключение из правила когда вам потребуется где-то изменить свой код кроме импортов и этот код не похож на обычный код PySide2. Например, в PyQt4 и PySide есть метод QHeaderView.setResizeMode Для PyQt5 и PySide2 они были благополучно переименованы в QHeaderView.setSectionResizeMode Чтобы применить этот метод следует использовать такой код from Qt import QtCompath header = self.horizontalHeader() QtCompat.QHeaderView.setSectionResizeMode(header, QtWidgets.QHeaderView.Fixed) Унификация загрузки UI файлов: # PySide2 from PySide2.QtUiTools import QUiLoader loader = QUiLoader() widget = loader.load(ui_file) # PyQt5 from PyQt5 import uic widget = uic.loadUi(ui_file) # Qt.py from Qt import QtCompat widget = QtCompat.loadUi(ui_file) Хорошо что таких моментов не много и их легко запомнить. Полный список можно посмотреть в таблице. #qt#tricks

Hashtags

Резултати

Пронајдени 10 слични објави

Пребарај: #resolved

当前筛选 #resolved清除筛选
Luckydonalds Bots: Development/Status

@luckydonaldsbots · Post #220 · 15.01.2020 г., 22:43

A few minutes ago I had a networking issue, making my server unreachable for a bit more than 5 minutes. Got that resolved and the services are responsive again. It may have happen that some messages got processed twice in that unstable period, which is due to how telegram sends updates. I appologize for any inconvenience. The server is now back to operating normal. #resolved

Hashtags

Luckydonalds Bots: Development/Status

@luckydonaldsbots · Post #125 · 01.02.2018 г., 17:47

17:46 UTC @BanWarnBot and @RulesRulesBot are back up. 17:50 UTC @HeyAdminBot is back up. 18:00 UTC @moustache_bot is back up. 18:25 UTC finally @StickerTagBot is back up. A file went missing, so not all code to run was there. Basic operation is back. 19:16 UTC @LangInfoBot is back up. 19:26 UTC @BassBoostBot is back up. Lol, as if anyone missed that bot. 19:34 UTC @bonbot is back up soon. Currently fighting with API rate limiting. 19:37 UTC @travis_cibot is back up. 19:45 UTC and the health checks are all good now. #resolved#update

Luckydonalds Bots: Development/Status

@luckydonaldsbots · Post #278 · 27.03.2021 г., 16:48

The worker node of @JoinCaptchaBot just restarted ungreacefully, in some cases causing up to 6 times the same messages. The good news is, while it happend multiple times in the same second, any missed out kicks were now processed as well (6 times). The issue has been identified and will be resolved soon. Sorry for your inconvinience. #resolved#JoinCaptchaBot

Luckydonalds Bots: Development/Status

@luckydonaldsbots · Post #252 · 04.07.2020 г., 15:57

@BanWarnBot is nowsuccessfully back up and running the newest version: Here's a list of what's new: New /kick and /ban commands: Just like the /warn one, but immediately removes the user from the chat, either once or permanently. You can specify a reason for why you kicked/banned someone after the command. Those kicks count into the normal warn count, because they are kinda like special warns. Those 3 commands, /warn, /kick and /ban now also allow the first thing after the command to be the id of a user, in the format of #1234, or a user mention. This can come in handy if you don't have a message to reply to. Overhaul of the warning lists: Now the list of /listwarnings and /listallwarnings will link you to the message warn message, if you press the date stamp. Also support for distinguishing automatic kicks/bans and manual kicks/bans has been added. #update#BanWarnBot#resolved

Luckydonalds Bots: Development/Status

@luckydonaldsbots · Post #218 · 08.09.2019 г., 19:48

Updated @HeyAdminBot: - Improved handling of private groups, will now export the join link if the bot has the rights for that - Added a direct link to the message ("requested") - Randomizing order of admins called so it's not always the same one being the first to respond. - Fixed bug where the first admin would receive the messages meant for the other admins as well. #update#resolved#HeyAdminBot