-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Unclear error messages #224
Comments
Thank you for your report, Thomas! Let's address first the missing HOME issue. We fixed the missing HOME problem for Windows platform by using USERPROFILE for these cases for August release. Looks like more fixes are needed. What is the HOME equivalent on your platform (output of |
As for your traceback enhancement, looks reasonable to me. I opened an internal new feature ticket for this (See labels) |
I'm using Centos 7. # Ups, I accidentally closed the issue, sorry! |
Note that this option (PGAP_INPUT_DIR) is documented in Wiki. Glad it worked out for you, Thomas! |
True, but the error would have happened anyway: class Setup:
def __init__(self, args):
...
if platform.system() == 'Windows':
self.install_dir = os.environ.get('PGAP_INPUT_DIR',os.environ['USERPROFILE']+'/.pgap')
else:
self.install_dir = os.environ.get('PGAP_INPUT_DIR',os.environ['HOME']+'/.pgap')
To demonstrate, run this:
|
This will go in the coming release (in the next few days) |
I tried to run pgap using Python's
subprocess.run
. I got return code 1, STDOUT='HOME'
and no STDERR.The reason was that on line 493 of pgap.py,
os.environ['HOME']
is called, which raises an error because I didn't define theHOME
variable. Because of lines 936-940, only'HOME'
is printed:I propose that you change the code to something like this:
Then, the whole stack trace is printed and I would have quickly found the problem.
The text was updated successfully, but these errors were encountered: