xpra icon
Bug tracker and wiki

Opened 4 weeks ago

Closed 3 weeks ago

#1653 closed defect (fixed)

simulate_console_user.py automated test failing

Reported by: J. Max Mena Owned by: J. Max Mena
Priority: minor Milestone: 2.2
Component: tests Version: trunk
Keywords: Cc: smo@…


As mentioned before one of the console tests is failing with a bash exit code of 127 - here's what the test outputs:

starting server: ['/usr/bin/xpra', '--no-daemon', '--bind-tcp=', '--no-notifications', '--password-file=./test-password.txt', '--auth=file', '--auth=none', '--tcp-auth=file', '--no-pulseaudio', 'start', ':10']
starting test command: ['/usr/bin/vglrun', '-d', ':0', ' -- ', '/usr/bin/xterm', '-geometry', '160x60', '-e', 'PYTHONPATH=`pwd` ./tests/xpra/test_apps/simulate_console_user.py'] with env={'TERM': 'xterm-256colTraceback (most recent call last):
  File "test_measure_perf.py", line 475, in with_server
    assert code is None, "test command %s failed to start: exit code is %s" % (cmd, code)
AssertionError: test command ['/usr/bin/vglrun', '-d', ':0', ' -- ', '/usr/bin/xterm', '-geometry', '160x60', '-e', 'PYTHONPATH=`pwd` ./tests/xpra/test_apps/simulate_console_user.py'] failed to start: exit code is 127

I'm not sure what the actual cause is - I don't think it's the relative folder (I hardcoded the file path), maybe it's a PATH issue? Or maybe it's a pathing issue in that the system can't find the test? I've tried hard-coding the file location into the test and it still fails, so I'm not sure.

I re-ran the test without VirtualGL and it fails with exit code 0...so VirtualGL isn't it.

Just running python simulate_console_user.py works fine, so the python file itself is okay.

I'll keep poking at it today and see if I can get it working, but I'm not sure how much use I'll be as I'm still learning Python.

Of note:

The xterm tests work fine (for example, the while true; do dmesg; done) - it's just the one that loads the Python file that is being problematic.

Change History (5)

comment:1 Changed 4 weeks ago by Antoine Martin

Owner: changed from Antoine Martin to J. Max Mena

That command line is wrong and is never going to work:

['/usr/bin/vglrun', '-d', ':0', ' -- ', '/usr/bin/xterm', '-geometry', '160x60', '-e', 'PYTHONPATH=`pwd` ./tests/xpra/test_apps/simulate_console_user.py']

The PYTHONPATH=`pwd` part will fail, you can try running it from a regular xterm to verify. It needs to be added to the environment that executes this command, not nested in it.

comment:2 Changed 4 weeks ago by J. Max Mena

Okay I removed the 'PYTHONPATH=`pwd bit and added it to the environment of the bash script that runs the file and that fixed it.

Do you want to remove it from the default config.py file and make a note for others?

FWIW I'm running with PYTHONPATH=/usr/lib/python2.7.

comment:3 Changed 4 weeks ago by J. Max Mena

Cc: smo@… added

Smo was interested in this as well.

comment:4 Changed 4 weeks ago by Antoine Martin

How about just r16939?

comment:5 Changed 3 weeks ago by J. Max Mena

Resolution: fixed
Status: newclosed

That works much better.


Note: See TracTickets for help on using tickets.