Skip to content

Commit

Permalink
mitigate "can't open DISPLAY" (#51)
Browse files Browse the repository at this point in the history
* Xvfb settings: -noreset -nolock -shmem
* pyvirtualdisplay: manage_global_env=False
  • Loading branch information
alexsavulescu authored Aug 31, 2022
1 parent 54d6594 commit c9e6163
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/nrn-modeldb-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
set
# Set up Xvfb
sudo apt-get install xvfb
sudo /usr/bin/Xvfb $DISPLAY -screen 0 1600x1200x24 & # run in bg
sudo /usr/bin/Xvfb $DISPLAY -screen 0 1600x1200x24 -noreset -nolock -shmem & # run in bg
# Install python dependencies
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
Expand Down
2 changes: 1 addition & 1 deletion modeldb/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def runmodels(args=None):

if virtual:
from pyvirtualdisplay import Display
with Display() as _:
with Display(manage_global_env=False) as _:
mrm.run_models(model_list)
else:
mrm.run_models(model_list)
Expand Down

0 comments on commit c9e6163

Please sign in to comment.