wjddn279 commented on code in PR #65127:
URL: https://github.com/apache/airflow/pull/65127#discussion_r3073310191
##########
airflow-core/src/airflow/settings.py:
##########
@@ -434,6 +434,12 @@ def configure_orm(disable_connection_pool=False,
pool_class=None):
# Skip DB initialization in unit tests, if DB tests are skipped
Session = SkipDBTestsSession
engine = None
+
+ # Ensure all models are imported so SQLAlchemy can resolve
string-based relationships in tests.
+ from airflow.models import import_all_models
+
+ import_all_models()
Review Comment:
I tried the approach you suggested, but the same error I encountered still
occurs.
Would you like to try it yourself?
run into shell by executing
```
breeze shell --skip-db-tests --backend none
```
and do test what i did
```
airflow-core/tests/unit/serialization --verbosity=0 --strict-markers
--durations=100 --maxfail=50 --color=yes
--junitxml=/files/test_result-all-none.xml --timeouts-order=moi
--setup-timeout=60 --execution-timeout=60 --teardown-timeout=60
--disable-warnings -rfEX --skip-db-tests --ignore-glob=*/tests/system/*
--ignore-glob=airflow-core/tests/integration/*
--ignore-glob=providers/apache/cassandra/tests/integration/*
--ignore-glob=providers/apache/drill/tests/integration/*
--ignore-glob=providers/apache/hive/tests/integration/*
--ignore-glob=providers/apache/kafka/tests/integration/*
--ignore-glob=providers/apache/pinot/tests/integration/*
--ignore-glob=providers/apache/tinkerpop/tests/integration/*
--ignore-glob=providers/celery/tests/integration/*
--ignore-glob=providers/elasticsearch/tests/integration/*
--ignore-glob=providers/google/tests/integration/*
--ignore-glob=providers/microsoft/mssql/tests/integration/*
--ignore-glob=providers/mongo/tests/integration/* --ignore-glob=provi
ders/openlineage/tests/integration/*
--ignore-glob=providers/opensearch/tests/integration/*
--ignore-glob=providers/qdrant/tests/integration/*
--ignore-glob=providers/redis/tests/integration/*
--ignore-glob=providers/trino/tests/integration/*
--ignore-glob=providers/ydb/tests/integration/*
--warning-output-path=/files/warnings-all-none.txt --ignore=helm-tests
--with-db-init --ignore=providers/apache/beam/tests -n 4 --no-cov
--no-db-cleanup
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]