-
Notifications
You must be signed in to change notification settings - Fork 42
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
Added separate methods for required path and body parameters and added Must/CanUseJson methods #666
Conversation
…d Must/CanUseJson methods
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.
LGTM, just a couple small suggestions
// JSON input to set all required fields for request. | ||
// If we can do so, it means we can ignore all positional arguments | ||
// passed for a certaing command and only use JSON input passed via --json flag. | ||
func (m *Method) CanSetRequiredFieldsFromJson() bool { |
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.
Should we leave this here so that we don't break compilation of the new tool with older versions of the SDK (e.g. someone checked out an older version of the SDK and is doing local testing)? We can deprecate this with a message saying not to use this method. WDYT?
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.
@mgyucht this is only for code generation and an SDK exposed method and it is not anymore anywhere (removed usage of it in CLI with this PR databricks/cli#905) so it should be safe to be removed
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
Codecov ReportAttention:
... and 1 file with indirect coverage changes 📢 Thoughts on this report? Let us know!. |
…cks/databricks-sdk-go into improve-required-path-parameters
…arameters and JSON input (#905) ## Changes Simplified code generation logic for handling path and request body parameters and JSON input Note: relies on these PRs: databricks/databricks-sdk-go#666 databricks/databricks-sdk-go#669 databricks/databricks-sdk-go#670
Changes
In attempt to simplify code generation logic (databricks/cli#905) added separate methods for required path and body parameters and added Must/CanUseJson methods.
Tests
make test
passingmake fmt
applied[ ] relevant integration tests applied