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 2020/11/27 10:58:00 UTC

[GitHub] [airflow] dromcre opened a new issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

dromcre opened a new issue #12651:
URL: https://github.com/apache/airflow/issues/12651


   **Apache Airflow version**:
   
   Airflow version: 2.0.0b3
   
   
   **What happened**:
   
   Something bad has happened.
   Please consider letting us know by creating a bug report using GitHub.
   
   Python version: 3.6.8
   Airflow version: 2.0.0b3
   
   -------------------------------------------------------------------------------
   Traceback (most recent call last):
     File "/usr/lib/python3.6/site-packages/flask/app.py", line 2447, in wsgi_app
       response = self.full_dispatch_request()
     File "/usr/lib/python3.6/site-packages/flask/app.py", line 1952, in full_dispatch_request
       rv = self.handle_user_exception(e)
     File "/usr/lib/python3.6/site-packages/flask/app.py", line 1821, in handle_user_exception
       reraise(exc_type, exc_value, tb)
     File "/usr/lib/python3.6/site-packages/flask/_compat.py", line 39, in reraise
       raise value
     File "/usr/lib/python3.6/site-packages/flask/app.py", line 1950, in full_dispatch_request
       rv = self.dispatch_request()
     File "/usr/lib/python3.6/site-packages/flask/app.py", line 1936, in dispatch_request
       return self.view_functions[rule.endpoint](**req.view_args)
     File "/usr/lib/python3.6/site-packages/airflow/www/auth.py", line 34, in decorated
       return func(*args, **kwargs)
     File "/usr/lib/python3.6/site-packages/airflow/www/views.py", line 575, in index
       tags_filter=arg_tags_filter,
     File "/usr/lib/python3.6/site-packages/airflow/www/views.py", line 387, in render_template
       **kwargs,
     File "/usr/lib/python3.6/site-packages/flask_appbuilder/baseviews.py", line 281, in render_template
       template, **dict(list(kwargs.items()) + list(self.extra_args.items()))
     File "/usr/lib/python3.6/site-packages/flask/templating.py", line 140, in render_template
       ctx.app,
     File "/usr/lib/python3.6/site-packages/flask/templating.py", line 120, in _render
       rv = template.render(context)
     File "/usr/lib/python3.6/site-packages/jinja2/environment.py", line 1090, in render
       self.environment.handle_exception()
     File "/usr/lib/python3.6/site-packages/jinja2/environment.py", line 832, in handle_exception
       reraise(*rewrite_traceback_stack(source=source))
     File "/usr/lib/python3.6/site-packages/jinja2/_compat.py", line 28, in reraise
       raise value.with_traceback(tb)
     File "/usr/lib/python3.6/site-packages/airflow/www/templates/airflow/dags.html", line 21, in top-level template code
       {% from 'appbuilder/loading_dots.html' import loading_dots %}
     File "/usr/lib/python3.6/site-packages/airflow/www/templates/airflow/master.html", line 20, in top-level template code
       {% extends 'appbuilder/baselayout.html' %}
     File "/usr/lib/python3.6/site-packages/flask_appbuilder/templates/appbuilder/baselayout.html", line 2, in top-level template code
       {% import 'appbuilder/baselib.html' as baselib %}
     File "/usr/lib/python3.6/site-packages/flask_appbuilder/templates/appbuilder/init.html", line 46, in top-level template code
       {% block body %}
     File "/usr/lib/python3.6/site-packages/flask_appbuilder/templates/appbuilder/baselayout.html", line 16, in block "body"
       {% block messages %}
     File "/usr/lib/python3.6/site-packages/airflow/www/templates/airflow/master.html", line 54, in block "messages"
       >{{ macros.datetime_diff_for_humans(scheduler_job.latest_heartbeat) }}</time>.
     File "/usr/lib/python3.6/site-packages/airflow/macros/__init__.py", line 83, in datetime_diff_for_humans
       return pendulum.instance(dt).diff_for_humans(since)
     File "/usr/lib/python3.6/site-packages/pendulum/datetime.py", line 824, in diff_for_humans
       other = self.now()
     File "/usr/lib/python3.6/site-packages/pendulum/datetime.py", line 106, in now
       return pendulum.now(tz)
     File "/usr/lib/python3.6/site-packages/pendulum/__init__.py", line 211, in now
       dt = _datetime.datetime.now(local_timezone())
     File "/usr/lib/python3.6/site-packages/pendulum/tz/__init__.py", line 60, in local_timezone
       return get_local_timezone()
     File "/usr/lib/python3.6/site-packages/pendulum/tz/local_timezone.py", line 35, in get_local_timezone
       tz = _get_system_timezone()
     File "/usr/lib/python3.6/site-packages/pendulum/tz/local_timezone.py", line 63, in _get_system_timezone
       return _get_unix_timezone()
     File "/usr/lib/python3.6/site-packages/pendulum/tz/local_timezone.py", line 242, in _get_unix_timezone
       raise RuntimeError("Unable to find any timezone configuration")
   RuntimeError: Unable to find any timezone configuration
   
   **How to reproduce it**:
   
   Enter in webserver and launch manual execution.
   1000 dags with 100 in on with scheduler "* * * * *"
   
   
   


