Wo finde ich die .env-Datei?
Verfasst: Montag 2. Dezember 2019, 22:23
Vielleicht kann mir jemand helfen. Ich möchte gerne diesen Script installieren: https://github.com/glogiotatidis/tg-relay
In der Beschreibung steht:
Set API_ID and API_HASH to .env file or your environment.
Wie und wo mache ich das?
Wenn ich ausführe, bekomme ich folgende Meldung:
Ich nutze Ubuntu 19.04 und Python3.7
In der Beschreibung steht:
Set API_ID and API_HASH to .env file or your environment.
Wie und wo mache ich das?
Wenn ich
Code: Alles auswählen
python3 listchannels.p
Code: Alles auswählen
Traceback (most recent call last):
File "listchannels.py", line 6, in <module>
import config
File "/home/arturweiss/tg-relay/config.py", line 3, in <module>
API_ID = config('1129586')
File "/home/arturweiss/.local/lib/python3.7/site-packages/decouple.py", line 199, in __call__
return self.config(*args, **kwargs)
File "/home/arturweiss/.local/lib/python3.7/site-packages/decouple.py", line 83, in __call__
return self.get(*args, **kwargs)
File "/home/arturweiss/.local/lib/python3.7/site-packages/decouple.py", line 68, in get
raise UndefinedValueError('{} not found. Declare it as envvar or define a default value.'.format(option))
decouple.UndefinedValueError: 1129586 not found. Declare it as envvar or define a default value.