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

[AIRFLOW-3709] Validate allowed_states for ExternalTaskSensor #4536

Merged
merged 1 commit into from
Jan 15, 2019

Conversation

XD-DENG
Copy link
Member

@XD-DENG XD-DENG commented Jan 15, 2019

Jira

Description

In ExternalTaskSensor, we can specify allowed_states. This commit adds validation for it, so that users will not specify any invalid state (by accident).

This change works no matter the sensor waits for a DAG (available since 2a8c91b) or a specific task.

Tests

  • My PR adds the following unit tests OR does not need testing for this extremely good reason:

Tests are added.

In ExternalTaskSensor, we can specify `allowed_states`.
This commit adds validation for it, so that users will not
specify any invalid state.

This change works no matter the sensor waits for a DAG or
a specific task.
@codecov-io
Copy link

Codecov Report

Merging #4536 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #4536      +/-   ##
==========================================
+ Coverage   74.02%   74.02%   +<.01%     
==========================================
  Files         421      421              
  Lines       27644    27649       +5     
==========================================
+ Hits        20463    20467       +4     
- Misses       7181     7182       +1
Impacted Files Coverage Δ
airflow/sensors/external_task_sensor.py 97.5% <100%> (+0.35%) ⬆️
airflow/models/__init__.py 92.13% <0%> (-0.05%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fc440dc...1dc64d3. Read the comment docs.

@ashb ashb merged commit 98982c7 into apache:master Jan 15, 2019
@XD-DENG XD-DENG deleted the refine_ExternalTaskSensor branch January 17, 2019 23:54
ashb pushed a commit to ashb/airflow that referenced this pull request Mar 5, 2019
…he#4536)

In ExternalTaskSensor, we can specify `allowed_states`.
This commit adds validation for it, so that users will not
specify any invalid state.

This change works no matter the sensor waits for a DAG or
a specific task.
wmorris75 pushed a commit to modmed/incubator-airflow that referenced this pull request Jul 29, 2019
…he#4536)

In ExternalTaskSensor, we can specify `allowed_states`.
This commit adds validation for it, so that users will not
specify any invalid state.

This change works no matter the sensor waits for a DAG or
a specific task.
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