gpt4 book ai didi

db init 后的 Airflow 2.0 警告

转载 作者:行者123 更新时间:2023-12-05 06:54:40 27 4
gpt4 key购买 nike

我使用 pip 命令在 ubuntu 上部署了 Airflow 2.0。已从 1.10.13 迁移到 2.0。但是在 db inint 之后,我收到了以下警告。请建议我为什么会收到这些警告。我尝试运行示例 dags,它们成功运行。

WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-http' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-sqlite' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-imap' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-ftp' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-http' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-sqlite' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-imap' could not be registered from because providers for that package name have already been registered
WARNI [airflow.providers_manager] The provider for package 'apache-airflow-providers-ftp' could not be registered from because providers for that package name have already been registered

最佳答案

我认为您有一种安装方式,您在 PYTHONPATH 中同时安装了“提供程序包”和带有提供程序源代码的 Airflow。我猜你是从带有 -e 标志的源安装 Airflow 而不是从 PyPI 包安装的,在这种情况下你会收到这些警告。

顺便说一句。这些警告将在 2.0.1 中消失 https://github.com/apache/airflow/commit/18df31d5d451299c510a9bf11946f17471f1e573

警告是无害的 - 但是作为包安装的提供程序未被使用(来自 Airflow 源的提供程序是)。

它的根本原因是如果你想从源代码安装 Airflow 作为可编辑安装(基本上当你想为 Airflow 做贡献时)你应该将 INSTALL_PROVIDERS_FROM_SOURCES 变量设置为 true 在安装 Airflow 之前(请参阅 https://github.com/apache/airflow/blob/master/CONTRIBUTING.rst#provider-packages)- 这样您就不会从 PyPI 安装提供程序包。

关于db init 后的 Airflow 2.0 警告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65476450/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com