Add post_shutdown#3126
Add post_shutdown#3126Bibo-Joshi merged 6 commits intopython-telegram-bot:masterfrom ExalFabu:post_shutdown-method
post_shutdown#3126Conversation
Tests not succesful: - test_run_polling_post_shutdown - test_run_webhook_post_shutdown It is beyond my knowledge the reason why these 2 tests fails. Somehow Updater.shutdown is called two times
Bibo-Joshi
left a comment
There was a problem hiding this comment.
Thanks for the PR! I left two comments below
Co-authored-by: Bibo-Joshi <22366557+Bibo-Joshi@users.noreply.github.com>
|
I fixed and removed that duplicated line of code and the tests i wrote passed.
Edit 2: I think that what i wrote before was entirely wrong, so i leave it up to you big guys to help me understand where the issue is and I'll try and fix it for you |
|
The bad boy is this here: python-telegram-bot/telegram/ext/_application.py Lines 374 to 376 in f1d0339 this tells |
Co-authored-by: Harshil <37377066+harshil21@users.noreply.github.com>
|
Thank you for the contribution :) |
This should resolve #3105
I strictly followed #3078, I hope I've not missed any documentation that was required to change as well
Anyway, as I mentioned in the issue i am struggling with these test that i added:
test_run_polling_post_shutdowntest_run_webhook_post_shutdownHere's a screenshot of the error (it's the same for both tests)

I don't know if I've messed up the test itself or I'm missing something