1

I get

AttributeError: 'Display' object has no attribute 'old_display_var' 

in PyVirtualDisplay when trying to stop display after tests execution:

in setUp method:

self.display = Display(visible=False, size=(1440, 900)) 
self.display.start()

then open browser and execute tests

and in tearDown method:

self.display.stop()

I want to stop display because of many opened Xvfb processes in ubuntu after several test execution

Vadim Kovrizhkin
  • 1,575
  • 4
  • 16
  • 27
  • Were you able to determine a fix for this? Just ran into this same issue and this appears to be the only SO question about it. Not a huge deal, as I can just manually delete the Xvfb processes, but would be interested in a fix. – n1c9 Nov 01 '17 at 21:04
  • No, I did not resolve it. – Vadim Kovrizhkin Nov 02 '17 at 21:01

1 Answers1

3

I got the same message yesterday. I forgot starting the display with self.display.start()

Adding this to the file resolved the issue.

Stan van Rooy
  • 346
  • 2
  • 11