How to use IronPython with RF?

586 views
Skip to first unread message

tmpalaniselvam

unread,
Nov 5, 2010, 7:40:56 AM11/5/10
to robotframework-users
Hi All,
Today I was going through IronPython (URL: http://www.ironpython.net).
I would like to know anybody using IronPython with Robot Framework.

How one can create RF Library with combination of CSharp application
and IronPython? Anybody tried so far?

Thanks,
Palani.

Pekka Klärck

unread,
Nov 6, 2010, 12:24:38 PM11/6/10
to palani...@gmail.com, robotframework-users
2010/11/5 tmpalaniselvam <palani...@gmail.com>:

Robot Framework isn't "officially" supported on IronPython, but the
enhancement request related to it [1] contains steps needed to get
started. I don't know can you write libraries using C# directly, but
you should at least be able to write a Python library and interact
with C# APIs through it.

The main reason IronPython isn't yet supported better is that Nokia
Siemens Networks, the company that sponsors most of the RF
development, doesn't use .NET. Our team is definitely willing to help,
though, if someone is interested to enhance the support.

[1] http://code.google.com/p/robotframework/issues/detail?id=154

Cheers,
.peke
--
Agile Tester/Developer/Consultant :: http://eliga.fi
Lead Developer of Robot Framework :: http://robotframework.org

tmpalaniselvam

unread,
Nov 9, 2010, 1:19:32 AM11/9/10
to robotframework-users
Hi All,

. I was trying to execute existing tests as per [1] with IPYBOT. But
I’m getting error like ‘ImportError: No module named unicodedata’ How
can I solve this issue?

[1] http://code.google.com/p/robotframework/issues/detail?id=154

Thanks,
Palani.

Jussi Malinen

unread,
Nov 9, 2010, 4:00:13 AM11/9/10
to palani...@gmail.com, robotframework-users
Hi Palani,

Using unicodedata is already avoided on Jython because it is too slow
there. Could you try changing the code slightly to see if simply
removing unicodedata is enough?

in file "robot/utils/unic.py"

you have the following bit:

else:
# importing unicodedata on jython takes a very long time, and does not seem
# necessary as java probably already handles normalization. Furthermore
# java 1.5 does not even have unicodedata.normalize
from unicodedata import normalize

def unic(item, *args):
return normalize('NFC', _unic(item, *args))

Change that to:

else:
def unic(item, *args):
return _unic(item, *args)


That should do the trick. Unicodedata is only used for unicode
normalization and most likely(?) it's not even needed on ironpython.
(Even on regular python it is only needed on very specific conditions,
mostly with Mac filesystems containing diacritics.)

I guess the real way to fix this would be to add a separate check for
sys.platform == 'cli' (as we do for Jython there) and then define unic
as above only for ironpython.

Best regards,
Jussi

> --
> You received this message because you are subscribed to the Google Groups "robotframework-users" group.
> To post to this group, send email to robotframe...@googlegroups.com.
> To unsubscribe from this group, send email to robotframework-u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/robotframework-users?hl=en.
>
>

tmpalaniselvam

unread,
Nov 9, 2010, 4:48:48 AM11/9/10
to robotframework-users
Hi Jussi,

On Nov 9, 2:00 pm, Jussi Malinen <jussi.ao.mali...@gmail.com> wrote:
> Hi Palani,
>
> Using unicodedata is already avoided on Jython because it is too slow
> there. Could you try changing the code slightly to see if simply
> removing unicodedata is enough?

Thanks for your reply.

For past two days, I'm trying to run on IronPython. I have commented
unicodedata.py like below:
try:
unicodedata
except NameError:
pass

In unic.py, I have commented like below:
# Commented below line as per Jussi's suggestion
#from unicodedata import normalize

def unic(item, *args):
#return normalize('NFC', _unic(item, *args))
return _unic(item, *args)

Now I'm getting error like ==> 'LightException' object has no
attribute 'ElementTree'
My environment:
OS - WinXP SP2 (32bit)
Python - 2.6
IronPython - IronPython 2.7 Alpha 1 (2.7.0.1) on .NET 4.0.30319.1
DotNet Framework: 4.0
Robot Framework 2.5.3 (Python 2.6.6 on win32)

My command line error:
D:\MDM_Scripts\Phase1>ipybot --test CVG_TC012 CVG.html
Traceback (most recent call last):
File "C:\IronPython\Lib\site-packages\robot\runner.py", line 307, in
<module>
File "C:\IronPython\Lib\site-packages\robot\__init__.py", line 23,
in <module>
File "C:\IronPython\Lib\site-packages\robot\output\__init__.py",
line 16, in <module>
File "C:\IronPython\Lib\site-packages\robot\output\output.py", line
18, in <module>
File "C:\IronPython\Lib\site-packages\robot\common\__init__.py",
line 16, in <module>
File "C:\IronPython\Lib\site-packages\robot\common\model.py", line
17, in <module>
File "C:\IronPython\Lib\site-packages\robot\common\statistics.py",
line 17, in <module>
File "C:\IronPython\Lib\site-packages\robot\utils\__init__.py", line
17, in <module>
File "C:\IronPython\Lib\site-packages\robot\utils\domwrapper.py",
line 25, in <module>
AttributeError: 'LightException' object has no attribute 'ElementTree'


I sent a mail to wolfram (wol...@wstanger.de) yesterday. Awaiting for
his reply.

Please do the needful.

Thanks,
Palani.

tmpalaniselvam

unread,
Nov 9, 2010, 5:20:04 AM11/9/10
to robotframework-users
Hi All,

I hope the issues might be due to Java classes.. So far, the errors
are thrown only for java calls.

Any other ideas / suggestions?

Thanks,
Palani.

tmpalaniselvam

unread,
Nov 9, 2010, 8:14:35 AM11/9/10
to robotframework-users
Hi All,

I tried as per Wolfram and Janne given the steps in [1] with lower
versions in other machine and script is started to run.

Robot Framework 2.1.2 (Python 2.6.4 on win32)
robotframework-seleniumlibrary-2.2.win32.exe
IronPython 2.6.1 (2.6.10920.0) on .NET 4.0.30319.1

[1] http://code.google.com/p/robotframework/issues/detail?id=154

But it is failing in the updated environment. First of all, IPYBOT is
unable to run with following environment.
Robot Framework 2.5.3 (Python 2.6.6 on win32)
IronPython 2.7 Alpha 1 (2.7.0.1) on .NET 4.0.30319.1

I hope, we can solve this issue for IronPython...

Thanks,
Palani.

William Kouda

unread,
Nov 9, 2010, 7:37:46 AM11/9/10
to robotframework-users, palani...@gmail.com
Hi all,

I myself have been working on implementing IronPython with the Robot Framework too, for the past week.
For this, I followed the early steps mentioned on discussion http://code.google.com/p/robotframework/issues/detail?id=154
I have experienced the same symptoms described by other users.
I've managed to solve some of the early issues (the first two I ran into) although there might be better ways of doing it:

1- the unicodedata issue, I actually solved after a bit of research by downloading a copy of a unicodedata.py from http://fepy.svn.sourceforge.net/viewvc/fepy/trunk/lib and copying it to the IronPythonxxx\Lib folder.

2- the AttributeError: 'LightException' object has no attribute 'ElementTree' issue was solved by copying ElementTreePath.py from Pythonxxx\Lib\xml\etree to IronPythonxxx\Lib\xml\etree. I think, depending on the version of IronPython installed, this file might or might not be there (might be in IronPython 2.6 but missing from IronPython 2.7).

Those errors disappeared but were immediately replaced by a new error (which I would expect other people to get):


Traceback (most recent call last):

File "c:\Python26\Lib\site-packages\robot\runner.py", line 307, in <module>
File "c:\Python26\Lib\site-packages\robot\__init__.py", line 41, in <module>
File "c:\Python26\Lib\site-packages\robot\output\__init__.py", line 16, in <module>
File "c:\Python26\Lib\site-packages\robot\output\output.py", line 18, in <module>
File "c:\Python26\Lib\site-packages\robot\common\__init__.py", line 17, in <module>
ImportError: Cannot import name BaseKeyword

After looking around, I found that BaseKeyword is a class found in PythonXXX\Lib\site-packages\robot\common\keyword.py. It is being ignored.
But there also is a keyword.py file in PythonXXX\Lib, which I suspect is the one being used. It does not contain that class, hence the error.

This is how far I've gone.

Both keyword.py modules are needed so it seems like a conflict. I am relatively new to Python but I assume whichever keyword.py module is picked up is dictated by the contents of the PYTHONPATH environment variable but if this is the case, I would be interested in knowing how to work around this issue.
There might still be other issues further down but I won't find out until I can fix this one.

Any feedback much appreciated. Thanks in advance.

William

Hi Jussi,

Thanks for your reply.

Please do the needful.

Thanks,
Palani.

--

You received this message because you are subscribed to the Google Groups "robotframework-users" group.
To post to this group, send email to robotframe...@googlegroups.com.
To unsubscribe from this group, send email to robotframework-u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/robotframework-users?hl=en.


______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________

______________________________________________________________________
This message and any attachments are confidential and should only be read by those to whom they are addressed. If you are not the intended recipient, please contact us, delete the message from your computer and destroy any copies. Any distribution or copying without our prior permission is prohibited. Internet communications are not always secure and therefore Fundraising Innovations Limited does not accept legal responsibility for this message. The recipient is responsible for verifying its authenticity before acting on the contents. Any views or opinions presented are solely those of the author and do not necessarily represent those of Fundraising Innovations Limited.

www.firsthelpline.com, www.energyhelpline.com and www.switchandgive.com are web sites operated and owned by Fundraising Innovations Ltd. Fundraising Innovations Ltd is a Company registered in England and Wales with a company Registration No 04426857 and having its registered office at THE CART WAGON LODGE, FRIDAY STREET FARM, FRIDAY STREET, EAST SUTTON, ME17 3DD
______________________________________________________________________
Scanned by the MessageLabs Email Security System.

WilliamK

unread,
Nov 9, 2010, 9:07:27 AM11/9/10
to robotframework-users
Hi all,

Apologies if I replied earlier to Palani's report using my mail
system. I'm sending this again but via the website for better
tracking.

------------------------------------------------------------------------------------------------------------------------------------

I myself have been working on implementing IronPython with the Robot
Framework too, for the past week.
For this, I followed the early steps mentioned on discussion
http://code.google.com/p/robotframework/issues/detail?id=154
I have experienced the same symptoms described by other users.
I've managed to solve some of the early issues (the first two I ran
into) although there might be better ways of doing it:

