Conversation
18c4f09 to
9eded3a
Compare
33ee1e2 to
e70f3be
Compare
e70f3be to
13b23c1
Compare
e22fea0 to
9dde463
Compare
There was a problem hiding this comment.
Why are we using LazyXComSelectSequence instead of LazyXComAccess?
I'm seeing this error when I run make sm2a-local-init 😯
(editing to share error message!)
INFO [alembic.runtime.migration] Context impl PostgresqlImpl.
INFO [alembic.runtime.migration] Will assume transactional DDL.
ERROR [airflow.models.dagbag.DagBag] Failed to import: /opt/airflow/dags/generate_dags.py
Traceback (most recent call last):
File "/home/airflow/.local/lib/python3.11/site-packages/airflow/models/dagbag.py", line 346, in parse
loader.exec_module(new_module)
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/airflow/dags/generate_dags.py", line 9, in <module>
from veda_data_pipeline.veda_discover_pipeline import get_discover_dag
File "/opt/airflow/dags/veda_data_pipeline/veda_discover_pipeline.py", line 6, in <module>
from veda_data_pipeline.groups.discover_group import discover_from_s3_task, get_files_task
File "/opt/airflow/dags/veda_data_pipeline/groups/discover_group.py", line 7, in <module>
from airflow.models.xcom import LazyXComSelectSequence
ImportError: cannot import name 'LazyXComSelectSequence' from 'airflow.models.xcom' (/home/airflow/.local/lib/python3.11/site-packages/airflow/models/xcom.py)
/home/airflow/.local/lib/python3.11/site-packages/airflow_multi_dagrun/operators.py:3 DeprecationWarning: This module is deprecated. Please use `airflow.api.common.trigger_dag` instead.
ERROR [airflow.models.dagbag.DagBag] Failed to import: /opt/airflow/dags/veda_data_pipeline/veda_promotion_pipeline.py
Traceback (most recent call last):
File "/home/airflow/.local/lib/python3.11/site-packages/airflow/models/dagbag.py", line 346, in parse
loader.exec_module(new_module)
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/airflow/dags/veda_data_pipeline/veda_promotion_pipeline.py", line 10, in <module>
from veda_data_pipeline.groups.discover_group import discover_from_s3_task, get_dataset_files_to_process
File "/opt/airflow/dags/veda_data_pipeline/groups/discover_group.py", line 7, in <module>
from airflow.models.xcom import LazyXComSelectSequence
ImportError: cannot import name 'LazyXComSelectSequence' from 'airflow.models.xcom' (/home/airflow/.local/lib/python3.11/site-packages/airflow/models/xcom.py)
ERROR [airflow.models.dagbag.DagBag] Failed to import: /opt/airflow/dags/veda_data_pipeline/veda_vector_pipeline.py
Traceback (most recent call last):
File "/home/airflow/.local/lib/python3.11/site-packages/airflow/models/dagbag.py", line 346, in parse
loader.exec_module(new_module)
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/airflow/dags/veda_data_pipeline/veda_vector_pipeline.py", line 9, in <module>
from veda_data_pipeline.groups.discover_group import discover_from_s3_task, get_files_task
File "/opt/airflow/dags/veda_data_pipeline/groups/discover_group.py", line 7, in <module>
from airflow.models.xcom import LazyXComSelectSequence
ImportError: cannot import name 'LazyXComSelectSequence' from 'airflow.models.xcom' (/home/airflow/.local/lib/python3.11/site-packages/airflow/models/xcom.py)
ERROR [airflow.models.dagbag.DagBag] Failed to import: /opt/airflow/dags/veda_data_pipeline/veda_dataset_pipeline.py
Traceback (most recent call last):
File "/home/airflow/.local/lib/python3.11/site-packages/airflow/models/dagbag.py", line 346, in parse
loader.exec_module(new_module)
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/airflow/dags/veda_data_pipeline/veda_dataset_pipeline.py", line 4, in <module>
from veda_data_pipeline.groups.discover_group import discover_from_s3_task, get_files_task
File "/opt/airflow/dags/veda_data_pipeline/groups/discover_group.py", line 7, in <module>
from airflow.models.xcom import LazyXComSelectSequence
ImportError: cannot import name 'LazyXComSelectSequence' from 'airflow.models.xcom' (/home/airflow/.local/lib/python3.11/site-packages/airflow/models/xcom.py)
ERROR [airflow.models.dagbag.DagBag] Failed to import: /opt/airflow/dags/veda_data_pipeline/veda_discover_pipeline.py
Traceback (most recent call last):
File "/home/airflow/.local/lib/python3.11/site-packages/airflow/models/dagbag.py", line 346, in parse
loader.exec_module(new_module)
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/airflow/dags/veda_data_pipeline/veda_discover_pipeline.py", line 6, in <module>
from veda_data_pipeline.groups.discover_group import discover_from_s3_task, get_files_task
File "/opt/airflow/dags/veda_data_pipeline/groups/discover_group.py", line 7, in <module>
from airflow.models.xcom import LazyXComSelectSequence
ImportError: cannot import name 'LazyXComSelectSequence' from 'airflow.models.xcom' (/home/airflow/.local/lib/python3.11/site-packages/airflow/models/xcom.py)
/home/airflow/.local/lib/python3.11/site-packages/airflow/utils/db.py:741 DeprecationWarning: The load_default_connections option in [core] has been moved to the load_default_connections option in [database] - the old setting has been used, but please update your config.
I wasn't able to reproduce this error, but I've seen similar errors caused by version mismatches. The LazyXCom models were renamed between Airflow 2.8 and 2.10. Could you try running |
With Maybe this is an issue I am experiencing personally from having an incorrect python version or something 🤔 Which version are you using @ividito ? |
|
My I'm a bit stumped on how to debug this if it's not a docker version issue. I tried a fresh build with no caching, and still didn't run into any errors. |
c7d2b6f to
b1bc512
Compare
- remove schedule on stactools DAGs - fix SIT deployment
b1bc512 to
037e416
Compare
Summary:
Airflow (+related libraries) version upgrade. This prompted some other changes and improvements, as several things broke with the updated libraries.
LazyXcomAccess->LazyXcomSequenceManual step required to make deployment work with new version -python scripts/run_task.py --vpc-id vpc-xxx --security-group xxx --task-definition xxx --cluster xxx--command 'db init'^ No longer applies, instead we must set the
airflow_versionvariable for SM2A - NASA-IMPACT/self-managed-apache-airflow#23Testing/action items
veda-dataset-pipelineveda-vector-pipeline- works, but SIT cannot connect to dev features DB to submit generated items