Skip to content

Conversation

@sumeshpremraj
Copy link
Contributor

@sumeshpremraj sumeshpremraj commented Jul 6, 2023

This fixes the header value passed into the HttpAsyncHook and adds a test, and uses a backport of unittest.mock for AsyncMock usage in Python 3.7.

closes: #32390
replaces: #31010

setup.cfg Outdated
markupsafe>=1.1.1
marshmallow-oneofschema>=2.0.1
mdit-py-plugins>=0.3.0
mock>=5.0.2;python_version<="3.7"
Copy link
Contributor

@eladkal eladkal Jul 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We dont support Python 3.7 any longer.
If you check the test suite you will see it tests against 3.8 - 3.11

Where did you notice failure related to Python 3.7?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the stale PR https://github.com/apache/airflow/actions/runs/4885483415/jobs/8719703717?pr=31010
I understand Py 3.7 support will be dropped only in the next Airflow release, but I didn't realize the test suites have already dropped it, sorry about that.

I've reverted the Py 3.7 related changes.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is provider code :)
You can see in the change log that we already dropped support
https://airflow.apache.org/docs/apache-airflow-providers-github/stable/index.html#id1

Python 3.7 is relevant only for Airflow 2.6 releases

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah TIL, this is my first time contributing to Airflow, I've only been a user until now.
Thanks for the review 😄

@sumeshpremraj sumeshpremraj marked this pull request as ready for review July 6, 2023 19:33
@potiuk potiuk merged commit 358e6e8 into apache:main Jul 6, 2023
@sumeshpremraj sumeshpremraj deleted the spremraj/fix-HttpAsyncHook-headers branch July 6, 2023 21:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix HttpAsyncHook headers

3 participants