Closed jamespet77 closed 6 months ago
Hi @jamespet77 , did you set THEPIPE_API_KEY
to your API key? If so, I'd love to get this fixed for you at our discord https://discord.gg/khsB3667 and push a change to resolve the bug.
Yes.
I did find a workaround.
I added
import dotenv dotenv.load_dotenv()
to extractor.py
I am not sure why it is not picking up my env vars, but this allowed it to grab my ".env" for the project.
If there is an alternative that is recommended, I am not seeing it in the current documentation.
@jamespet77 Thanks! I think I understand this issue a bit better now -- a system-wide environment variable must be set (the equivalent of export THEPIPE_API_KEY=yourkeyhere
in linux), not a .env file environment variable. I will make the readme more clear on this until I can push a change to support this fix. It must also be valid, so if the key is invalid it will return this message.
I tried the system wide in in .bashrc and that did not work either. Maybe it was formatted wrong?? Either way, it would be nice to have it local so that I can use a project specific KEY for it.
@jamespet77 I added the dotenv load as you suggested: #3fdda829b2bd82e53926dc0d5bf8fc363e668fa8
Although, if this does not work for you, you can send me your API key at emmett@thepi.pe and I will investigate this deeper. You can also use it without an API key (see the local installation section).
Thanks for already having spent the time to help with that workaround.
I have added the env var THEPIPE_API_KEY to my .env, .bashrc and at the commandline. It is not getting accepted.
{response['error']}") ValueError: Valid environment variable THEPIPE_API_KEY not found. You may need to restart if you have set your API key. Visit https://thepi.pe/docs to learn more.