Skip to content
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

Limit azure-cosmos<4.6.0 #38175

Merged
merged 1 commit into from
Mar 15, 2024
Merged

Limit azure-cosmos<4.6.0 #38175

merged 1 commit into from
Mar 15, 2024

Conversation

eladkal
Copy link
Contributor

@eladkal eladkal commented Mar 15, 2024

azure-cosmos version 4.6.0 released today and it breaks mypy

airflow/providers/microsoft/azure/hooks/cosmos.py:228: error: Argument
"partition_key" to "create_container" of "DatabaseProxy" has incompatible type
"Optional[str]"; expected "PartitionKey"  [arg-type]
                    collection_name, partition_key=partition_key
                                                   ^~~~~~~~~~~~~
airflow/providers/microsoft/azure/hooks/cosmos.py:339: error: Argument
"partition_key" to "delete_item" of "ContainerProxy" has incompatible type
"Optional[str]"; expected
"Union[str, int, float, bool, Sequence[Union[str, int, float, bool, None]], Type[NonePartitionKeyValue]]"
 [arg-type]
                .delete_item(document_id, partition_key=partition_key)
                                                        ^~~~~~~~~~~~~
airflow/providers/microsoft/azure/hooks/cosmos.py:358: error: Argument
"partition_key" to "read_item" of "ContainerProxy" has incompatible type
"Optional[str]"; expected
"Union[str, int, float, bool, Sequence[Union[str, int, float, bool, None]], Type[NonePartitionKeyValue]]"
 [arg-type]
                    .read_item(document_id, partition_key=partition_key)
                                                          ^~~~~~~~~~~~~
Found 3 errors in 1 file (checked [122](https://github.com/apache/airflow/actions/runs/8291950812/job/22692722738?pr=38048#step:6:123)8 source files)
Error 1 returned

@eladkal eladkal changed the title Limit azure-cosmos Limit azure-cosmos<4.6.0 Mar 15, 2024
@eladkal eladkal merged commit 832571c into apache:main Mar 15, 2024
21 checks passed
@eladkal eladkal deleted the azure branch March 15, 2024 10:50
@ephraimbuddy ephraimbuddy added the changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) label Mar 18, 2024
@potiuk potiuk added this to the Airflow 2.8.4 milestone Mar 19, 2024
potiuk pushed a commit that referenced this pull request Mar 19, 2024
(cherry picked from commit 832571c)
utkarsharma2 pushed a commit to astronomer/airflow that referenced this pull request Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:providers changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) provider:microsoft-azure Azure-related issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants