Title: Expose measured duration on Timer context manager by vokracko · Pull Request #1166 · prometheus/client_python · GitHub
Open Graph Title: Expose measured duration on Timer context manager by vokracko · Pull Request #1166 · prometheus/client_python
X Title: Expose measured duration on Timer context manager by vokracko · Pull Request #1166 · prometheus/client_python
Description: Prometheus instrumentation library for Python applications - Expose measured duration on Timer context manager by vokracko · Pull Request #1166 · prometheus/client_python
Open Graph Description: Motivation When you use .time() as a context manager, the duration is already computed internally but thrown away — if you want to log or reuse it, you end up measuring twice: start = time.monotoni...
X Description: Motivation When you use .time() as a context manager, the duration is already computed internally but thrown away — if you want to log or reuse it, you end up measuring twice: start = time.monotoni...
Opengraph URL: https://github.com/prometheus/client_python/pull/1166
X: @github
Domain: github.com
| route-pattern | /_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format) |
| route-controller | voltron_pull_requests_fragments |
| route-action | pull_request_layout |
| fetch-nonce | v2:e5beb8e9-6047-056e-328f-ef35f48bfd6a |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 89B0:1FCD98:1E0898B:27D103C:6A51E204 |
| html-safe-nonce | cdf3df0c2226b04a1936e8835eb45fa8ded0dbe26ed9c8781049328687d2cd7f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4OUIwOjFGQ0Q5ODoxRTA4OThCOjI3RDEwM0M6NkE1MUUyMDQiLCJ2aXNpdG9yX2lkIjoiNzA5MDYxMTc3OTA0NzM4MzU1NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | b9d83e10f8afdc607c0654f3759d7a79a42b347a0d523080cd9b446bc38f6959 |
| hovercard-subject-tag | pull_request:3571751103 |
| 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/_view_fragments/voltron/pull_requests/show/prometheus/client_python/1166/pull_request_layout |
| twitter:image | https://opengraph.githubassets.com/69ce3b44c73355de0355a2131cfe2c8501f02f77b9d5fa41eea69b6395778648/prometheus/client_python/pull/1166 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/69ce3b44c73355de0355a2131cfe2c8501f02f77b9d5fa41eea69b6395778648/prometheus/client_python/pull/1166 |
| og:image:alt | Motivation When you use .time() as a context manager, the duration is already computed internally but thrown away — if you want to log or reuse it, you end up measuring twice: start = time.monotoni... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | vokracko |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-cache |
| go-import | github.com/prometheus/client_python git https://github.com/prometheus/client_python.git |
| octolytics-dimension-user_id | 3380462 |
| octolytics-dimension-user_login | prometheus |
| octolytics-dimension-repository_id | 30618733 |
| octolytics-dimension-repository_nwo | prometheus/client_python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 30618733 |
| octolytics-dimension-repository_network_root_nwo | prometheus/client_python |
| 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 | 7aed05249554b889eb33d002851a973eebcc7e91 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width