----------------------------------------------------------------
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.

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



[GitHub] [airflow] ashb commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
ashb commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-735291484


   Sounds like you need to set `TZ=UTC` in your docker container then.


----------------------------------------------------------------
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.

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



[GitHub] [airflow] dromcre commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
dromcre commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-734927203


   **Scheduler with Core Executor = LocalExecutor.**
   
   AIRFLOW__CORE__LOAD_DEFAULT_CONNECTIONS=False
   AIRFLOW__CORE__DAGS_FOLDER="$AIRFLOW_FOLDER/dags"
   AIRFLOW__CORE__PLUGINS_FOLDER="$AIRFLOW_HOME/plugins"
   AIRFLOW__CORE__EXECUTOR="LocalExecutor"
   AIRFLOW__CORE__PARALELLISM=50
   AIRFLOW__CORE__DAG_CONCURRENCY=100
   AIRFLOW__CORE__MAX_ACTIVE_RUNS_PER_DAG=100
   AIRFLOW__CORE__DAGS_ARE_PAUSED_AT_CREATION=True
   AIRFLOW__CORE__LOAD_EXAMPLES=False
   AIRFLOW__CORE__ENABLE_XCOM_PICKLING=True
   AIRFLOW__CORE__LAZY_LOAD_PLUGINS=False
   AIRFLOW__CORE__STORE_SERIALIZED_DAGS=True
   AIRFLOW__CORE__STORE_DAG_CODE=True
   AIRFLOW__CORE__MIN_SERIALIZED_DAG_UPDATE_INTERVAL=30
   AIRFLOW__CORE__MIN_SERIALIZED_DAG_FETCH_INTERVAL=10
   AIRFLOW__CLI__API_CLIENT="airflow.api.client.json_client"
   AIRFLOW__WEBSERVER__WEB_SERVER_PORT=8081
   AIRFLOW__WEBSERVER__WORKER_REFRESH_BATCH_SIZE=5
   AIRFLOW__WEBSERVER__WORKERS=10
   AIRFLOW__WEBSERVER__WORKER_CLASS="gevent"
   AIRFLOW__WEBSERVER__EXPOSE_CONFIG=True
   AIRFLOW__WEBSERVER__AUTHENTICATE=True
   AIRFLOW__WEBSERVER__AUTH_BACKEND="airflow.contrib.auth.backends.password_auth"
   AIRFLOW__WEBSERVER__LOG_FETCH_TIMEOUT_SEC=10
   AIRFLOW__WEBSERVER__HIDE_PAUSED_DAGS_BY_DEFAULT=True
   AIRFLOW__WEBSERVER__CHILD_PROCESS_LOG_DIRECTORY=$AIRFLOW__LOGGING__BASE_LOG_FOLDER"/webserver"
   AIRFLOW__SCHEDULER__MAX_THREADS=6
   AIRFLOW__SCHEDULER__POOL="gevent"
   AIRFLOW__SCHEDULER__SCHEDULER_HEARTBEAT_SEC=10
   AIRFLOW__SCHEDULER__DAG_DIR_LIST_INTERVAL=300
   AIRFLOW__SCHEDULER__CHILD_PROCESS_LOG_DIRECTORY=$AIRFLOW__LOGGING__BASE_LOG_FOLDER"/scheduler"
   AIRFLOW__RBAC=True


----------------------------------------------------------------
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.

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



[GitHub] [airflow] dromcre commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
dromcre commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-734932800


   i found a similiar issue: https://issuehunt.io/r/miracle2k/k8s-snapshots/issues/83
   
   In my case, i run webserver and scheduler in two pods. 
   
   Docker:
   FROM alpine:3.6
   


----------------------------------------------------------------
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.

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



[GitHub] [airflow] ashb closed issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

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


   


----------------------------------------------------------------
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.

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



[GitHub] [airflow] kaxil commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
kaxil commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-734906130


   @dromcre Can you expand a bit more on `1000 dags with 100 in on with scheduler "* * * * *"` !
   
   Can you post at least one of your DAGs


----------------------------------------------------------------
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.

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



[GitHub] [airflow] dromcre commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
dromcre commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-734926182


   Attach zip with 300 dags.
   
   [dags.zip](https://github.com/apache/airflow/files/5608984/dags.zip)
   


----------------------------------------------------------------
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.

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



[GitHub] [airflow] boring-cyborg[bot] commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

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


   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.

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



[GitHub] [airflow] ashb commented on issue #12651: Webserver error - RuntimeError: Unable to find any timezone configuration

Posted by GitBox <gi...@apache.org>.
ashb commented on issue #12651:
URL: https://github.com/apache/airflow/issues/12651#issuecomment-735291515


   The number of dags should be unrelated to this bug.


----------------------------------------------------------------
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.

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