You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/08/19 05:39:44 UTC

[GitHub] [airflow] ezerkar opened a new issue #17714: dag import error when using sys.path.append(str(Path('.').absolute().parent))

ezerkar opened a new issue #17714:
URL: https://github.com/apache/airflow/issues/17714


   <!--
   Welcome to Apache Airflow!
   
   Please complete the next sections or the issue will be closed.
   -->
   
   **Apache Airflow version**:
   
   v2.1.2
   
   **OS**:
   
   Ubuntu 20.04.1 LTS 
   
   **Deployment**:
   
   local
   
   **What happened**:
   
   have a file in a parent directory I want to import from, so did this:
   ```
   import sys
   from pathlib import Path
   sys.path.append(str(Path('.').absolute().parent))
   from get_data_functions import *
   ```
   this seem to be working in general python but airflow gives out a DAG import error:
   `ModuleNotFoundError: No module named 'get_data_functions'`
   
   
   **Are you willing to submit a PR?**
   No idea how to fix this, but if you give me some hints I could try
   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] potiuk closed issue #17714: dag import error when using sys.path.append(str(Path('.').absolute().parent))

Posted by GitBox <gi...@apache.org>.
potiuk closed issue #17714:
URL: https://github.com/apache/airflow/issues/17714


   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] boring-cyborg[bot] commented on issue #17714: dag import error when using sys.path.append(str(Path('.').absolute().parent))

Posted by GitBox <gi...@apache.org>.
boring-cyborg[bot] commented on issue #17714:
URL: https://github.com/apache/airflow/issues/17714#issuecomment-901625952


   Thanks for opening your first issue here! Be sure to follow the issue template!
   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org