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

Improved compatibility with Python 3.5+ - Convert signal.SIGTERM to int #9207

Merged
merged 1 commit into from
Jun 10, 2020

Conversation

phill84
Copy link
Contributor

@phill84 phill84 commented Jun 10, 2020

Solves the issue #9202

File changed: airflow/utils/process_utils.py

Problem
Since python3.5, signals have become IntEnum instead of int, therefore str(signal.SIGTERM) yields the string literal signal.SIGTERM instead of 15.

Solution
convert signal.SIGTERM to int first and then str

  • Description above provides context of the change
  • Unit tests coverage for changes (not needed for documentation changes)
  • Target Github ISSUE in description if exists
  • Commits follow "How to write a good git commit message"
  • Relevant documentation is updated including usage instructions. unnecessary
  • I will engage committers as explained in Contribution Workflow Example.

@boring-cyborg
Copy link

boring-cyborg bot commented Jun 10, 2020

Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contribution Guide (https://github.com/apache/airflow/blob/master/CONTRIBUTING.rst)
Here are some useful points:

  • Pay attention to the quality of your code (flake8, pylint and type annotations). Our pre-commits will help you with that.
  • In case of a new feature add useful documentation (in docstrings or in docs/ directory). Adding a new operator? Check this short guide Consider adding an example DAG that shows how users should use it.
  • Consider using Breeze environment for testing locally, it’s a heavy docker but it ships with a working Airflow and a lot of integrations.
  • Be patient and persistent. It might take some time to get a review or get the final approval from Committers.
  • Be sure to read the Airflow Coding style.
    Apache Airflow is a community-driven project and together we are making it better 🚀.
    In case of doubts contact the developers at:
    Mailing List: [email protected]
    Slack: https://apache-airflow-slack.herokuapp.com/

@mik-laj mik-laj changed the title fix kill signal on python3 Improved compatibility with Python 3.5+ - Convert signal.SIGTERM to int Jun 10, 2020
@mik-laj mik-laj merged commit 1cf52da into apache:master Jun 10, 2020
@boring-cyborg
Copy link

boring-cyborg bot commented Jun 10, 2020

Awesome work, congrats on your first merged pull request!

@mik-laj
Copy link
Member

mik-laj commented Jun 10, 2020

@phill84 I'm glad you decided to contribute to this project. What are your plans? Anything else you would like to improve in the project?

@phill84
Copy link
Contributor Author

phill84 commented Jun 10, 2020

@mik-laj Thanks for helping get this fix merged! I am usually a couple minors behind the latest release, so this is actually the first bug I found that hasn't been fixed in master. Let's hope that I won't open new PR's too soon or often, at least for time being. 😸

@ashb ashb added this to the Airflow 1.10.11 milestone Jun 10, 2020
potiuk pushed a commit that referenced this pull request Jun 20, 2020
… int (#9207)

Co-authored-by: Jiening Wen <[email protected]>
(cherry picked from commit 1cf52da)
potiuk pushed a commit that referenced this pull request Jun 29, 2020
… int (#9207)

Co-authored-by: Jiening Wen <[email protected]>
(cherry picked from commit 1cf52da)
kaxil pushed a commit that referenced this pull request Jul 1, 2020
… int (#9207)

Co-authored-by: Jiening Wen <[email protected]>
(cherry picked from commit 1cf52da)
cfei18 pushed a commit to cfei18/incubator-airflow that referenced this pull request Mar 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants