Title: Wrong project ID when running cloud monitoring custom metrics sample · Issue #244 · GoogleCloudPlatform/python-docs-samples · GitHub
Open Graph Title: Wrong project ID when running cloud monitoring custom metrics sample · Issue #244 · GoogleCloudPlatform/python-docs-samples
X Title: Wrong project ID when running cloud monitoring custom metrics sample · Issue #244 · GoogleCloudPlatform/python-docs-samples
Description: Trying to run this sample: https://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/monitoring/api/v3/custom_metric.py Command is: python custom_metric.py --project_id=evennia-game-directory Output is: File "/home/gtaylor/w...
Open Graph Description: Trying to run this sample: https://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/monitoring/api/v3/custom_metric.py Command is: python custom_metric.py --project_id=evennia-game-di...
X Description: Trying to run this sample: https://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/monitoring/api/v3/custom_metric.py Command is: python custom_metric.py --project_id=evennia-game-di...
Opengraph URL: https://github.com/GoogleCloudPlatform/python-docs-samples/issues/244
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Wrong project ID when running cloud monitoring custom metrics sample","articleBody":"Trying to run this sample:\nhttps://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/monitoring/api/v3/custom_metric.py\n\nCommand is:\n\n```\npython custom_metric.py --project_id=evennia-game-directory\n```\n\nOutput is:\n\n```\n File \"/home/gtaylor/workspace/evennia-game-dir/evennia_gamedir/views/game_list.py\", line 13, in game_list\n metric_poop()\n File \"/home/gtaylor/workspace/evennia-game-dir/evennia_gamedir/views/game_list.py\", line 60, in metric_poop\n name=project_resource, body=metrics_descriptor).execute()\n File \"/home/gtaylor/workspace/evennia-game-dir/lib/oauth2client/util.py\", line 137, in positional_wrapper\n return wrapped(*args, **kwargs)\n File \"/home/gtaylor/workspace/evennia-game-dir/lib/googleapiclient/http.py\", line 760, in execute\n raise HttpError(resp, content, uri=self.uri)\nHttpError: \u003cHttpError 403 when requesting https://monitoring.googleapis.com/v3/projects/evennia-game-directory/metricDescriptors?alt=json returned \"Google Monitoring API has not been used in project 32555940559 before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/monitoring/overview?project=32555940559 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.\"\u003e\nINFO 2016-04-07 05:43:27,970 module.py:787] default: \"GET / HTTP/1.1\" 500 291\n```\n\nIt's tossing out a weird project ID, so when I follow the link I get something odd:\n\nSeems like it's got me in some invalid project.\n\nIf I go to the actual project and look at the permissions, I've got them enabled (as of 20+ minutes ago):\n\n\nAny ideas? I'm aiming to get this working within App Engine, which I'm not sure is even possible. I'm running these samples from my dev machine with the latest gcloud SDK after having done `gcloud auth login`.\n","author":{"url":"https://github.com/gtaylor","@type":"Person","name":"gtaylor"},"datePublished":"2016-04-07T05:47:10.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/244/python-docs-samples/issues/244"}
| 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:09249fa0-0166-f9a3-a0f4-9a21e08df2aa |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B960:3861F:AAEF39:E89C5A:6A4D5177 |
| html-safe-nonce | 1fd9f2c35d10b1507fb5ab4988fa2bb56760c326f34408e0966eeb5b0b044b51 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCOTYwOjM4NjFGOkFBRUYzOTpFODlDNUE6NkE0RDUxNzciLCJ2aXNpdG9yX2lkIjoiNDY3ODgyNzc0NTAwNTYyMTYyMyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 8cd18451b4b27078e4792cd581f3da0bdb757cbcf07ef629b1d4556a78eb4365 |
| hovercard-subject-tag | issue:146515630 |
| 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/GoogleCloudPlatform/python-docs-samples/244/issue_layout |
| twitter:image | https://opengraph.githubassets.com/61ee59597321598df2fc35b2f3c458d5aeb6fc87042a22f426d728c347b15030/GoogleCloudPlatform/python-docs-samples/issues/244 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/61ee59597321598df2fc35b2f3c458d5aeb6fc87042a22f426d728c347b15030/GoogleCloudPlatform/python-docs-samples/issues/244 |
| og:image:alt | Trying to run this sample: https://github.com/GoogleCloudPlatform/python-docs-samples/blob/master/monitoring/api/v3/custom_metric.py Command is: python custom_metric.py --project_id=evennia-game-di... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | gtaylor |
| hostname | github.com |
| expected-hostname | github.com |
| None | 92571a8944142227b7e19cd10918b1ddd06e5066c1ad5bc7e4769cf6140a87e6 |
| turbo-cache-control | no-preview |
| go-import | github.com/GoogleCloudPlatform/python-docs-samples git https://github.com/GoogleCloudPlatform/python-docs-samples.git |
| octolytics-dimension-user_id | 2810941 |
| octolytics-dimension-user_login | GoogleCloudPlatform |
| octolytics-dimension-repository_id | 35065876 |
| octolytics-dimension-repository_nwo | GoogleCloudPlatform/python-docs-samples |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 35065876 |
| octolytics-dimension-repository_network_root_nwo | GoogleCloudPlatform/python-docs-samples |
| 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 | 56fc8347865a14e2ec811533d68f929cf4e0ec19 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width