> >>> list(chain.from_iterable(starmap(product, izip(izip(dims.iterkeys()),
>
> dims.itervalues()
> [('special', '+'), ('special', '-'), ('number', 1), ('number', 2),
> ('number', 3), ('letter', 'a'), ('letter', 'b')]
>
> Peter
so far I have never noticed chain.from_iterable, but many thanks t
I am about to learn Higher-Order-Programming with Lisp, Haskell, and
Python. Some people who have gone completely out of their mind call
this FP.
In Haskell I learned that when I use map on a list it starts nesting
as soon as I start adding elements. If I do not like the nesting I use
ConcatMap.
I used send instead. This should work.
-Mark
--
http://mail.python.org/mailman/listinfo/python-list
Hi there,
I have a source file FailFixture.py in the folder
D:\AUT_TEST\workspace\JyFIT\testutil. Now I want to import the file
with "import testutil.FailFixture". Unfortunately I could not figure
out how to set this up. I am convinced that
"D:\AUT_TEST\workspace\JyFIT" should be included in the p
Hi there,
I am about to port a server application from Java to Jython. For the
socket part I found some examples written in Python. I have problems to
figure out the socket part of the application. In Jython 2.1 the
sendall function is missing?
def establishConnection(self):
self.socke
Hi Kent,
many thanks for your help! In the meantime I received my "Jython
Essentials" book and hope that I have much fewer questions in the near
future.
One last question for this thread. I tried to inherit from a Java class
and override on method. I figured that this approach was nonsense
because
thanks to the help of this group I moved a tiny step forward. Obviously
it is not possible to resolve name localhost:
Type "copyright", "credits" or "license" for more information.
>>> import socket
>>> s=socket.socket(socket.AF_INET, socket.SOCK_STREAM)
>>> s.connect(localhost, 8080)
Traceback (in
I try to port a server application to Jython. At the moment I use
Jython21\Lib\socket.py
Currently I do face problems with casting the string "localhost" to the
desired value:
D:\AUT_TEST\workspace\JyFIT>jython fit/JyFitServer2.py localhost 1234
23
['fit/JyFitServer2.py', 'localhost', '1234', '23']
Please enlighten me. This seemed so easy yust inherit from a Java class
overwrite one method - done. At the moment I do not know how to proceed
:-((
Jython or jythonc?
==
In general is it better to run programms with the jython interpreter or
is it better to compile them first? I ha
I observed something strange when I tried to compile the jython class:
D:\AUT_TEST\workspace\JyFIT\fit>jythonc JyFitServer.py
processing JyFitServer
Required packages:
fitnesse.util
java.io
java.net
fitnesse.components*
Creating adapters:
Creating .java files:
JyFitServer module
Jy
Alan, Kent, many thanks this really helped!
But there is still a problem I guess with inheritance. I use the java
testsuit supplied with the original to test the server. If I use the
Java FitServer the testsuite can be completed. I commented everything
out from my class and it does not work??
Thats
Exception, e:
self.exception(e)
Please help,
Mark Fink
--
http://mail.python.org/mailman/listinfo/python-list
:-))) it works!
I replaced it to "return eval(s)" and the results look extremely well
guess I should get one of this crystal balls myself.
one minor issue is still left:
correct me if I am wrong: result of 2/-3 is 0 (at least this is how it
is defined in the testcase)
In Jython 2.1.3:
>>> 2/-3
-1
This is the original code section of the library including the
comments:
class AutoAdapter(TypeAdapter):
"""
This adapter returns a type based on the format of the table cell
contents, following python's rules for literals (plus a few
others).
We could fall back on this when we don'
this is really funny...
I tried to use eval(String) as an replacement. It works now but the
calculation results from my tests are not as expected: 2 + 3 = 23 !!! 2
- 3 = 2-3...
I have the feeling that there is a really easy solution for this.
Unfortunately I have no enough experience
--
http://ma
sorry for the double post!
It is the r_eval() functionality of the rexec module I am looking
forward to replace
--
http://mail.python.org/mailman/listinfo/python-list
Hi there,
I at the moment port a library from Python to Jython (at lease I try to
do so :-))). The library uses the Rexec to form a type adapter to cast
parameters given as text into the according Jython type. I learned
rexec is not available in Jython. Is something that is commonly used in
Jython
Hi there,
I at the moment port a library from Python to Jython (at lease I try to
do so :-))). The library uses the Rexec to form a type adapter to cast
parameters given as text into the according Jython type. I learned
rexec is not available in Jython. Is something that is commonly used in
Jython
Hi there,
unfortunately I am new to Jython and my "Jython Essentials" book is
still in the mail. I looked into the Jython API Doc but could not find
the information.
I am porting a Python library to Jython and some parts are missing. My
question basically is where do I find information on what to
that it is possible to use Fitnesse and Java Fit and involve
Jython testcases with this configuration but I do not know how. Perhaps
someone from this group has done this before and wants to share some
tipps with me.
Cheers,
Mark Fink
http://www.mark-fink.de
--
http://mail.python.org/mailman
20 matches
Mail list logo