1- the unicodedata issue, I actually solved after a bit of research
by downloading a copy of a unicodedata.py from
http://fepy.svn.sourceforge.net/viewvc/fepy/trunk/lib and copying it
to the IronPythonxxx\Lib folder.

2- the AttributeError: 'LightException' object has no attribute
'ElementTree' issue was solved by copying ElementTreePath.py from
Pythonxxx\Lib\xml\etree to IronPythonxxx\Lib\xml\etree. I think,
depending on the version of IronPython installed, this file might or
might not be there (might be in IronPython 2.6 but missing from
IronPython 2.7).

Those errors disappeared but were immediately replaced by a new error
(which I would expect other people to get):
Traceback (most recent call last):
File "c:\Python26\Lib\site-packages\robot\runner.py", line 307, in
<module>
File "c:\Python26\Lib\site-packages\robot\__init__.py", line 41, in
<module>
File "c:\Python26\Lib\site-packages\robot\output\__init__.py", line
16, in <module>
File "c:\Python26\Lib\site-packages\robot\output\output.py", line
18, in <module>

tmpalaniselvam

unread,
Nov 10, 2010, 4:46:51 AM11/10/10
to robotframework-users
Hi,

I have uninstalled IronPython 2.7 Alpha 1 and installed IronPython
2.6.2 (2.6.10920.0) on .NET 4.0.30319.1. Now the import problem
('ImportError: Cannot import name BaseKeyword') is solved.

