← Back to team overview

sikuli-driver team mailing list archive

[Bug 865354] Re: traceit

 

def traceit(frame, event, arg):
# keeps track of code line number
    if event == "line":
    	global lineno
        lineno = frame.f_lineno
    return traceit

I just moved my library to a new location that´s all about virtual 1 & 0

Do you see anything else?

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/865354

Title:
  traceit

Status in Sikuli:
  New

Bug description:
  [my code:]

  import sys

  virtual = 1
  if virtual == 1:
    myScriptPath = "C:\\Documents and Settings\\Administrator\\My Documents\\Dropbox\\Linus\\SikuliLib\\MSSLib.sikuli"
  else:
    myScriptPath = "C:\\SikuliLib\\MSSLib.sikuli" 		      # path to library
  	
  if not myScriptPath in sys.path: sys.path.append(myScriptPath)  # load library path
  from MSSLib import * 							     	  # import myLib
  print "MSSLib Loaded..."
  sys.settrace(traceit)

  [printout:]

  Starting Test case 1.1
  MSSLib Loaded...
  [error] Stopped
  [error] An error occurs at line 41
  [error] Error message: Traceback (most recent call last):
   File "C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\sikuli-tmp1660965428825825785.py", line 41, in 
   sys.settrace(traceit)
  NameError: name 'traceit' is not defined


  
  what am I doing wrong?
  runnig rc3 build 931

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/865354/+subscriptions


References