Title: Refactor handling of exceptions raised by error handlers · Issue #2601 · python-telegram-bot/python-telegram-bot · GitHub
Open Graph Title: Refactor handling of exceptions raised by error handlers · Issue #2601 · python-telegram-bot/python-telegram-bot
X Title: Refactor handling of exceptions raised by error handlers · Issue #2601 · python-telegram-bot/python-telegram-bot
Description: Currently, we do something like try: dispatcher.dispatch_error(exception) except: logger.execption(…) everywhere, where we call dispatcher.dispatch_error, leading to some code repetition. I propose to instead move that logic directly int...
Open Graph Description: Currently, we do something like try: dispatcher.dispatch_error(exception) except: logger.execption(…) everywhere, where we call dispatcher.dispatch_error, leading to some code repetition. I propose...
X Description: Currently, we do something like try: dispatcher.dispatch_error(exception) except: logger.execption(…) everywhere, where we call dispatcher.dispatch_error, leading to some code repetition. I propose...
Opengraph URL: https://github.com/python-telegram-bot/python-telegram-bot/issues/2601
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Refactor handling of exceptions raised by error handlers","articleBody":"Currently, we do something like\r\n\r\n```python\r\ntry:\r\n dispatcher.dispatch_error(exception)\r\nexcept:\r\n logger.execption(…)\r\n```\r\n\r\neverywhere, where we call `dispatcher.dispatch_error`, leading to some code repetition. I propose to instead move that logic directly into `Dispatcher.dispatch_error`. The only downside of this would be that currently log message in line 4 above can contain some explicit hint on where the exception happened, but one can also just read the traceback …\r\n\r\nEdit: This would also cover cases where some `CustomContext.from_*` raises an exception, see the discussion at https://t.me/c/1494805131/17428","author":{"url":"https://github.com/Bibo-Joshi","@type":"Person","name":"Bibo-Joshi"},"datePublished":"2021-07-22T15:49:14Z","url":"https://github.com/python-telegram-bot/python-telegram-bot/issues/2601"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:8c37eed2-da14-ecd1-6c2b-0e31431e4558 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8816:25866C:85E5FC:AF4DB3:6B0255DC |
| html-safe-nonce | 722f176646209d2e6300b46328193b571c94a8c0e511a7f01420a1f77d1f8dd2 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4ODE2OjI1ODY2Qzo4NUU1RkM6QUY0REIzOjZCMDI1NURDIiwidmlzaXRvcl9pZCI6IjIwNjY5NTYwNjY3MTcwNjI2MjAiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | e602c343d15965067abe7b673a7eb21dedef28ff8f1ff27bf67cf9c970982eae |
| hovercard-subject-tag | issue:950810194 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python-telegram-bot/python-telegram-bot/2601/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c29723f6127d153d7733615a37205486f1371b3590b96825394991db78e7daa2/python-telegram-bot/python-telegram-bot/issues/2601 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c29723f6127d153d7733615a37205486f1371b3590b96825394991db78e7daa2/python-telegram-bot/python-telegram-bot/issues/2601 |
| og:image:alt | Currently, we do something like try: dispatcher.dispatch_error(exception) except: logger.execption(…) everywhere, where we call dispatcher.dispatch_error, leading to some code repetition. I propose... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Bibo-Joshi |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/python-telegram-bot/python-telegram-bot git https://github.com/python-telegram-bot/python-telegram-bot.git |
| octolytics-dimension-user_id | 16178365 |
| octolytics-dimension-user_login | python-telegram-bot |
| octolytics-dimension-repository_id | 38696925 |
| octolytics-dimension-repository_nwo | python-telegram-bot/python-telegram-bot |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 38696925 |
| octolytics-dimension-repository_network_root_nwo | python-telegram-bot/python-telegram-bot |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width