Title
w

Wilson Bilkovich

08/29/2021, 4:43 PM
Anybody seen this error before? I’m getting it in the prefect job pods that get spun up:
RuntimeError: Unable to find any timezone configuration
Successfully installed PyGithub-1.55 aiohttp-3.7.4.post0 async-timeout-3.0.1 attrs-21.2.0 cachetools-4.2.2 click-7.1.2 croniter-0.3.37 dask-kubernetes-2021.3.1 deprecated-1.2.12 docker-5.0.0 google-auth-2.0.1 idna-2.10 kubernetes-12.0.1 kubernetes-asyncio-12.1.2 marshmallow-3.13.0 marshmallow-oneofschema-3.0.1 multidict-5.1.0 mypy-extensions-0.4.3 natsort-7.1.1 oauthlib-3.1.1 pendulum-2.1.2 prefect-0.15.4 pyasn1-0.4.8 pyasn1-modules-0.2.8 pyjwt-2.1.0 pynacl-1.4.0 python-box-5.4.1 python-slugify-5.0.2 pytzdata-2020.1 requests-2.25.1 requests-oauthlib-1.3.0 rsa-4.7.2 tabulate-0.8.9 text-unidecode-1.3 toml-0.10.2 websocket-client-1.2.1 wrapt-1.12.1 yarl-1.6.3
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: <https://pip.pypa.io/warnings/venv>
+ exec prefect execute flow-run
Traceback (most recent call last):
  File "/opt/conda/bin/prefect", line 8, in <module>
    sys.exit(cli())
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/opt/conda/lib/python3.8/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/opt/conda/lib/python3.8/site-packages/prefect/cli/execute.py", line 52, in flow_run
    client = Client()
  File "/opt/conda/lib/python3.8/site-packages/prefect/client/client.py", line 121, in __init__
    self._access_token_expires_at = pendulum.now()
  File "/opt/conda/lib/python3.8/site-packages/pendulum/__init__.py", line 211, in now
    dt = _datetime.datetime.now(local_timezone())
  File "/opt/conda/lib/python3.8/site-packages/pendulum/tz/__init__.py", line 60, in local_timezone
    return get_local_timezone()
  File "/opt/conda/lib/python3.8/site-packages/pendulum/tz/local_timezone.py", line 35, in get_local_timezone
    tz = _get_system_timezone()
  File "/opt/conda/lib/python3.8/site-packages/pendulum/tz/local_timezone.py", line 63, in _get_system_timezone
    return _get_unix_timezone()
  File "/opt/conda/lib/python3.8/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
Setting the
TZ
env variable seems to fix it, but it’s funny that I need to, I feel like?
k

Kevin Kho

08/30/2021, 12:33 AM
Maybe this is related?
w

Wilson Bilkovich

08/30/2021, 1:04 AM
Interesting. Sounds like
tzdata
might be worth installing in the
prefect
image?
k

Kevin Kho

08/30/2021, 1:05 AM
I can ask about it and get back to you
💯 1