Sikuli 2.0 is not finding images previously found by 1.1.3

Asked by hcuthbert

Sikuli 1.1.3 works like a champ when using the MasterPath folder to specify the folders which Sikuli can see and pull scripts to images from:

from sikuli import *

admPath = "C:\\Sikulix\\FMH_Regression\\TS_ADMIN\\" # Test Cases
if not admPath in sys.path: sys.path.append(admPath)

APMPath = "C:\\Sikulix\\FMH_Regression\\TS_APM\\" # Test Cases
if not APMPath in sys.path: sys.path.append(APMPath)

prtPath = "C:\\Sikulix\\FMH_Regression\\TS_PRT\\" # Test Cases
if not prtPath in sys.path: sys.path.append(prtPath)

path19 = "C:\\Sikulix\\FMH_Regression\\Images\\FMH"
addImagePath(path19)

------------------------------------------------------------------------
Path is used by the tests as an alias to MasterPath:

# Open the Master_Path.sikuli file and create the new entires to support the folder creation
from sikuli import *

masterPath = "C:\\Sikulix\\FMH_Regression\\"
if not masterPath in sys.path: sys.path.append(masterPath)

import Master_Path

------------------------------------------------------------------------
Tests: uses Import Paths

#====================================================================
from sikuli import *
import Paths
import FUNC_Log as Log
import NotificationsLib as Noti
import PORTAL_FunctionLib as Port

In Sikuli 2.0, how do I get Sikuli to recognize the images within the folder path:

Folder structure is below -- images are stored in subfolders within the Images folder

 C:\SikuliX\FMH_Regression\Images

When opening 2.0, Sikuli throws the following errors -- images are found within the image directories
 [error] ImagePath: find: not there: 1569933177020.png
[error] ImagePath: find: not there: 1569933177020.png
[error] ImagePath: find: not there: 1572965898802.png
[error] ImagePath: find: not there: 1572965898802.png
[error] ImagePath: find: not there: 1570460512259.png
[error] ImagePath: find: not there: 1570460512259.png
[error] ImagePath: find: not there: 1570460512259.png
[error] ImagePath: find: not there: 1570460512259.png

Feb 28 2020, Good Morning Rainman, you can close this issue with my path issue. Version 2.0.3 has somewhat resolved the issue. I moved all images to the specific function library vs having individual image libraries. I am continuing to verify the differences between 1.1.3 and 2....

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :
#1

If I understand right:
The images are found at runtime of the script, but not shown in the IDE as thumbnails.

Please confirm.

Revision history for this message
hcuthbert (howard-cuthbert) said :
#2

Rainman, thanks for the quick response,

Sikuli 2.0 does not recognize the path to get the images, doesn't like the function calls, or doesn't like the masterpath references. I have tried to manipulate the folder struction and MasterPath to see if Sikuli will pick up the images. Doesn't happen. As I have stated, 1.1.3 works great.

more info:
Tests are function driven to support reuse of images. Functions are stored in separate scripts with reference calls to the images(etc.. 1234.png) . Images are stored within their own directories.

Revision history for this message
hcuthbert (howard-cuthbert) said :
#3

Rainman, I have been doing different scenarios to try an narrow the problem. I will keep you posted. There are some differences already noted from the 1.1.3 vs 2.0 for ex:
Sikuli is not verifying path names to be exact matches (case sensitive) vs 1.1.3
ex: 2.0 expects: C:\SikuliX\FMH_Regression\Logs
      1.1.3 allowed: C:\SikuliX\FMH_regression\logs

Sikuli is has changed the acceptance of specific calls:
ex: 1.1.3 allowed: openApp('explorer "C:\SikuliX\FMH_Regression\Logs"') to open File Explorer
        2.0 must now use: dir = os.path.join('C:\SikuliX\FMH_Regression\Logs')
                                             os.popen('start explorer "%s" ' % dir)

Revision history for this message
RaiMan (raimund-hocke) said :
#4

thanks.

I will have a look and in case create bugs.

Revision history for this message
hcuthbert (howard-cuthbert) said :
#5

Rainman,

Hope you are having a happy Friday. More information for you. It appears Sikuli 2.0 does find the file directories containing the images based on the Master Path.

The problem I am facing is the calls to open the various applications (IE, Firefox, Chrome, etc....). I have found that the Win calls work (click start menu, search for Firefox, click Enter Key.)). Program calls are a little on the messy side at the moment (fickle as you say).

I will continue to debug. I did get a workflow to startup and enter data from the workbooks -- that's a great thing. I will still play around with 2.0. But I will stay with 1.1.3 for now.

Thanks again.

Revision history for this message
RaiMan (raimund-hocke) said :
#6

as said by user