theskumar / theskumar/python-dotenv
Doesn't accept any pathnames nor show errors on python 3.9.2 / raspberry pi
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Python
- Sterne
- 8.9k
- Forks
- 581
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
Either running from a script, or from the command line, it doesn't accept any pathnames as valid arguments
toni@rpi:~/temp $ pwd
/home/toni/temp
toni@rpi:~/temp $ dotenv list
ENV1=value1
ENV2=value2
toni@rpi:~/temp $ dotenv -f /home/toni/temp list
Usage: dotenv list [OPTIONS]
Try 'dotenv list --help' for help.
Error: Invalid value: Path "/home/toni/temp" does not exist.
toni@rpi:~/temp $ dotenv -f . list
Usage: dotenv list [OPTIONS]
Try 'dotenv list --help' for help.
Error: Invalid value: Path "." does not exist.
toni@rpi:~/temp $ dotenv -f / list
Usage: dotenv list [OPTIONS]
Try 'dotenv list --help' for help.
Error: Invalid value: Path "/" does not exist.
toni@rpi:~/temp $
In a script, load_dotenv() works if I'm in the correct directory. However, load_dotenv(dotenv_path="/home/toni/temp", verbose=True) or any other directory falls silently without populating the relevant environment variables.
The environment:
toni@rpi:~/temp $ python -V
Python 3.9.2
toni@rpi:~/temp $ cat /etc/issue
Debian GNU/Linux 11 \n \l
toni@rpi:~/temp $ uname -a
Linux rpi 5.15.61-v8+ #1579 SMP PREEMPT Fri Aug 26 11:16:44 BST 2022 aarch64 GNU/Linux
toni@rpi:~/temp $
Happy to provide further debugging information as needed. Your contribution guidelines don't provide any guidance on what's useful. Perhaps that could be something to add, too, to make issue submissions easier to look at.
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Start by reproducing the reported dotenv -f commands and the load_dotenv(dotenv_path=..., verbose=True) call on the documented Python and Debian environment. Trace the CLI path handling and the load_dotenv entry point; done means valid pathnames are accepted, failures are reported appropriately, and variables load from the specified path.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- backend, cli
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 35/100