Skip to content

Update mwaddlink tags collection to list type

Fix to a very minor issue, that has been causing issues with pytest, error:

Traceback (most recent call last):
  File "/home/kcvelaga/anaconda3/envs/airflow-dags/lib/python3.10/site-packages/airflow/models/dagbag.py", line 383, in parse
    loader.exec_module(new_module)
  File "<frozen importlib._bootstrap_external>", line 883, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/kcvelaga/Desktop/GIT/wmf_git/airflow-dags-fork-kcv/research/dags/mwaddlink_dag.py", line 131, in <module>
    with DAG(
  File "/home/kcvelaga/anaconda3/envs/airflow-dags/lib/python3.10/site-packages/airflow/models/dag.py", line 789, in __init__
    validate_instance_args(self, DAG_ARGS_EXPECTED_TYPES)
  File "/home/kcvelaga/anaconda3/envs/airflow-dags/lib/python3.10/site-packages/airflow/utils/helpers.py", line 68, in validate_instance_args
    raise TypeError(
TypeError: 'tags' has an invalid type <class 'tuple'> with value ('research', 'mwaddlink', 'from_hive', 'from_hdfs', 'to_hdfs', 'uses_spark'), expected type is <class 'list'>

and when I try to re-build fixtures using

find tests -name \*.expected -exec rm '{}' \;
REBUILD_FIXTURES=yes pytest

I am having to manually restore the fixtures, as they weren't getting regenerated due to above mentioned error.

Edited by KCVelaga

Merge request reports