-
Notifications
You must be signed in to change notification settings - Fork 197
feat: generate SDKs for Looker 25_16 #1603
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Release-As: 25_16.0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of Changes
Hello @drstrangelooker, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request updates the SDKs to align with Looker version 25.16, introducing a new API method for managing user API3 credentials and enhancing existing functionalities. Key improvements include more refined search options for content favorites and users, expanded metadata for various content types, and clearer definitions for database connection authentication. The changes also involve a significant refactoring of CI run-related models for better clarity and consistency.
Highlights
- SDK Version Update: The SDK version has been updated across all supported languages from
25.10to25.16to align with the latest Looker release. - New API Method Added: A new API method,
update_user_credentials_api3, has been introduced, allowing for patching API3 credentials for a specified user. - Model Renaming and Refactoring: The
CIRunandProjectCIRunmodels have been renamed toRunandProjectRunrespectively, streamlining the naming convention for CI run-related entities and impacting theget_ci_runmethod's return type. - Enhanced Content Favorite Search: The
search_content_favoritesmethod now includes aninclude_board_itemsparameter, providing more granular control over search results for board-related content favorites. - Expanded User Search Capabilities: The
search_usersmethod has been augmented with a newcan_manage_api3_credsparameter, enabling filtering of users based on their API3 credential management permissions. - API3 Credential Purpose Field: A
purposefield has been added toCreateCredentialsApi3,CredentialsApi3, andWriteCredentialsApi3models, allowing users to define the intent behind their API3 credentials. - New Dashboard-Related Fields: The
ContentFavoriteandWriteContentFavoritemodels now includelookml_dashboard_idandlookml_dashboardfields, enhancing support for LookML dashboards. - Content Metadata Expansion: The
ContentMetaandWriteContentMetamodels have been updated withhomepage_idandagent_idfields, providing more context for content metadata related to boards and agents. - Database Connection Authentication: A
uses_service_authfield has been added to theDBConnectionandWriteDBConnectionmodels, indicating whether a database connection utilizes service authentication certificates. - Result Maker Model Clarifications: Descriptions for several fields within
ResultMakerFilterablesandResultMakerWithIdVisConfigAndDynamicFieldsmodels have been updated, removing the 'read-only' designation for certain fields, which may imply new writeable capabilities.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in pull request comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
Python Tests 5 files 5 suites 2s ⏱️ For more details on these failures, see this check. Results for commit 4617ac3. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request updates the SDKs to support Looker version 25.16. The changes, which appear to be auto-generated, include version bumps, new API methods, and model updates. The changes are largely consistent across the different language SDKs. I've identified a few minor issues related to code formatting in the generated Python, Go, and Swift code that impact readability and maintainability.
| options *rtl.ApiSettings) ([]ContentFavorite, error) { | ||
| var result []ContentFavorite | ||
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/content_favorite/search", map[string]interface{}{"id": request.Id, "user_id": request.UserId, "content_metadata_id": request.ContentMetadataId, "dashboard_id": request.DashboardId, "look_id": request.LookId, "board_id": request.BoardId, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "fields": request.Fields, "filter_or": request.FilterOr}, nil, options) | ||
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/content_favorite/search", map[string]interface{}{"id": request.Id, "user_id": request.UserId, "content_metadata_id": request.ContentMetadataId, "dashboard_id": request.DashboardId, "look_id": request.LookId, "board_id": request.BoardId, "include_board_items": request.IncludeBoardItems, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "fields": request.Fields, "filter_or": request.FilterOr}, nil, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is excessively long, which harms readability and maintainability. It's standard practice in Go to format long map literals across multiple lines. Please consider updating the code generator to produce more readable code.
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/content_favorite/search", map[string]interface{}{"id": request.Id, "user_id": request.UserId, "content_metadata_id": request.ContentMetadataId, "dashboard_id": request.DashboardId, "look_id": request.LookId, "board_id": request.BoardId, "include_board_items": request.IncludeBoardItems, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "fields": request.Fields, "filter_or": request.FilterOr}, nil, options) | |
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/content_favorite/search", map[string]interface{}{ | |
| "id": request.Id, | |
| "user_id": request.UserId, | |
| "content_metadata_id": request.ContentMetadataId, | |
| "dashboard_id": request.DashboardId, | |
| "look_id": request.LookId, | |
| "board_id": request.BoardId, | |
| "include_board_items": request.IncludeBoardItems, | |
| "limit": request.Limit, | |
| "offset": request.Offset, | |
| "sorts": request.Sorts, | |
| "fields": request.Fields, | |
| "filter_or": request.FilterOr, | |
| }, nil, options) |
| options *rtl.ApiSettings) ([]User, error) { | ||
| var result []User | ||
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/users/search", map[string]interface{}{"fields": request.Fields, "page": request.Page, "per_page": request.PerPage, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "id": request.Id, "first_name": request.FirstName, "last_name": request.LastName, "verified_looker_employee": request.VerifiedLookerEmployee, "embed_user": request.EmbedUser, "email": request.Email, "is_disabled": request.IsDisabled, "filter_or": request.FilterOr, "content_metadata_id": request.ContentMetadataId, "group_id": request.GroupId}, nil, options) | ||
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/users/search", map[string]interface{}{"fields": request.Fields, "page": request.Page, "per_page": request.PerPage, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "id": request.Id, "first_name": request.FirstName, "last_name": request.LastName, "verified_looker_employee": request.VerifiedLookerEmployee, "embed_user": request.EmbedUser, "email": request.Email, "is_disabled": request.IsDisabled, "filter_or": request.FilterOr, "content_metadata_id": request.ContentMetadataId, "group_id": request.GroupId, "can_manage_api3_creds": request.CanManageApi3Creds}, nil, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is excessively long, which harms readability and maintainability. It's standard practice in Go to format long map literals across multiple lines. Please consider updating the code generator to produce more readable code.
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/users/search", map[string]interface{}{"fields": request.Fields, "page": request.Page, "per_page": request.PerPage, "limit": request.Limit, "offset": request.Offset, "sorts": request.Sorts, "id": request.Id, "first_name": request.FirstName, "last_name": request.LastName, "verified_looker_employee": request.VerifiedLookerEmployee, "embed_user": request.EmbedUser, "email": request.Email, "is_disabled": request.IsDisabled, "filter_or": request.FilterOr, "content_metadata_id": request.ContentMetadataId, "group_id": request.GroupId, "can_manage_api3_creds": request.CanManageApi3Creds}, nil, options) | |
| err := l.AuthSession.Do(&result, "GET", "/4.0", "/users/search", map[string]interface{}{ | |
| "fields": request.Fields, | |
| "page": request.Page, | |
| "per_page": request.PerPage, | |
| "limit": request.Limit, | |
| "offset": request.Offset, | |
| "sorts": request.Sorts, | |
| "id": request.Id, | |
| "first_name": request.FirstName, | |
| "last_name": request.LastName, | |
| "verified_looker_employee": request.VerifiedLookerEmployee, | |
| "embed_user": request.EmbedUser, | |
| "email": request.Email, | |
| "is_disabled": request.IsDisabled, | |
| "filter_or": request.FilterOr, | |
| "content_metadata_id": request.ContentMetadataId, | |
| "group_id": request.GroupId, | |
| "can_manage_api3_creds": request.CanManageApi3Creds, | |
| }, nil, options) |
| """ | ||
| Dynamic writeable type for ContentFavorite removes: | ||
| id, look_id, dashboard_id, board_id | ||
| id, look_id, dashboard_id, board_id, lookml_dashboard_id | ||
|
|
||
| Attributes: | ||
| user_id: User Id which owns this ContentFavorite | ||
| content_metadata_id: Content Metadata Id associated with this ContentFavorite | ||
| look: Dynamic writeable type for LookBasic removes: | ||
| can, content_metadata_id, id, title | ||
| dashboard: Dynamic writeable type for DashboardBase removes: | ||
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | ||
| lookml_dashboard: Dynamic writeable type for DashboardBase removes: | ||
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | ||
| """ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The indentation in this docstring is inconsistent, making it difficult to read. The lists of removed properties are not correctly indented. For better readability and adherence to PEP 257, please ensure the code generator produces correctly formatted docstrings.
| """ | |
| Dynamic writeable type for ContentFavorite removes: | |
| id, look_id, dashboard_id, board_id | |
| id, look_id, dashboard_id, board_id, lookml_dashboard_id | |
| Attributes: | |
| user_id: User Id which owns this ContentFavorite | |
| content_metadata_id: Content Metadata Id associated with this ContentFavorite | |
| look: Dynamic writeable type for LookBasic removes: | |
| can, content_metadata_id, id, title | |
| dashboard: Dynamic writeable type for DashboardBase removes: | |
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | |
| lookml_dashboard: Dynamic writeable type for DashboardBase removes: | |
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | |
| """ | |
| """ | |
| Dynamic writeable type for ContentFavorite removes: | |
| id, look_id, dashboard_id, board_id, lookml_dashboard_id | |
| Attributes: | |
| user_id: User Id which owns this ContentFavorite | |
| content_metadata_id: Content Metadata Id associated with this ContentFavorite | |
| look: Dynamic writeable type for LookBasic removes: | |
| can, content_metadata_id, id, title | |
| dashboard: Dynamic writeable type for DashboardBase removes: | |
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | |
| lookml_dashboard: Dynamic writeable type for DashboardBase removes: | |
| can, content_favorite_id, content_metadata_id, description, hidden, id, model, query_timezone, readonly, refresh_interval, refresh_interval_to_i, title, user_id, slug, preferred_viewer | |
| """ |
| """ | ||
| Dynamic writeable type for ResultMakerWithIdVisConfigAndDynamicFields removes: | ||
| id, dynamic_fields, filterables, sorts, merge_result_id, total, query_id, sql_query_id, vis_config | ||
| id, query_id | ||
|
|
||
| Attributes: | ||
| dynamic_fields: JSON string of dynamic field information. | ||
| filterables: array of items that can be filtered and information about them. | ||
| sorts: Sorts of the constituent Look, Query, or Merge Query | ||
| merge_result_id: ID of merge result if this is a merge_result. | ||
| total: Total of the constituent Look, Query, or Merge Query | ||
| sql_query_id: ID of SQL Query if this is a SQL Runner Query | ||
| query: Dynamic writeable type for Query removes: | ||
| can, id, slug, share_url, expanded_share_url, url, has_table_calculations | ||
| vis_config: Vis config of the constituent Query, or Merge Query. | ||
| """ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The indentation in this docstring is inconsistent, which harms readability. The lists of removed properties and the Attributes section are not correctly indented. To improve code quality and adhere to PEP 257, please adjust the generator to produce properly formatted docstrings.
| """ | |
| Dynamic writeable type for ResultMakerWithIdVisConfigAndDynamicFields removes: | |
| id, dynamic_fields, filterables, sorts, merge_result_id, total, query_id, sql_query_id, vis_config | |
| id, query_id | |
| Attributes: | |
| dynamic_fields: JSON string of dynamic field information. | |
| filterables: array of items that can be filtered and information about them. | |
| sorts: Sorts of the constituent Look, Query, or Merge Query | |
| merge_result_id: ID of merge result if this is a merge_result. | |
| total: Total of the constituent Look, Query, or Merge Query | |
| sql_query_id: ID of SQL Query if this is a SQL Runner Query | |
| query: Dynamic writeable type for Query removes: | |
| can, id, slug, share_url, expanded_share_url, url, has_table_calculations | |
| vis_config: Vis config of the constituent Query, or Merge Query. | |
| """ | |
| """ | |
| Dynamic writeable type for ResultMakerWithIdVisConfigAndDynamicFields removes: | |
| id, query_id | |
| Attributes: | |
| dynamic_fields: JSON string of dynamic field information. | |
| filterables: array of items that can be filtered and information about them. | |
| sorts: Sorts of the constituent Look, Query, or Merge Query | |
| merge_result_id: ID of merge result if this is a merge_result. | |
| total: Total of the constituent Look, Query, or Merge Query | |
| sql_query_id: ID of SQL Query if this is a SQL Runner Query | |
| query: Dynamic writeable type for Query removes: | |
| can, id, slug, share_url, expanded_share_url, url, has_table_calculations | |
| vis_config: Vis config of the constituent Query, or Merge Query. | |
| """ |
| ) -> SDKResponse<[ContentFavorite], SDKError> { | ||
| let result: SDKResponse<[ContentFavorite], SDKError> = self.get("/content_favorite/search", | ||
| ["id": id, "user_id": user_id, "content_metadata_id": content_metadata_id, "dashboard_id": dashboard_id, "look_id": look_id, "board_id": board_id, "limit": limit, "offset": offset, "sorts": sorts, "fields": fields, "filter_or": filter_or as Any?], nil, options) | ||
| ["id": id, "user_id": user_id, "content_metadata_id": content_metadata_id, "dashboard_id": dashboard_id, "look_id": look_id, "board_id": board_id, "include_board_items": include_board_items as Any?, "limit": limit, "offset": offset, "sorts": sorts, "fields": fields, "filter_or": filter_or as Any?], nil, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is excessively long, making the code difficult to read and maintain. For better readability, please consider breaking the dictionary literal into multiple lines, which is a standard practice in Swift.
[
"id": id,
"user_id": user_id,
"content_metadata_id": content_metadata_id,
"dashboard_id": dashboard_id,
"look_id": look_id,
"board_id": board_id,
"include_board_items": include_board_items as Any?,
"limit": limit,
"offset": offset,
"sorts": sorts,
"fields": fields,
"filter_or": filter_or as Any?
], nil, options)| ) -> SDKResponse<[User], SDKError> { | ||
| let result: SDKResponse<[User], SDKError> = self.get("/users/search", | ||
| ["fields": fields, "page": page, "per_page": per_page, "limit": limit, "offset": offset, "sorts": sorts, "id": id, "first_name": first_name, "last_name": last_name, "verified_looker_employee": verified_looker_employee as Any?, "embed_user": embed_user as Any?, "email": email, "is_disabled": is_disabled as Any?, "filter_or": filter_or as Any?, "content_metadata_id": content_metadata_id, "group_id": group_id], nil, options) | ||
| ["fields": fields, "page": page, "per_page": per_page, "limit": limit, "offset": offset, "sorts": sorts, "id": id, "first_name": first_name, "last_name": last_name, "verified_looker_employee": verified_looker_employee as Any?, "embed_user": embed_user as Any?, "email": email, "is_disabled": is_disabled as Any?, "filter_or": filter_or as Any?, "content_metadata_id": content_metadata_id, "group_id": group_id, "can_manage_api3_creds": can_manage_api3_creds as Any?], nil, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is excessively long, which harms readability and maintainability. It's a good practice in Swift to format long dictionary literals across multiple lines. Please consider updating the code generator to improve the formatting.
[
"fields": fields,
"page": page,
"per_page": per_page,
"limit": limit,
"offset": offset,
"sorts": sorts,
"id": id,
"first_name": first_name,
"last_name": last_name,
"verified_looker_employee": verified_looker_employee as Any?,
"embed_user": embed_user as Any?,
"email": email,
"is_disabled": is_disabled as Any?,
"filter_or": filter_or as Any?,
"content_metadata_id": content_metadata_id,
"group_id": group_id,
"can_manage_api3_creds": can_manage_api3_creds as Any?
], nil, options)
Typescript Tests 2 files 56 suites 1m 0s ⏱️ Results for commit 4617ac3. |
Release-As: 25.16.0