Title: list_models() of dataset containing a BigQuery AutoML models errors with Invalid enum value AUTOML_REGRESSOR for enum type · Issue #293 · googleapis/python-bigquery · GitHub
Open Graph Title: list_models() of dataset containing a BigQuery AutoML models errors with Invalid enum value AUTOML_REGRESSOR for enum type · Issue #293 · googleapis/python-bigquery
X Title: list_models() of dataset containing a BigQuery AutoML models errors with Invalid enum value AUTOML_REGRESSOR for enum type · Issue #293 · googleapis/python-bigquery
Description: Listing standard BigQuery models (e.g. LINEAR_REGRESSION or https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial#run_the_create_model_query) works, but AutoML model (https://cloud.google.com/bigquery-ml/docs/referenc...
Open Graph Description: Listing standard BigQuery models (e.g. LINEAR_REGRESSION or https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial#run_the_create_model_query) works, but AutoML model (https://cl...
X Description: Listing standard BigQuery models (e.g. LINEAR_REGRESSION or https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial#run_the_create_model_query) works, but AutoML model (https://cl...
Opengraph URL: https://github.com/googleapis/python-bigquery/issues/293
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"list_models() of dataset containing a BigQuery AutoML models errors with Invalid enum value AUTOML_REGRESSOR for enum type","articleBody":"Listing standard BigQuery models (e.g. LINEAR_REGRESSION or https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial#run_the_create_model_query) works, but AutoML model (https://cloud.google.com/bigquery-ml/docs/reference/standard-sql/bigqueryml-syntax-create-automl#create_model_syntax) seems to fail?\r\n\r\n\r\n#### Environment details\r\n\r\n - OS type and version: Ubuntu 20.04\r\n - Python version: `Python 3.8.2 (default, Jul 16 2020, 14:00:26) `\r\n - pip version: `pip 20.2`\r\n\r\n```\r\npip3 freeze | grep goo\r\ngoogle-api-core==1.22.3\r\ngoogle-auth==1.22.0\r\ngoogle-cloud-bigquery==2.0.0\r\ngoogle-cloud-core==1.4.2\r\ngoogle-crc32c==1.0.0\r\ngoogle-resumable-media==1.0.0\r\ngoogleapis-common-protos==1.6.0\r\n```\r\n\r\n#### Steps to reproduce\r\n\r\n 1. Create a BigQuery AutoML model, e.g. https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial\r\n 2. Use the API to list the models\r\n\r\n#### Code example\r\n\r\n```python\r\nfrom google.cloud import bigquery\r\n\r\nclient = bigquery.Client() \r\n \r\nfor d in client.list_datasets():\r\n for m in client.list_models(d.reference):\r\n print(m.friendly_name)\r\n\r\n\r\n```\r\n\r\n#### Stack trace\r\n```\r\nTraceback (most recent call last):\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 745, in _ConvertScalarFieldValue\r\n number = int(value)\r\nValueError: invalid literal for int() with base 10: 'AUTOML_REGRESSOR'\r\n\r\nDuring handling of the above exception, another exception occurred:\r\n\r\nTraceback (most recent call last):\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 589, in _ConvertFieldValuePair\r\n setattr(message, field.name, _ConvertScalarFieldValue(value, field))\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 748, in _ConvertScalarFieldValue\r\n raise ParseError('Invalid enum value {0} for enum type {1}.'.format(\r\ngoogle.protobuf.json_format.ParseError: Invalid enum value AUTOML_REGRESSOR for enum type google.cloud.bigquery.v2.Model.ModelType.\r\n\r\nDuring handling of the above exception, another exception occurred:\r\n\r\nTraceback (most recent call last):\r\n File \"\u003cstdin\u003e\", line 2, in \u003cmodule\u003e\r\n File \" python3.8/site-packages/google/api_core/page_iterator.py\", line 213, in _items_iter\r\n for item in page:\r\n File \" python3.8/site-packages/google/api_core/page_iterator.py\", line 133, in next\r\n result = self._item_to_value(self._parent, item)\r\n File \" python3.8/site-packages/google/cloud/bigquery/client.py\", line 3241, in _item_to_model\r\n return Model.from_api_repr(resource)\r\n File \" python3.8/site-packages/google/cloud/bigquery/model.py\", line 308, in from_api_repr\r\n this._proto = json_format.ParseDict(\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 452, in ParseDict\r\n parser.ConvertMessage(js_dict, message)\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 483, in ConvertMessage\r\n self._ConvertFieldValuePair(value, message)\r\n File \" python3.8/site-packages/google/protobuf/json_format.py\", line 592, in _ConvertFieldValuePair\r\n raise ParseError('Failed to parse {0} field: {1}.'.format(name, e))\r\ngoogle.protobuf.json_format.ParseError: Failed to parse modelType field: Invalid enum value AUTOML_REGRESSOR for enum type google.cloud.bigquery.v2.Model.ModelType..\r\n```\r\n\r\n\r\n","author":{"url":"https://github.com/romainr","@type":"Person","name":"romainr"},"datePublished":"2020-10-03T14:42:14.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":8},"url":"https://github.com/293/python-bigquery/issues/293"}
| 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:37996140-e71b-fcc5-474e-ac7fbf679233 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B25C:29226:3096F2:4610FC:6A4E03D4 |
| html-safe-nonce | 98ab2282b6dc3ec22b79f1efa4be8758fa2a42a04ad998b109bd8bbd0a651323 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCMjVDOjI5MjI2OjMwOTZGMjo0NjEwRkM6NkE0RTAzRDQiLCJ2aXNpdG9yX2lkIjoiMzM5MDIwNDc5MzM0MzE5MDYwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 31451848e25c70ba2b233cb88188aab4d0b779194aeda05bf3aed47e36af2d50 |
| hovercard-subject-tag | issue:714104863 |
| 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-bigquery/293/issue_layout |
| twitter:image | https://opengraph.githubassets.com/6ef9289735c87c3e2e239f0407d451c36ba5987059c02a1dcc97261438b4a848/googleapis/python-bigquery/issues/293 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/6ef9289735c87c3e2e239f0407d451c36ba5987059c02a1dcc97261438b4a848/googleapis/python-bigquery/issues/293 |
| og:image:alt | Listing standard BigQuery models (e.g. LINEAR_REGRESSION or https://cloud.google.com/bigquery-ml/docs/bigqueryml-mf-explicit-tutorial#run_the_create_model_query) works, but AutoML model (https://cl... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | romainr |
| hostname | github.com |
| expected-hostname | github.com |
| None | df0492960db29b4938cb72070351d6b1d0c6c0767b27ceb8394bbf4fcc0223c6 |
| turbo-cache-control | no-preview |
| go-import | github.com/googleapis/python-bigquery git https://github.com/googleapis/python-bigquery.git |
| octolytics-dimension-user_id | 16785467 |
| octolytics-dimension-user_login | googleapis |
| octolytics-dimension-repository_id | 226992475 |
| octolytics-dimension-repository_nwo | googleapis/python-bigquery |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 226992475 |
| octolytics-dimension-repository_network_root_nwo | googleapis/python-bigquery |
| 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 | 52bde38e24398476f8eb1e0760c81346c6a00812 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width