KeyError: 'USERNAME'
Bug #715507 reported by
Levi Larsen
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cGmail |
New
|
Undecided
|
Francesco Marella |
Bug Description
Version 0.6.2
Traceback (most recent call last):
File "/usr/share/
from cGmail.
File "/usr/share/
if os.environ[
File "/usr/lib/
raise KeyError(key)
KeyError: 'USERNAME'
The problem is that there is no "USERNAME" environmental variable set on my system (Debian Sid). This also just a bad way to check if the script is running as root, anyway. I would suggest replacing
if os.environ[
with
if os.geteuid() == 0:
Related branches
Changed in cgmail: | |
milestone: | none → 0.6.3 |
assignee: | nobody → Francesco Marella (francesco-marella) |
To post a comment you must log in.
Thank you Levi!!!