Adjust type hints in credentials handling for Azure API client#1964
Merged
asnare merged 1 commit intodependabot/pip/databricks-sdk-gte-0.27-and-lt-0.30from Jul 2, 2024
Conversation
|
❌ 168/172 passed, 4 failed, 24 skipped, 5h40m32s total ❌ test_running_real_workflow_linter_job: TimeoutError: timed out after 0:20:00: (21m49.008s)❌ test_table_migration_job_cluster_override[regular]: AssertionError: assert False (12m15.845s)❌ test_table_migration_job_refreshes_migration_status[regular-migrate-tables]: AssertionError: No destination schema found for TableType.VIEW hive_metastore.migrate_e1qqa.ucx_tfnce given migration statuses Row(src_schema='migrate_e1qqa', src_table='ucx_tksdz', dst_catalog='ucx_c1zcx', dst_schema='migrate_e1qqa', dst_table='ucx_tksdz', update_ts='1719909569.860524') (24m2.578s)❌ test_hiveserde_table_ctas_migration_job[hiveserde]: AssertionError: assert False (11m38.384s)Running from acceptance #4094 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
This PR is stacked on #1943; it is stacked to verify the type hinting changes via the CI environment.
The situation is:
The Databricks SDK has partially implemented type hints for the credentials handlers.
The
CredentialsProvideris the fundamental type for a callable factory that can be used to obtain credentials.The
CredentialsStrategyis the type that can be used for a function that can be used to obtain a provider, given theConfig.The
@credentials_strategydecorator is used to fuse the two:Config, returns aCredentialsProvider.CredentialsStrategy.The type upstream type hinting for the
@credentials_strategydecorator is incomplete: the return type is omitted. This confuses IntelliJ/PyCharm a little but not Mypy.