python scripts are unable to pick up environment variables. I'm not sure if this is expected or a bug. But wanted to know if there is a way to work around this?
➜ echo $MY_VAR
/Users/cc/.pkb/personal/Books.org
➜ which python
/Users/cc/.asdf/shims/python
➜ python
Python 3.11.3 (main, May 8 2023, 20:50:37) [Clang 14.0.3 (clang-1403.0.22.14.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from os import environ
>>> environ.get('MY_VAR')
>>>
python
scripts are unable to pick up environment variables. I'm not sure if this is expected or a bug. But wanted to know if there is a way to work around this?