I'm getting the error as 'ImportError: No module named signal'. Also
I read the page [1] and came to know, we can not import signal.py
module in IronPython. How can I solve it now?

[1] http://ironpython.codeplex.com/wikipage?title=IPy1.0.xCPyDifferences&ProjectName=ironpython

Thanks,
Palani.

tmpalaniselvam

unread,
Nov 10, 2010, 7:45:50 AM11/10/10
to robotframework-users
Hi All,
I got a dummy signal.py from [1]. After that I'm getting error for
parsing HTML data file.

D:\IronPy_Robot>ipy UIATest.html
File "UIATest.html", line 2
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

^
SyntaxError: unexpected token '<'


[1] - http://discussion.forum.nokia.com/forum/showthread.php?159782-Replacement-for-signal-module

Looking for helping hands.

Thanks,
Palani.

Pekka Klärck

unread,
Nov 10, 2010, 9:37:12 AM11/10/10
to palani...@gmail.com, robotframework-users
2010/11/10 tmpalaniselvam <palani...@gmail.com>:

>
> I have uninstalled IronPython 2.7 Alpha 1 and installed IronPython
> 2.6.2 (2.6.10920.0) on .NET 4.0.30319.1. Now the import problem
> ('ImportError: Cannot import name BaseKeyword') is solved.

It's probably safest to use the IronPython 2.6 version at this point.

>  I'm getting the error as 'ImportError: No module named signal'. Also
> I read the page [1] and came to know, we can not import signal.py
> module in IronPython. How can I solve it now?
>
> [1] http://ironpython.codeplex.com/wikipage?title=IPy1.0.xCPyDifferences&ProjectName=ironpython

2010/11/10 tmpalaniselvam <palani...@gmail.com>:
> I got a dummy signal.py from [2].
>
> [2] - http://discussion.forum.nokia.com/forum/showthread.php?159782-Replacement-for-signal-module

The signal module is used only for handling stopping execution
gracefully with Ctrl-C (and signals, but that's not so relevant on
Windows). This could be handled in the framework so that if importing
the module fails, the support for Ctrl-C is not enabled. If you then
install the signal module manually, the support is enabled. Please
submit a separate enhancement request about this to the issue tracker
and I'll take a look at implementing it.

> After that I'm getting error for parsing HTML data file.
> D:\IronPy_Robot>ipy UIATest.html
> File "UIATest.html", line 2
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
>
> ^
> SyntaxError: unexpected token '<'

Now you try to execute the test data file directly with IronPython
(i.e. same as running `python tests.html` instead of `pybot
tests.html`). I don't know how you have installed Robot for IronPython
-- making the installation easier is one of the biggest part in
Robot's IronPython support -- so I don't know how you should start it.

tmpalaniselvam

unread,
Nov 11, 2010, 12:00:08 AM11/11/10
to robotframework-users
Hi Pekka

On Nov 10, 7:37 pm, Pekka Klärck <p...@iki.fi> wrote:
> 2010/11/10 tmpalaniselvam <palani.sel...@gmail.com>:

>
> Now you try to execute the test data file directly with IronPython
> (i.e. same as running `python tests.html` instead of `pybot
> tests.html`). I don't know how you have installed Robot for IronPython
> -- making the installation easier is one of the biggest part in
> Robot's IronPython support -- so I don't know how you should start it.
>

I have copied all RobotFramework libraries from python installation to
IronPython as per [1]. I have created the IronPython and executed the
same test created by Wolfram in [1]. I was able to run the same case
successfully in lower version of RF (2.1.2) libraries. But the same
case is unable to run in latest version RF (2.5.3).

Any help would be much helpful...Looking forward..

[1] - http://code.google.com/p/robotframework/issues/detail?id=154

Thanks,
Palani.

Pekka Klärck

unread,
Nov 11, 2010, 2:35:03 AM11/11/10
to palani...@gmail.com, robotframework-users
2010/11/11 tmpalaniselvam <palani...@gmail.com>:

> On Nov 10, 7:37 pm, Pekka Klärck <p...@iki.fi> wrote:
>>
>> Now you try to execute the test data file directly with IronPython
>> (i.e. same as running `python tests.html` instead of `pybot
>> tests.html`). I don't know how you have installed Robot for IronPython
>> -- making the installation easier is one of the biggest part in
>> Robot's IronPython support -- so I don't know how you should start it.
>>
>
> I have copied all RobotFramework libraries from python installation to
> IronPython as per [1]. I have created the IronPython and executed the
> same test created by Wolfram in [1]. I was able to run the same case
> successfully in lower version of RF (2.1.2) libraries. But the same
> case is unable to run in latest version RF (2.5.3).

How did you execute tests when using RF 2.1.2? In your earlier mail
you tried to execute tests like

ipy UIATest.html

which just cannot work. This `ipy` is the IronPython itself and it
alone cannot execute Robot tests. I got pretty much same syntax error
if I run a test case file with `python`:

python tests.html
File "tests.html", line 3
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
^
SyntaxError: invalid syntax

Runnint tests with like `pybot tests.html` obviously works.

You probably should use something like

ipy path/to/rf/installation/robot/runner.py UIATests.html

or have special start-up script which you can use like

ipybot UIATest.html

tmpalaniselvam

unread,
Nov 11, 2010, 3:58:59 AM11/11/10
to robotframework-users
Hi Pekka,
I'm getting error like below with RobotFramework 2.5.3

D:\IronPy_Robot>ipybot UIATest.html
==============================================================================
Uiatest
==============================================================================
[ ERROR ] Unexpected error: ValueError: Index was out of range. Must
be non-negative and less than the size of the collection.
Parameter name: startIndex

But the same case is running fine on Robot2.1.2

Thanks,
Palani.

tmpalaniselvam

unread,
Nov 11, 2010, 8:15:14 AM11/11/10
to robotframework-users
Hi Pekka

