Skip to content

Instantly share code, notes, and snippets.

@tszumowski
Created March 19, 2019 12:50
Show Gist options
  • Save tszumowski/49c5058371c697c4920d2421c6eb61be to your computer and use it in GitHub Desktop.
Save tszumowski/49c5058371c697c4920d2421c6eb61be to your computer and use it in GitHub Desktop.
airflow warning of removing args/kwargs
if args or kwargs:
# TODO remove *args and **kwargs in Airflow 2.0
warnings.warn(
'Invalid arguments were passed to {c} (task_id: {t}). '
'Support for passing such arguments will be dropped in '
'Airflow 2.0. Invalid arguments were:'
'\n*args: {a}\n**kwargs: {k}'.format(
c=self.__class__.__name__, a=args, k=kwargs, t=task_id),
category=PendingDeprecationWarning,
stacklevel=3
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment