← Back to team overview

sikuli-driver team mailing list archive

[Bug 1542474] Re: Imported Module is retaining old fuction definition

 

carefully read through:
http://sikulix-2014.readthedocs.org/en/latest/scripting.html#importing-other-sikuli-scripts-reuse-code-and-images

** Changed in: sikuli
       Status: New => Invalid

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

Title:
  Imported Module is retaining old fuction definition

Status in Sikuli:
  Invalid

Bug description:
  An older version of an imported function definition is sometimes used
  after a user changes the definition of a function by removing passed
  in variables (ex: def appSync(X, Y) changed to appSync() .

  Reproducible: Occasionally

  Steps to reproduce:
  1. Generate a new Sikuli Source folder: Module.sikuli
  2. Define a function that requires parameters EX: appSync(X, Y) and save changes. NOTE: I included the import sikuli.... in the module
  3. Import the module into another Sikuli script: I performed the following import(appSync) 
  4. Call function from imported module: Module.appSync("XXX", "YYY")
  5. Save and execute.
  6. Open Module.sikuli
  7. Edit defined function appSync and remove parameters from function: appSync()
  8. Edit Sikuli Script that imported the module and edit to remove parameter: Module.appSync()
  9. Save and run script.

  Observe that occasionally script will stop with the error:
  Module.appSync requires parameters (2 needed, 0 provided). I have
  closed and restarted Sikuli and the PC running Sikuli. Sometimes it
  works as expected but the next run it doesn't.

  OS: Win8.1 Pro 64Bit
  Version of Sikuli: 1.1.0 (2015-10-05_17:07) 20

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


References