question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres'

See original GitHub issue

Apache Airflow version: 2.0.1

Environment:

  • Cloud provider or hardware configuration: MacBook Pro
  • OS (e.g. from /etc/os-release): Catalina 10.15.7
  • Kernel (e.g. uname -a): Darwin CSchillebeeckx-0589.local 19.6.0 Darwin Kernel Version 19.6.0: Thu Oct 29 22:56:45 PDT 2020; root:xnu-6153.141.2.2~1/RELEASE_X86_64 x86_64
  • Install tools: pip

requirements.txt

apache-airflow[crypto,celery,amazon,mysql,jdbc,password,redis,slack,snowflake,ssh,google,databricks,mongo,zendesk,papermill,salesforce]==2.0.1
pyarrow==0.17.1
iniconfig==1.1.1
sqlparse==0.4.1
google-api-python-client===1.12.8
google-auth==1.27.0
google-api-core==1.26.0
avro-python3==1.10.0
databricks-connect==7.3.8
matplotlib==3.3.4
scikit-learn==0.24.1
ipykernel==5.4.3
flower==0.9.7

What happened:

I’m using MySQL as a backend and am using the GoogleBaseHook; when I run the webserver I see:

webserver_1  | [2021-02-16 23:39:13,008] {providers_manager.py:299} WARNING - Exception when importing 'airflow.providers.google.cloud.hooks.cloud_sql.CloudSQLHook' from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres'
webserver_1  | [2021-02-16 23:39:13,009] {providers_manager.py:299} WARNING - Exception when importing 'airflow.providers.google.cloud.hooks.cloud_sql.CloudSQLDatabaseHook' from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres'
webserver_1  | [2021-02-16 23:39:13,066] {providers_manager.py:299} WARNING - Exception when importing 'airflow.providers.google.cloud.hooks.cloud_sql.CloudSQLHook' from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres'
webserver_1  | [2021-02-16 23:39:13,067] {providers_manager.py:299} WARNING - Exception when importing 'airflow.providers.google.cloud.hooks.cloud_sql.CloudSQLDatabaseHook' from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres'

If I add the extra package postgres the warnings are not present anymore.

What you expected to happen:

No warnings

How to reproduce it:

Anything else we need to know:

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:27 (21 by maintainers)

github_iconTop GitHub Comments

2reactions
OBITORASUcommented, Feb 19, 2021

I guess I will wait until this is investigated further then.

1reaction
potiukcommented, Mar 19, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

apache-airflow-providers-postgres Documentation
This is a provider package for postgres provider. All classes for this provider package are in airflow.providers.postgres python package.
Read more >
How to import Airflow's PostgresOperator - Stack Overflow
The solution was to run the following in the terminal, using the project's virtualenv: pip install 'apache-airflow[postgres]' .
Read more >
apache-airflow-providers-google 8.6.0 - PyPI
This is a provider package for google provider. All classes for this provider package are in airflow.providers.google python package. You can find package...
Read more >
Appendix B Package structures Airflow 1 and 2
Many modules were removed from the core Airflow, and are now installed via a separate ... Vbsc desproirv cagapke jz damne apache-airflow-providers-[name] ...
Read more >
from 'apache-airflow-providers-google' package: No module ...
CloudSQLHook' from 'apache-airflow-providers-google' package: No module named 'airflow.providers.postgres' webserver_1 | [2021-02-16 ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found