← Back to team overview

sikuli-driver team mailing list archive

[Question #668852]: How to connect to vnc using jython?

 

New question #668852 on Sikuli:
https://answers.launchpad.net/sikuli/+question/668852

How to connect to vnc using jython? 

My simple script:

import unittest
import org.sikuli.script.SikulixForJython
from sikuli import *

class Test_Thing1(unittest.TestCase):

   def setUp(self):
    wait(2)
    Debug.on(4)
    vnc = vncStart("192.168.3.15",5900)
    Test = vnc.capture();
    Test.save("test.png");

if __name__ == '__main__':

   suite = unittest.TestLoader().loadTestsFromTestCase(Test_Thing1) #give the class name
   runner = unittest.TextTestRunner()
   failures = runner.run(suite)
   sys.exit(not failures.wasSuccessful())

Return error:

Traceback (most recent call last):
  File "example.py", line 16, in setUp
    Test = vnc.capture();
AttributeError: 'NoneType' object has no attribute 'capture'




-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.