Title: Use contextlib.suppress instead of except: pass by blablatdinov · Pull Request #113 · gitpython-developers/gitdb · GitHub
Open Graph Title: Use contextlib.suppress instead of except: pass by blablatdinov · Pull Request #113 · gitpython-developers/gitdb
X Title: Use contextlib.suppress instead of except: pass by blablatdinov · Pull Request #113 · gitpython-developers/gitdb
Description: This PR refactors the LooseObjectDB class in gitdb/db/loose.py to utilize contextlib.suppress for handling KeyError exceptions, replacing the previous try-except block. This change improves code readability and aligns with best practices for exception handling in Python.
Open Graph Description: This PR refactors the LooseObjectDB class in gitdb/db/loose.py to utilize contextlib.suppress for handling KeyError exceptions, replacing the previous try-except block. This change improves code re...
X Description: This PR refactors the LooseObjectDB class in gitdb/db/loose.py to utilize contextlib.suppress for handling KeyError exceptions, replacing the previous try-except block. This change improves code re...
Opengraph URL: https://github.com/gitpython-developers/gitdb/pull/113
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:1869a722-8eca-ce01-db11-ca033c06a465 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | BE58:D7362:1EFE25B:2919411:696B0BDF |
| html-safe-nonce | 2e00cc4fd5c1e6f1246ddda324b5c36ccea73631bd429f548a502eba99842896 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRTU4OkQ3MzYyOjFFRkUyNUI6MjkxOTQxMTo2OTZCMEJERiIsInZpc2l0b3JfaWQiOiI0MDE5NjUxMzA0MTYwNDMxMDcxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 49e430692b5856758c55d5a5a1b1d7b9328be209d8036ae3dab886b4c57ed120 |
| hovercard-subject-tag | pull_request:1910685596 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,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/gitpython-developers/gitdb/pull/113/files |
| twitter:image | https://avatars.githubusercontent.com/u/45946541?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/45946541?s=400&v=4 |
| og:image:alt | This PR refactors the LooseObjectDB class in gitdb/db/loose.py to utilize contextlib.suppress for handling KeyError exceptions, replacing the previous try-except block. This change improves code re... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5f99f7c1d70f01da5b93e5ca90303359738944d8ab470e396496262c66e60b8d |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/gitpython-developers/gitdb git https://github.com/gitpython-developers/gitdb.git |
| octolytics-dimension-user_id | 503709 |
| octolytics-dimension-user_login | gitpython-developers |
| octolytics-dimension-repository_id | 1126093 |
| octolytics-dimension-repository_nwo | gitpython-developers/gitdb |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1126093 |
| octolytics-dimension-repository_network_root_nwo | gitpython-developers/gitdb |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 82560a55c6b2054555076f46e683151ee28a19bc |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width