-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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-6706] Lazy load operator extra links (#7327) #10318
Conversation
732f732
to
9cc758e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When I was thinking about it, I preserved the old serialization the old way and new serialization the new way. But adding old here is much better.
I tested it with: # bq.py
from airflow.models import BaseOperatorLink
class BigQueryConsoleLink(BaseOperatorLink):
name = 'BigQuery Console'
def get_link(self, operator, dttm):
return "teees" and DAG: class CustomOp(DummyOperator):
@property
def operator_extra_links(self):
return (BigQueryConsoleLink(),)
with DAG("example_link",
schedule_interval=None, # Override to match your needs
start_date=days_ago(1),
) as dag:
task = CustomOp(task_id="task_withlink") I added |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
SHll we un-draft and rerun it ? |
9cc758e
to
d08608e
Compare
airflow/plugins_manager.py:118:1: E303 too many blank lines (3) |
d08608e
to
b2ca4cf
Compare
Co-authored-by: Kamil Breguła <[email protected]> Backported from #7327 cherry-picked from b180e4b
Co-authored-by: Kamil Breguła <[email protected]> Backported from apache#7327 cherry-picked from b180e4b
closes: #10171
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code change, Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in UPDATING.md.