Syslog - contents are posted here:

-----
20101111 18:38:50.543 | INFO | Robot Framework 2.5.4 (Python 2.6.1 on
cli)
20101111 18:38:50.777 | INFO | Data sources: 'UIATest.html'
20101111 18:38:50.840 | INFO | Settings:
Critical: None
DebugFile: NONE
Doc: None
Exclude: []
Include: []
Listeners: []
Log: log.html
LogLevel: INFO
LogTitle: None
Metadata: []
MonitorColors: False
MonitorWidth: 78
Name: Syslog
NonCritical: None
Output: output.xml
OutputDir: d:\ironpy_robot
Report: report.html
ReportBackground: None
ReportTitle: None
RunMode: []
SetTag: []
SplitOutputs: -1
SuiteNames: []
SuiteStatLevel: -1
Summary: NONE
SummaryTitle: None
TagDoc: []
TagStatCombine: []
TagStatExclude: []
TagStatInclude: []
TagStatLink: []
TestNames: []
TimestampOutputs: False
VariableFiles: []
Variables: []
20101111 18:38:50.871 | INFO | No debug file
20101111 18:38:50.980 | INFO | Parsing file 'd:\ironpy_robot
\uiatest.html'.
20101111 18:38:51.480 | INFO | Initializing namespace for test suite
'Syslog'
20101111 18:38:51.746 | DEBUG | Got handler method 'call_method'
20101111 18:38:51.746 | DEBUG | Created keyword 'Call Method'
20101111 18:38:51.746 | DEBUG | Got handler method 'catenate'
20101111 18:38:51.746 | DEBUG | Created keyword 'Catenate'
20101111 18:38:51.761 | DEBUG | Got handler method 'comment'
20101111 18:38:51.761 | DEBUG | Created keyword 'Comment'
20101111 18:38:51.761 | DEBUG | Got handler method
'convert_to_boolean'
20101111 18:38:51.761 | DEBUG | Created keyword 'Convert To Boolean'
20101111 18:38:51.761 | DEBUG | Got handler method
'convert_to_integer'
20101111 18:38:51.761 | DEBUG | Created keyword 'Convert To Integer'
20101111 18:38:51.761 | DEBUG | Got handler method 'convert_to_number'
20101111 18:38:51.761 | DEBUG | Created keyword 'Convert To Number'
20101111 18:38:51.761 | DEBUG | Got handler method 'convert_to_string'
20101111 18:38:51.761 | DEBUG | Created keyword 'Convert To String'
20101111 18:38:51.761 | DEBUG | Got handler method 'create_list'
20101111 18:38:51.761 | DEBUG | Created keyword 'Create List'
20101111 18:38:51.777 | DEBUG | Got handler method 'evaluate'
20101111 18:38:51.777 | DEBUG | Created keyword 'Evaluate'
20101111 18:38:51.777 | DEBUG | Got handler method 'exit_for_loop'
20101111 18:38:51.777 | DEBUG | Created keyword 'Exit For Loop'
20101111 18:38:51.777 | DEBUG | Got handler method 'fail'
20101111 18:38:51.777 | DEBUG | Created keyword 'Fail'
20101111 18:38:51.777 | DEBUG | Got handler method 'fatal_error'
20101111 18:38:51.777 | DEBUG | Created keyword 'Fatal Error'
20101111 18:38:51.793 | DEBUG | Got handler method 'get_count'
20101111 18:38:51.793 | DEBUG | Created keyword 'Get Count'
20101111 18:38:51.793 | DEBUG | Got handler method 'get_length'
20101111 18:38:51.793 | DEBUG | Created keyword 'Get Length'
20101111 18:38:51.793 | DEBUG | Got handler method
'get_library_instance'
20101111 18:38:51.793 | DEBUG | Created keyword 'Get Library Instance'
20101111 18:38:51.793 | DEBUG | Got handler method 'get_time'
20101111 18:38:51.793 | DEBUG | Created keyword 'Get Time'
20101111 18:38:51.793 | DEBUG | Got handler method 'get_variables'
20101111 18:38:51.793 | DEBUG | Created keyword 'Get Variables'
20101111 18:38:51.793 | DEBUG | Got handler method 'import_library'
20101111 18:38:51.793 | DEBUG | Created keyword 'Import Library'
20101111 18:38:51.808 | DEBUG | Got handler method 'import_resource'
20101111 18:38:51.808 | DEBUG | Created keyword 'Import Resource'
20101111 18:38:51.808 | DEBUG | Got handler method 'import_variables'
20101111 18:38:51.808 | DEBUG | Created keyword 'Import Variables'
20101111 18:38:51.808 | DEBUG | Got handler method 'length_should_be'
20101111 18:38:51.808 | DEBUG | Created keyword 'Length Should Be'
20101111 18:38:51.808 | DEBUG | Got handler method 'log'
20101111 18:38:51.808 | DEBUG | Created keyword 'Log'
20101111 18:38:51.808 | DEBUG | Got handler method 'log_many'
20101111 18:38:51.808 | DEBUG | Created keyword 'Log Many'
20101111 18:38:51.808 | DEBUG | Got handler method 'log_variables'
20101111 18:38:51.808 | DEBUG | Created keyword 'Log Variables'
20101111 18:38:51.808 | DEBUG | Got handler method 'no_operation'
20101111 18:38:51.824 | DEBUG | Created keyword 'No Operation'
20101111 18:38:51.824 | DEBUG | Got handler method 'regexp_escape'
20101111 18:38:51.824 | DEBUG | Created keyword 'Regexp Escape'
20101111 18:38:51.824 | DEBUG | Got handler method 'remove_tags'
20101111 18:38:51.824 | DEBUG | Created keyword 'Remove Tags'
20101111 18:38:51.824 | DEBUG | Got handler method 'repeat_keyword'
20101111 18:38:51.824 | DEBUG | Created keyword 'Repeat Keyword'
20101111 18:38:51.824 | DEBUG | Got handler method 'replace_variables'
20101111 18:38:51.824 | DEBUG | Created keyword 'Replace Variables'
20101111 18:38:51.824 | DEBUG | Got handler method 'run_keyword'
20101111 18:38:51.824 | DEBUG | Created keyword 'Run Keyword'
20101111 18:38:51.824 | DEBUG | Got handler method
'run_keyword_and_continue_on_failure'
20101111 18:38:51.824 | DEBUG | Created keyword 'Run Keyword And
Continue On Failure'
20101111 18:38:51.824 | DEBUG | Got handler method
'run_keyword_and_expect_error'
20101111 18:38:51.824 | DEBUG | Created keyword 'Run Keyword And
Expect Error'
20101111 18:38:51.840 | DEBUG | Got handler method
'run_keyword_and_ignore_error'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword And
Ignore Error'
20101111 18:38:51.840 | DEBUG | Got handler method 'run_keyword_if'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword If'
20101111 18:38:51.840 | DEBUG | Got handler method
'run_keyword_if_all_critical_tests_passed'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword If All
Critical Tests Passed'
20101111 18:38:51.840 | DEBUG | Got handler method
'run_keyword_if_all_tests_passed'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword If All
Tests Passed'
20101111 18:38:51.840 | DEBUG | Got handler method
'run_keyword_if_any_critical_tests_failed'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword If Any
Critical Tests Failed'
20101111 18:38:51.840 | DEBUG | Got handler method
'run_keyword_if_any_tests_failed'
20101111 18:38:51.840 | DEBUG | Created keyword 'Run Keyword If Any
Tests Failed'
20101111 18:38:51.855 | DEBUG | Got handler method
'run_keyword_if_test_failed'
20101111 18:38:51.855 | DEBUG | Created keyword 'Run Keyword If Test
Failed'
20101111 18:38:51.855 | DEBUG | Got handler method
'run_keyword_if_test_passed'
20101111 18:38:51.855 | DEBUG | Created keyword 'Run Keyword If Test
Passed'
20101111 18:38:51.855 | DEBUG | Got handler method
'run_keyword_if_timeout_occurred'
20101111 18:38:51.855 | DEBUG | Created keyword 'Run Keyword If
Timeout Occurred'
20101111 18:38:51.855 | DEBUG | Got handler method
'run_keyword_unless'
20101111 18:38:51.855 | DEBUG | Created keyword 'Run Keyword Unless'
20101111 18:38:51.855 | DEBUG | Got handler method 'run_keywords'
20101111 18:38:51.855 | DEBUG | Created keyword 'Run Keywords'
20101111 18:38:51.855 | DEBUG | Got handler method
'set_global_variable'
20101111 18:38:51.855 | DEBUG | Created keyword 'Set Global Variable'
20101111 18:38:51.855 | DEBUG | Got handler method
'set_library_search_order'
20101111 18:38:51.855 | DEBUG | Created keyword 'Set Library Search
Order'
20101111 18:38:51.855 | DEBUG | Got handler method 'set_log_level'
20101111 18:38:51.855 | DEBUG | Created keyword 'Set Log Level'
20101111 18:38:51.871 | DEBUG | Got handler method
'set_suite_variable'
20101111 18:38:51.871 | DEBUG | Created keyword 'Set Suite Variable'
20101111 18:38:51.871 | DEBUG | Got handler method 'set_tags'
20101111 18:38:51.886 | DEBUG | Created keyword 'Set Tags'
20101111 18:38:51.886 | DEBUG | Got handler method 'set_test_message'
20101111 18:38:51.886 | DEBUG | Created keyword 'Set Test Message'
20101111 18:38:51.886 | DEBUG | Got handler method 'set_test_variable'
20101111 18:38:51.886 | DEBUG | Created keyword 'Set Test Variable'
20101111 18:38:51.886 | DEBUG | Got handler method 'set_variable'
20101111 18:38:51.886 | DEBUG | Created keyword 'Set Variable'
20101111 18:38:51.886 | DEBUG | Got handler method 'set_variable_if'
20101111 18:38:51.902 | DEBUG | Created keyword 'Set Variable If'
20101111 18:38:51.902 | DEBUG | Got handler method 'should_be_empty'
20101111 18:38:51.902 | DEBUG | Created keyword 'Should Be Empty'
20101111 18:38:51.902 | DEBUG | Got handler method 'should_be_equal'
20101111 18:38:51.902 | DEBUG | Created keyword 'Should Be Equal'
20101111 18:38:51.918 | DEBUG | Got handler method
'should_be_equal_as_integers'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Be Equal As
Integers'
20101111 18:38:51.918 | DEBUG | Got handler method
'should_be_equal_as_numbers'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Be Equal As
Numbers'
20101111 18:38:51.918 | DEBUG | Got handler method
'should_be_equal_as_strings'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Be Equal As
Strings'
20101111 18:38:51.918 | DEBUG | Got handler method 'should_be_true'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Be True'
20101111 18:38:51.918 | DEBUG | Got handler method 'should_contain'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Contain'
20101111 18:38:51.918 | DEBUG | Got handler method
'should_contain_x_times'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should Contain X
Times'
20101111 18:38:51.918 | DEBUG | Got handler method 'should_end_with'
20101111 18:38:51.918 | DEBUG | Created keyword 'Should End With'
20101111 18:38:51.933 | DEBUG | Got handler method 'should_match'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Match'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_match_regexp'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Match Regexp'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_empty'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be Empty'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_equal'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be Equal'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_equal_as_integers'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be Equal
As Integers'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_equal_as_numbers'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be Equal
As Numbers'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_equal_as_strings'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be Equal
As Strings'
20101111 18:38:51.933 | DEBUG | Got handler method
'should_not_be_true'
20101111 18:38:51.933 | DEBUG | Created keyword 'Should Not Be True'
20101111 18:38:51.949 | DEBUG | Got handler method
'should_not_contain'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Not Contain'
20101111 18:38:51.949 | DEBUG | Got handler method
'should_not_end_with'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Not End With'
20101111 18:38:51.949 | DEBUG | Got handler method 'should_not_match'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Not Match'
20101111 18:38:51.949 | DEBUG | Got handler method
'should_not_match_regexp'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Not Match
Regexp'
20101111 18:38:51.949 | DEBUG | Got handler method
'should_not_start_with'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Not Start
With'
20101111 18:38:51.949 | DEBUG | Got handler method 'should_start_with'
20101111 18:38:51.949 | DEBUG | Created keyword 'Should Start With'
20101111 18:38:51.949 | DEBUG | Got handler method 'sleep'
20101111 18:38:51.949 | DEBUG | Created keyword 'Sleep'
20101111 18:38:51.965 | DEBUG | Got handler method
'variable_should_exist'
20101111 18:38:51.965 | DEBUG | Created keyword 'Variable Should
Exist'
20101111 18:38:51.965 | DEBUG | Got handler method
'variable_should_not_exist'
20101111 18:38:51.965 | DEBUG | Created keyword 'Variable Should Not
Exist'
20101111 18:38:51.965 | DEBUG | Got handler method
'wait_until_keyword_succeeds'
20101111 18:38:51.965 | DEBUG | Created keyword 'Wait Until Keyword
Succeeds'
20101111 18:38:51.980 | INFO | Imported library 'BuiltIn' with
arguments [ ] (version 2.5.4, class type, global scope, 79 keywords,
source c:\ironpython\lib\site-packages\robot\libraries\BuiltIn.py)
20101111 18:38:52.027 | DEBUG | Got handler method 'boolean'
20101111 18:38:52.027 | DEBUG | Created keyword 'Boolean'
20101111 18:38:52.027 | DEBUG | Got handler method 'contains'
20101111 18:38:52.027 | DEBUG | Created keyword 'Contains'
20101111 18:38:52.027 | DEBUG | Got handler method 'does_not_contain'
20101111 18:38:52.027 | DEBUG | Created keyword 'Does Not Contain'
20101111 18:38:52.027 | DEBUG | Got handler method 'does_not_end'
20101111 18:38:52.027 | DEBUG | Created keyword 'Does Not End'
20101111 18:38:52.027 | DEBUG | Got handler method 'does_not_match'
20101111 18:38:52.027 | DEBUG | Created keyword 'Does Not Match'
20101111 18:38:52.027 | DEBUG | Got handler method
'does_not_match_regexp'
20101111 18:38:52.027 | DEBUG | Created keyword 'Does Not Match
Regexp'
20101111 18:38:52.027 | DEBUG | Got handler method 'does_not_start'
20101111 18:38:52.043 | DEBUG | Created keyword 'Does Not Start'
20101111 18:38:52.043 | DEBUG | Got handler method 'ends'
20101111 18:38:52.043 | DEBUG | Created keyword 'Ends'
20101111 18:38:52.043 | DEBUG | Got handler method 'equal'
20101111 18:38:52.043 | DEBUG | Created keyword 'Equal'
20101111 18:38:52.043 | DEBUG | Got handler method 'equals'
20101111 18:38:52.043 | DEBUG | Created keyword 'Equals'
20101111 18:38:52.043 | DEBUG | Got handler method 'error'
20101111 18:38:52.043 | DEBUG | Created keyword 'Error'
20101111 18:38:52.043 | DEBUG | Got handler method 'fail_if'
20101111 18:38:52.043 | DEBUG | Created keyword 'Fail If'
20101111 18:38:52.043 | DEBUG | Got handler method 'fail_if_contains'
20101111 18:38:52.043 | DEBUG | Created keyword 'Fail If Contains'
20101111 18:38:52.043 | DEBUG | Got handler method 'fail_if_ends'
20101111 18:38:52.043 | DEBUG | Created keyword 'Fail If Ends'
20101111 18:38:52.043 | DEBUG | Got handler method 'fail_if_equal'
20101111 18:38:52.043 | DEBUG | Created keyword 'Fail If Equal'
20101111 18:38:52.043 | DEBUG | Got handler method
'fail_if_floats_equal'
20101111 18:38:52.043 | DEBUG | Created keyword 'Fail If Floats Equal'
20101111 18:38:52.058 | DEBUG | Got handler method
'fail_if_ints_equal'
20101111 18:38:52.058 | DEBUG | Created keyword 'Fail If Ints Equal'
20101111 18:38:52.058 | DEBUG | Got handler method 'fail_if_matches'
20101111 18:38:52.058 | DEBUG | Created keyword 'Fail If Matches'
20101111 18:38:52.058 | DEBUG | Got handler method
'fail_if_regexp_matches'
20101111 18:38:52.058 | DEBUG | Created keyword 'Fail If Regexp
Matches'
20101111 18:38:52.058 | DEBUG | Got handler method 'fail_if_starts'
20101111 18:38:52.058 | DEBUG | Created keyword 'Fail If Starts'
20101111 18:38:52.058 | DEBUG | Got handler method
'fail_if_variable_exists'
20101111 18:38:52.058 | DEBUG | Created keyword 'Fail If Variable
Exists'
20101111 18:38:52.058 | DEBUG | Got handler method 'fail_unless'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless'
20101111 18:38:52.074 | DEBUG | Got handler method
'fail_unless_contains'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Contains'
20101111 18:38:52.074 | DEBUG | Got handler method 'fail_unless_ends'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Ends'
20101111 18:38:52.074 | DEBUG | Got handler method 'fail_unless_equal'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Equal'
20101111 18:38:52.074 | DEBUG | Got handler method
'fail_unless_floats_equal'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Floats
Equal'
20101111 18:38:52.074 | DEBUG | Got handler method
'fail_unless_ints_equal'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Ints
Equal'
20101111 18:38:52.074 | DEBUG | Got handler method
'fail_unless_matches'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Matches'
20101111 18:38:52.074 | DEBUG | Got handler method
'fail_unless_regexp_matches'
20101111 18:38:52.074 | DEBUG | Created keyword 'Fail Unless Regexp
Matches'
20101111 18:38:52.090 | DEBUG | Got handler method
'fail_unless_starts'
20101111 18:38:52.090 | DEBUG | Created keyword 'Fail Unless Starts'
20101111 18:38:52.090 | DEBUG | Got handler method
'fail_unless_variable_exists'
20101111 18:38:52.090 | DEBUG | Created keyword 'Fail Unless Variable
Exists'
20101111 18:38:52.090 | DEBUG | Got handler method 'float'
20101111 18:38:52.090 | DEBUG | Created keyword 'Float'
20101111 18:38:52.090 | DEBUG | Got handler method 'floats_equal'
20101111 18:38:52.090 | DEBUG | Created keyword 'Floats Equal'
20101111 18:38:52.090 | DEBUG | Got handler method 'floats_not_equal'
20101111 18:38:52.090 | DEBUG | Created keyword 'Floats Not Equal'
20101111 18:38:52.090 | DEBUG | Got handler method 'integer'
20101111 18:38:52.090 | DEBUG | Created keyword 'Integer'
20101111 18:38:52.090 | DEBUG | Got handler method 'ints_equal'
20101111 18:38:52.090 | DEBUG | Created keyword 'Ints Equal'
20101111 18:38:52.105 | DEBUG | Got handler method 'ints_not_equal'
20101111 18:38:52.105 | DEBUG | Created keyword 'Ints Not Equal'
20101111 18:38:52.105 | DEBUG | Got handler method 'is_false'
20101111 18:38:52.105 | DEBUG | Created keyword 'Is False'
20101111 18:38:52.105 | DEBUG | Got handler method 'is_true'
20101111 18:38:52.105 | DEBUG | Created keyword 'Is True'
20101111 18:38:52.105 | DEBUG | Got handler method 'list'
20101111 18:38:52.105 | DEBUG | Created keyword 'List'
20101111 18:38:52.105 | DEBUG | Got handler method 'matches'
20101111 18:38:52.105 | DEBUG | Created keyword 'Matches'
20101111 18:38:52.105 | DEBUG | Got handler method 'matches_regexp'
20101111 18:38:52.105 | DEBUG | Created keyword 'Matches Regexp'
20101111 18:38:52.105 | DEBUG | Got handler method 'message'
20101111 18:38:52.105 | DEBUG | Created keyword 'Message'
20101111 18:38:52.105 | DEBUG | Got handler method 'noop'
20101111 18:38:52.105 | DEBUG | Created keyword 'Noop'
20101111 18:38:52.121 | DEBUG | Got handler method 'not_equal'
20101111 18:38:52.136 | DEBUG | Created keyword 'Not Equal'
20101111 18:38:52.136 | DEBUG | Got handler method 'not_equals'
20101111 18:38:52.136 | DEBUG | Created keyword 'Not Equals'
20101111 18:38:52.136 | DEBUG | Got handler method 'set_'
20101111 18:38:52.136 | DEBUG | Created keyword 'Set'
20101111 18:38:52.136 | DEBUG | Got handler method 'starts'
20101111 18:38:52.136 | DEBUG | Created keyword 'Starts'
20101111 18:38:52.136 | DEBUG | Got handler method 'string'
20101111 18:38:52.136 | DEBUG | Created keyword 'String'
20101111 18:38:52.152 | DEBUG | Got handler method
'variable_does_not_exist'
20101111 18:38:52.152 | DEBUG | Created keyword 'Variable Does Not
Exist'
20101111 18:38:52.152 | DEBUG | Got handler method 'variable_exists'
20101111 18:38:52.152 | DEBUG | Created keyword 'Variable Exists'
20101111 18:38:52.152 | INFO | Imported library 'DeprecatedBuiltIn'
with arguments [ ] (version <unknown>, class type, global scope, 51
keywords, source c:\ironpython\lib\site-packages\robot\libraries
\DeprecatedBuiltIn.py)
20101111 18:38:52.199 | DEBUG | Got handler method 'for'
20101111 18:38:52.199 | DEBUG | Created keyword 'For'
20101111 18:38:52.199 | DEBUG | Got handler method 'while'
20101111 18:38:52.199 | DEBUG | Created keyword 'While'
20101111 18:38:52.199 | DEBUG | Got handler method 'break'
20101111 18:38:52.199 | DEBUG | Created keyword 'Break'
20101111 18:38:52.199 | DEBUG | Got handler method 'continue'
20101111 18:38:52.199 | DEBUG | Created keyword 'Continue'
20101111 18:38:52.199 | DEBUG | Got handler method 'end'
20101111 18:38:52.199 | DEBUG | Created keyword 'End'
20101111 18:38:52.199 | DEBUG | Got handler method 'if'
20101111 18:38:52.199 | DEBUG | Created keyword 'If'
20101111 18:38:52.199 | DEBUG | Got handler method 'else'
20101111 18:38:52.199 | DEBUG | Created keyword 'Else'
20101111 18:38:52.199 | DEBUG | Got handler method 'elif'
20101111 18:38:52.199 | DEBUG | Created keyword 'Elif'
20101111 18:38:52.199 | DEBUG | Got handler method 'else if'
20101111 18:38:52.199 | DEBUG | Created keyword 'Else If'
20101111 18:38:52.199 | DEBUG | Got handler method 'return'
20101111 18:38:52.199 | DEBUG | Created keyword 'Return'
20101111 18:38:52.199 | INFO | Imported library 'Reserved' with
arguments [ ] (version <unknown>, dynamic type, global scope, 10
keywords, source c:\ironpython\lib\site-packages\robot\libraries
\Reserved.py)
20101111 18:38:52.199 | DEBUG | Got handler method 'none_shall_pass'
20101111 18:38:52.199 | DEBUG | Created keyword 'None Shall Pass'
20101111 18:38:52.215 | INFO | Imported library 'Easter' with
arguments [ ] (version <unknown>, module type, global scope, 1
keywords, source c:\ironpython\lib\site-packages\robot\libraries
\Easter.py)
20101111 18:38:52.246 | INFO | Parsing file 'd:\ironpy_robot
\global.html'.
20101111 18:38:52.277 | INFO | Imported resource file 'd:\ironpy_robot
\global.html' (0 keywords).
20101111 18:38:52.308 | DEBUG | Got handler method 'myapp'
20101111 18:38:52.308 | DEBUG | Created keyword 'Myapp'
20101111 18:38:52.308 | DEBUG | Got handler method 'start_application'
20101111 18:38:52.308 | DEBUG | Created keyword 'Start Application'
20101111 18:38:52.308 | INFO | Imported library 'rftest' with
arguments [ ] (version <unknown>, class type, global scope, 2
keywords, source d:\ironpy_robot\rftest.py)
20101111 18:38:52.308 | INFO | Found test library 'BuiltIn' with
arguments [ ] from cache
20101111 18:38:52.308 | INFO | Test library 'BuiltIn' already
imported by suite 'Syslog'
20101111 18:38:52.308 | INFO | Found test library 'rftest' with
arguments [ ] from cache
20101111 18:38:52.308 | INFO | Test library 'rftest' already imported
by suite 'Syslog'
20101111 18:38:52.433 | ERROR | Unexpected error: ValueError: Index
was out of range. Must be non-negative and less than the size of the
collection.
Parameter name: startIndex
20101111 18:38:52.433 | INFO | Traceback (most recent call last):
File "C:\IronPython\Lib\site-packages\robot\__init__.py", line 78,
in _run_or_rebot_from_cli
suite = method(*datasources, **options)
File "C:\IronPython\Lib\site-packages\robot\__init__.py", line 118,
in run
suite.run(output)
File "C:\IronPython\Lib\site-packages\robot\running\model.py", line
114, in run
context = self._start_run(output, parent, errors)
File "C:\IronPython\Lib\site-packages\robot\running\model.py", line
133, in _start_run
output.start_suite(self)
File "C:\IronPython\Lib\site-packages\robot\output\output.py", line
62, in start_suite
LOGGER.start_suite(suite)
File "C:\IronPython\Lib\site-packages\robot\output\logger.py", line
125, in start_suite
logger.start_suite(suite)
File "C:\IronPython\Lib\site-packages\robot\output\xmllogger.py",
line 103, in start_suite
self._writer = self._get_writer(*self._writer_args)
File "C:\IronPython\Lib\site-packages\robot\output\xmllogger.py",
line 45, in _get_writer
writer.start('robot', attrs)
File "C:\IronPython\Lib\site-packages\robot\utils\pyxmlwriter.py",
line 35, in start
self.content('\n')
File "C:\IronPython\Lib\site-packages\robot\utils\pyxmlwriter.py",
line 39, in content
self._writer.characters(self._encode(content))
File "C:\IronPython\Lib\site-packages\robot\utils
\abstractxmlwriter.py", line 46, in _encode
message = message.replace(char, '')


