Title: TypeError: 'float' object is not callable · Issue #63 · googleapis/python-api-core · GitHub
Open Graph Title: TypeError: 'float' object is not callable · Issue #63 · googleapis/python-api-core
X Title: TypeError: 'float' object is not callable · Issue #63 · googleapis/python-api-core
Description: How to reproduce: (1) clone https://github.com/googleapis/python-cloudbuild and checkout sijun branch. (2) run python -m nox -s unit-3.6 -- -s Exception thrown: def _apply_decorators(func, decorators): """Apply a list of decorators to a ...
Open Graph Description: How to reproduce: (1) clone https://github.com/googleapis/python-cloudbuild and checkout sijun branch. (2) run python -m nox -s unit-3.6 -- -s Exception thrown: def _apply_decorators(func, decorato...
X Description: How to reproduce: (1) clone https://github.com/googleapis/python-cloudbuild and checkout sijun branch. (2) run python -m nox -s unit-3.6 -- -s Exception thrown: def _apply_decorators(func, decorato...
Opengraph URL: https://github.com/googleapis/python-api-core/issues/63
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"TypeError: 'float' object is not callable","articleBody":"How to reproduce:\r\n(1) clone [https://github.com/googleapis/python-cloudbuild](https://github.com/googleapis/python-cloudbuild) and checkout `sijun` branch.\r\n(2) run `python -m nox -s unit-3.6 -- -s`\r\n\r\nException thrown:\r\n```\r\n def _apply_decorators(func, decorators):\r\n \"\"\"Apply a list of decorators to a given function.\r\n \r\n ``decorators`` may contain items that are ``None`` or ``False`` which will\r\n be ignored.\r\n \"\"\"\r\n decorators = filter(_is_not_none_or_false, reversed(decorators))\r\n \r\n for decorator in decorators:\r\n\u003e func = decorator(func)\r\nE TypeError: 'float' object is not callable\r\n```\r\n\r\nDescription of the bug:\r\n\r\n`google.api_core.gapic_v1.method._GapicCallable.__call__` [calls](https://github.com/googleapis/python-api-core/blob/master/google/api_core/gapic_v1/method.py#L115) `_determine_timeout` to create an `timeout_` object, then passes it to `_apply_decorators(self._target, [retry, timeout_])`. \r\n\r\nIn my example, `_determine_timeout(600.0, 600.0, None)` creates/returns `600.0`, which is a float object, when it is passed to `_apply_decorators`, the 'float' object is not callable is raised. \r\n\r\n`_determine_timeout` should always return a Timeout object.","author":{"url":"https://github.com/arithmetic1728","@type":"Person","name":"arithmetic1728"},"datePublished":"2020-07-21T00:15:43.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/63/python-api-core/issues/63"}
| 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:f997d88e-99ac-923b-b549-1134dfc6f9bd |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BC80:B577:10AF99A:16EA0E7:6A4DDB91 |
| html-safe-nonce | 8cebccd4032bca6dec913d44bdaef0c4ca01126c2ba3cb3ac39d53fd0a4681b1 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQzgwOkI1Nzc6MTBBRjk5QToxNkVBMEU3OjZBNEREQjkxIiwidmlzaXRvcl9pZCI6IjU5MDMwMDE0OTQzMzI3NTg5MjkiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | b6bee426cc8b6aebef2461dfb3999230aad53c4d3bbae865e5fdb688207f167d |
| hovercard-subject-tag | issue:662404417 |
| 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/googleapis/python-api-core/63/issue_layout |
| twitter:image | https://opengraph.githubassets.com/39dea0cac75c34f7b5d8d29f5d84c4dbb2b1ff5e2a45c595f14df6a3eb34d58f/googleapis/python-api-core/issues/63 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/39dea0cac75c34f7b5d8d29f5d84c4dbb2b1ff5e2a45c595f14df6a3eb34d58f/googleapis/python-api-core/issues/63 |
| og:image:alt | How to reproduce: (1) clone https://github.com/googleapis/python-cloudbuild and checkout sijun branch. (2) run python -m nox -s unit-3.6 -- -s Exception thrown: def _apply_decorators(func, decorato... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | arithmetic1728 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 06b8a6144231bf3a234f1c2e9993861e07ce98a905912b114aa386c2d7e84b33 |
| turbo-cache-control | no-preview |
| go-import | github.com/googleapis/python-api-core git https://github.com/googleapis/python-api-core.git |
| octolytics-dimension-user_id | 16785467 |
| octolytics-dimension-user_login | googleapis |
| octolytics-dimension-repository_id | 226992456 |
| octolytics-dimension-repository_nwo | googleapis/python-api-core |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 226992456 |
| octolytics-dimension-repository_network_root_nwo | googleapis/python-api-core |
| 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 | 1d344bdb7547fe6bca17a59bb2b8aac3dc9532a0 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width