Skip to content

Commit

Permalink
[Internal] Update OpenAPI spec (#715)
Browse files Browse the repository at this point in the history
## Changes
<!-- Summary of your changes that are easy to understand -->
Update OpenAPI spec

## Tests
<!-- 
How is this tested? Please see the checklist below and also describe any
other relevant tests
-->

- [X] `make test` run locally
- [X] `make fmt` applied
- [x] relevant integration tests applied
  • Loading branch information
hectorcast-db authored Jul 22, 2024
1 parent b0750eb commit 6a9c534
Show file tree
Hide file tree
Showing 17 changed files with 4,520 additions and 1,148 deletions.
2 changes: 1 addition & 1 deletion .codegen/_openapi_sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7437dabb9dadee402c1fc060df4c1ce8cc5369f0
37e2bbe0cbcbbbe78a06a018d4fab06314a26a40
4 changes: 2 additions & 2 deletions .codegen/service.py.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ class {{.PascalName}}API:{{if .Description}}
{{if .NeedsOffsetDedupe -}}
# deduplicate items that may have been added during iteration
seen = set()
{{- end}}{{if and .Pagination.Offset (not (eq .Path "/api/2.0/clusters/events")) }}
{{- end}}{{if and .Pagination.Offset (not (eq .Path "/api/2.1/clusters/events")) }}
query['{{.Pagination.Offset.Name}}'] =
{{- if eq .Pagination.Increment 1 -}}
1
Expand All @@ -321,7 +321,7 @@ class {{.PascalName}}API:{{if .Description}}
if '{{.Pagination.Token.Bind.Name}}' not in json or not json['{{.Pagination.Token.Bind.Name}}']:
return
{{if or (eq "GET" .Verb) (eq "HEAD" .Verb)}}query{{else}}body{{end}}['{{.Pagination.Token.PollField.Name}}'] = json['{{.Pagination.Token.Bind.Name}}']
{{- else if eq .Path "/api/2.0/clusters/events" -}}
{{- else if eq .Path "/api/2.1/clusters/events" -}}
if 'next_page' not in json or not json['next_page']:
return
body = json['next_page']
Expand Down
65 changes: 49 additions & 16 deletions databricks/sdk/__init__.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 6a9c534

Please sign in to comment.