Pekka Klärck

unread,
Nov 11, 2010, 9:09:27 AM11/11/10
to palani...@gmail.com, robotframework-users
2010/11/11 tmpalaniselvam <palani...@gmail.com>:

> Hi Pekka
>
> Syslog - contents are posted here:
>
> -----
[snip]

> 20101111 18:38:52.433 | ERROR | Unexpected error: ValueError: Index
> was out of range. Must be non-negative and less than the size of the
> collection.
> Parameter name: startIndex
> 20101111 18:38:52.433 | INFO  | Traceback (most recent call last):
[snip]

>  File "C:\IronPython\Lib\site-packages\robot\utils
> \abstractxmlwriter.py", line 46, in _encode
>    message = message.replace(char, '')

This looks like a bug in IronPython to me. Could you try changing
lines close to line 46 in
C:\IronPython\Lib\site-packages\robot\utils\abstractxmlwriter.py from

for char in _ILLEGAL_CHARS_IN_XML:
message = message.replace(char, '')

to

for char in _ILLEGAL_CHARS_IN_XML:
if char in message:
message = message.replace(char, '')

Pekka Klärck

unread,
Nov 11, 2010, 9:55:54 AM11/11/10
to Palani Selvam, robotframework-users
2010/11/11 Palani Selvam <palani...@gmail.com>:
> Hi Pekka,
>  It is worked for me. Thanks a lot... I tried a sample. It worked fine..

