Title: [BUG] get_stats function is not returning in the promised format · Issue #130 · datacommonsorg/api-python · GitHub
Open Graph Title: [BUG] get_stats function is not returning in the promised format · Issue #130 · datacommonsorg/api-python
X Title: [BUG] get_stats function is not returning in the promised format · Issue #130 · datacommonsorg/api-python
Description: Describe the bug The docstrings and docs indicate that get_stats returns "A dictionary mapping each Place identified by the given dcid to its name and the time series associated with the StatisticalVariable identified by the given stats_...
Open Graph Description: Describe the bug The docstrings and docs indicate that get_stats returns "A dictionary mapping each Place identified by the given dcid to its name and the time series associated with the Statistica...
X Description: Describe the bug The docstrings and docs indicate that get_stats returns "A dictionary mapping each Place identified by the given dcid to its name and the time series associated with the Stati...
Opengraph URL: https://github.com/datacommonsorg/api-python/issues/130
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[BUG] get_stats function is not returning in the promised format","articleBody":"**Describe the bug**\r\nThe docstrings and docs indicate that get_stats returns\r\n\r\n\"A dictionary mapping each Place identified by the given dcid to its name and the time series associated with the StatisticalVariable identified by the given stats_var and filtered by obs_dates.\"\r\n\r\nWhich is not true.\r\n\r\n**To Reproduce**\r\nSteps to reproduce the behavior:\r\n\r\n```\r\n\u003e dc.get_stats(['country/USA'], 'Count_Person')\r\n {'country/USA': {'data': {'2019': 328239523},\r\n 'is_dc_aggregate': True,\r\n 'place_dcid': 'country/USA',\r\n 'place_name': 'United States'}}\r\n```\r\n**Expected behavior**\r\n```\r\n\u003e dc.get_stats(['country/USA'], 'Count_Person')\r\n {'country/USA': {'data': {'2019': 328239523},\r\n 'place_name': 'United States'}}\r\n```\r\n\r\nOR updated docstring.\r\n\r\n**Screenshots**\r\n\r\n**Additional context**\r\n","author":{"url":"https://github.com/tjann","@type":"Person","name":"tjann"},"datePublished":"2020-07-10T05:38:04.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/130/api-python/issues/130"}
| 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:3418d38d-7c39-7764-9d22-45446f6c9275 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C6F4:2C98AB:50233B3:6D6ABB4:6978187A |
| html-safe-nonce | 91427e9cd86262dfdd63aee5c1c4986e0dc7c539e5379ec5a072dbaebca453db |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNkY0OjJDOThBQjo1MDIzM0IzOjZENkFCQjQ6Njk3ODE4N0EiLCJ2aXNpdG9yX2lkIjoiNjE0ODc3NDQ3ODA3MTk5NDQ5MCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 50d6061af54ce3db99757663fb532f28da5ef0557335c5708694372529d64242 |
| hovercard-subject-tag | issue:654524673 |
| 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/datacommonsorg/api-python/130/issue_layout |
| twitter:image | https://opengraph.githubassets.com/33a0a071c3ba8f732cd84ea1b20031d7ac493a94475ee725f671d48f38ed69fd/datacommonsorg/api-python/issues/130 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/33a0a071c3ba8f732cd84ea1b20031d7ac493a94475ee725f671d48f38ed69fd/datacommonsorg/api-python/issues/130 |
| og:image:alt | Describe the bug The docstrings and docs indicate that get_stats returns "A dictionary mapping each Place identified by the given dcid to its name and the time series associated with the Statistica... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | tjann |
| hostname | github.com |
| expected-hostname | github.com |
| None | e71ed39771d00f42ce2fc9320895c8c608c164191e118eae487fc3bd0af6886d |
| turbo-cache-control | no-preview |
| go-import | github.com/datacommonsorg/api-python git https://github.com/datacommonsorg/api-python.git |
| octolytics-dimension-user_id | 52017486 |
| octolytics-dimension-user_login | datacommonsorg |
| octolytics-dimension-repository_id | 150300890 |
| octolytics-dimension-repository_nwo | datacommonsorg/api-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 150300890 |
| octolytics-dimension-repository_network_root_nwo | datacommonsorg/api-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 | 4919f24054c1e9bf76d7b543cb2ac018075b18ce |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width