Great. I investigated this a bit more and confirmed that it was a bug
in IronPython:
http://ironpython.codeplex.com/workitem/29402

We can workaround this problem and probably do also other changes
necessary to get Robot to at least run on IronPython already in RF
2.5.5.

>  I just heard that Microsoft has stopped funding for Iron* languages. How do
> you feel about spending time on IronPython is worth for my project or not?
>
> Pls have a look at ->
> http://www.tikalk.com/net/future-ironruby-and-ironpython

Microsoft not anymore actively supporting IronPython isn't obviously
that good news for the project. It shouldn't be a disaster, though, as
Jython or even Python itself isn't backed by only one big corporation.
It remains seen how well the IronPython community can maintain the
project, but at least I'm pretty confident.

Pekka Klärck

unread,
Nov 11, 2010, 12:13:56 PM11/11/10
to robotframework-users
Hi all,

I implemented the fixes/workarounds discussed in this mail thread and
now running Robot Framework on IronPython 2.6 is relatively
straightforward. Basically you just need to install elementree module
in addition to the IronPython 2.6(.1) and running tests should work
fine. Because the changes I did are not yet in any released version
(they will be included to RF 2.5.5) you also need to checkout the
latest Robot source code yourself. For more detailed instructions with
download links see
http://code.google.com/p/robotframework/issues/detail?id=154#c16

I'm looking forward for feedback how well Robot now actually works on
IronPython. If further enhancements are needed, including them to RF
2.5.5 is possible. The biggest missing piece I see is automatically
creating ipybot start-up script or otherwise handling start-up nicely.

Reply all
Reply to author
Forward
0 new messages