Re: viewcvs 1.0 dev

2005-12-28 Thread Robin Becker
Uwe Hoffmann wrote: > Robin Becker schrieb: > >>Does anyone know the status of the svn handling version of viewCVS. > > > http://viewvc.tigris.org/index.html unfortunately there's no mention of svn handling there and the files only show 0.9[.x] versions.

Re: viewcvs 1.0 dev

2005-12-28 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker wrote: > >>Does anyone know the status of the svn handling version of viewCVS. > > > It works: > > http://svn.python.org/view/ > > Regards, > Martin yes I ahd it working and updated my freebsd and then couldn't lo

Re: viewcvs 1.0 dev

2005-12-28 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker wrote: > >>yes I ahd it working and updated my freebsd and then couldn't locate the >>latest version. If the svn head stuff from tigris works that'll do. On >>another point I thought the whole point of sourceforge was tha

Re: Dr. Dobb's Python-URL! - weekly Python news and links (Jan 3)

2006-01-03 Thread Robin Becker
rey goo we get to say "so you're a derivate of C. Tismer, how cool" :) -fleeingly yrs- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Spelling mistakes!

2006-01-08 Thread Robin Becker
y >>different meanings? > > >The words overlap in meaning. Both can mean to disparage or >belittle. > >Some dictionaries give 'depreciate' as a definition of 'deprecate'. > > Well if someone told me my investments were deprecated I&#

Mysterious non-module A.sys

2006-01-10 Thread Robin Becker
e from? I tried an experiment and it seems that it's the import statement in B.py so if I changed that to import sys,socket I also get A.socket so I assume it's the import within import that causes these strange modules to appear. Strangely, attempts to import A.sys fail and its value in sys.modules is None. What is the entry for? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Mysterious non-module A.sys

2006-01-10 Thread Robin Becker
Fredrik Lundh wrote: .. >> >>where does A.sys come from? > > > http://www.python.org/doc/essays/packages.html > > "Dummy Entries in sys.modules ... > > ... thanks -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

flatten a level one list

2006-01-11 Thread Robin Becker
,y2,]) --> [x0,y0,x1,y1,] clearly if f is doable then g can be done using zip. I suppose this is a special case flatten, but can flatten be done fast? The python recipes seem rather slow compared to the builtin functions. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: flatten a level one list

2006-01-12 Thread Robin Becker
tc etc A fast implementation would probably allocate the output list just once and then stream the values into place with a simple index. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: flatten a level one list

2006-01-12 Thread Robin Becker
'''D Murman''' return list(_flatten(zip(x, y))) def flatten6(x,y): '''Tim Hochberg''' n = min(len(x), len(y)) result = [None] * (2*n) for i in xrange(n): result[2*i] = xdata[i] result[2*i+1]

Re: flatten a level one list

2006-01-13 Thread Robin Becker
1]' 'i(xdata, ydata, pad=None)' > 1 loops, best of 3: 46.4 usec per loop > > Not overwhelming, but I expect the difference to grow when the arguments > occupy a significant portion of the available memory. > > Peter very nice indeed; another generalization

Re: reportlab - ttf justify

2006-01-19 Thread Robin Becker
hat has gone in to the code now, but I'm not sure if it is on the stable branch or not. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

strange error when importing a module

2006-07-20 Thread Robin Becker
not defined SimpleXMLRPCServer.py is a legacy version of the current SimpleXMLRPCserver code. I don't think there's anything special about it and as a standalone script it appears to work fine (ie it seems to compile and run). Any ideas? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: strange error when importing a module

2006-07-20 Thread Robin Becker
Robin Becker wrote: > I'm trying to understand the following strangeness > > C:\code\rlextra\ers>python > Python 2.4.3 (#69, Mar 29 2006, 17:35:34) [MSC v.1310 32 bit (Intel)] on win32 > Type "help", "copyright", "credits

Re: IronPython and scipy/pyExcelerator

2006-07-21 Thread Robin Becker
Thomas Philips > I don't think so unless scipy has a release for .net. I think all those nice algorithms are in C or Fortran and mostly haven't been translated into C#. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Python2.5 RC1 vs sgmlop.c

2006-08-17 Thread Robin Becker
hought that malloc/realloc/free were appropriate. Another parser attribute does hold an array of pointers to python objects, but again I don't think that should be a problem. Has anyone got any clue what the problem might be or a fixed version of the code? -- Robin Becker -- http://mail.pyth

Re: Python2.5 RC1 vs sgmlop.c

2006-08-17 Thread Robin Becker
Robin Becker wrote: > I have a segfault problem in Python2.5 RC1 (win32) when using the venerable > extension sgmlop.c. .. > Has anyone got any clue what the problem might be or a fixed version of the > code? I think this is PyObject_NEW mixed with PyMem_DEL, I thought that had a

Re: Python2.5 RC1 vs sgmlop.c

2006-08-17 Thread Robin Becker
Steve Holden wrote: > Robin Becker wrote: ... >> Has anyone got any clue what the problem might be or a fixed version of the >> code? > > I'm guessing this might be to do with the changes that have been made to > enable 64-bit readiness in the code, but

Re: Python2.5 RC1 vs sgmlop.c

2006-08-17 Thread Robin Becker
[EMAIL PROTECTED] wrote: > Robin> Just replaced three PyMem_DEL's with PyObject_FREE and things now > Robin> work again. > > Can you send me a patch? > > Thx, > > Skip On its way -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

amd64

2006-08-18 Thread Robin Becker
pile/debug all the extensions etc etc for another architecture it might not seem so attractive. -not ready for 64bitly yrs- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
rong as we are comparing a number with a negated number; the bits might drop off in 32 bits, but not in 64. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
Travis E. Oliphant wrote: > Robin Becker wrote: > NumPy defines an array and an array scalar for all signed and unsigned > integers defined in C. > > import numpy as nx > type(nx.array([1,2,3],dtype=nx.uint32)[0]) > > great, but do we have a pure python v

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker schrieb: >> Hi, just trying to avoid wheel reinvention. I have need of an unsigned >> 32 bit arithmetic type to carry out a checksum operation and wondered if >> anyone had already defined such a beast. >> >> Our current cod

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
Paul Rubin wrote: > Robin Becker <[EMAIL PROTECTED]> writes: >>> type(nx.array([1,2,3],dtype=nx.uint32)[0]) >>> >> great, but do we have a pure python version? > > array.array('L', [1,2,3]) yes that works if @L is unsigned 32 bit. I guess >L

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker schrieb: >> def add32(x, y): >> "Calculate (x + y) modulo 2**32" >> return ((x&0xL)+(y&0xL)) & 0xL > > That's redundant; it is sufficient to write > >

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
l, but I don't think I can ask people to add numpy to the list of requirements for reportlab :) I used to love its predecessor Numeric, but it was quite large. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: unsigned 32 bit arithmetic type?

2006-10-25 Thread Robin Becker
impact on the result. All hail congruency classes. I still miss the CDC 6000's where we had two zeroes :) -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: unsigned 32 bit arithmetic type?

2006-10-26 Thread Robin Becker
sturlamolden wrote: > Robin Becker wrote: > >> it's probably wonderful, but I don't think I can ask people to add numpy to >> the >> list of requirements for reportlab :) > > This was Matlab, but the same holds for Python and NumPy. The overhea

Re: Exploiting Dual Core's with Py_NewInterpreter's separated GIL ?

2006-11-09 Thread Robin Becker
rhaps there's something I need to do to allow them to work. > Paul > -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Exploiting Dual Core's with Py_NewInterpreter's separated GIL ?

2006-11-09 Thread Robin Becker
Andrew MacIntyre wrote: > Robin Becker wrote: > >> I think it uses sysv semaphores and although freeBSD 6 has them >> perhaps there's something I need to do to allow them to work. > > IIRC, you need to explicitly configure loading the kernel module, or > compi

Re: Exploiting Dual Core's with Py_NewInterpreter's separated GIL ?

2006-11-10 Thread Robin Becker
Robin Becker wrote: > Andrew MacIntyre wrote: >> Robin Becker wrote: >> >>> I think it uses sysv semaphores and although freeBSD 6 has them >>> perhaps there's something I need to do to allow them to work. >> IIRC, you need to explicitly configure

Re: Exploiting Dual Core's with Py_NewInterpreter's separated GIL ?

2006-11-11 Thread Robin Becker
emaphore parameters that can be set in the kernel config. > yes those limits look pretty low. I think POSH grabs 60 the first time and then fails the second as the limit appears to be 61. I wonder what the actual cost is of having lots of semaphores. -- Robin Becker -- http://mail.python.

Re: MySQLdb windows binaries for Python 2.5??

2006-11-11 Thread Robin Becker
y. It seems mysql-5.0.27 for win32 doesn't have mysql-config.exe so the setup fails rather miserably. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Multiple Polynomial Quadratic Sieve

2006-05-30 Thread Robin Becker
is available via FTP at > http://www.pythonstuff.pwp.blueyonder.co.uk/ > account: python password: guest > not sure I can help, but clicking on that http link produces a 404 for me. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

py2exe & tkinter

2006-06-12 Thread Robin Becker
th the new bundle_files option it should be possible to integrate our tcl/tk stuff into a common library.zip as that seems to be the method used by freewrap. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: py2exe & tkinter

2006-06-12 Thread Robin Becker
Robin Becker wrote: > Don't know if this is the right place to ask, but has anyone considered using > something like tcl's freewrap code to integrate tkinter into py2xe single > executables? > > We currently use the (fairly clunky) nsis route to create single file >

Re: Kamaelia 0.4.0 RELEASED - Faster! More Tools! More Examples! More Docs! ;-)

2006-06-24 Thread Robin Becker
libc.so.6 I get a Windows error from the statement libc = cdll.LoadLibrary("/lib/libc.so.6") This allows somethings to run eg AxonVisualiser.py --navelgaze but I'm not sure if the results are really unaffected by not having a real yielder. The diagram appears, but doe

Re: Kamaelia 0.4.0 RELEASED - Faster! More Tools! More Examples! More Docs! ;-)

2006-06-24 Thread Robin Becker
Robin Becker wrote: > Michael wrote: >> Hi! >> >> >> (OK, slightly silly subject line :) >> >> I'm extremely pleased to say - Kamaelia 0.4.0 has been released! >> . whoops, forgot to say thanks as I think this is very nice work -- Robin Becker

Embedded python problem

2006-07-03 Thread Robin Becker
ely somehow, but that won't work if in fact the second environment is in fact not the same as the other. Is there some way to work out if I'm in the same interpreter if in fact we're joining the DLL in two places perhaps? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Detecting 64bit vs. 32bit Linux

2006-07-10 Thread Robin Becker
to remember some compilers allowing pure 32 bit addressing on 8088 machines (with 16 bit registers), but I think the M$ compilers all had near and far pointer mechanisms to help you get confused. -mumbling-ly yrs- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Python-2.5beta1 crash

2006-07-10 Thread Robin Becker
= First off there may be a bunch of other C extensions involved including PIL, but I built them all against this beta. What should I do to refine the error? Do I start with trying to establish which of the tests is guilty or build from source in debug mode and attempt to fi

Re: Python-2.5beta1 crash

2006-07-10 Thread Robin Becker
y and pin down first the test file and then the statement; then try and figure out whether it's worth doing a debug build. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: IronPython 1.0 - Bugs or Features?

2006-09-06 Thread Robin Becker
ile(r'\\.\PhysicalDrive0', 'rb') >>> f I have used similar to get boot sectors etc, but then did you really think Bill would let us play with our own hardware? Just wait till DRM gets here. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: No ValueError for large exponents?

2006-09-06 Thread Robin Becker
gt; and language definition vs language implementation, etc.? > I suspect the hang may be python actually trying to work out the 1 followed by 735293857239475 zeroes. Perhaps IronPython has a forward looking algorithm that knows when to give up early. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Help me use my Dual Core CPU!

2006-09-13 Thread Robin Becker
quickly or we'll all end up using erlang :) As for subprocess I don't see it as much use unless we can at least determine the number of cpu's and also set the cpu affinity easy with occam maybe not in python. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Help me use my Dual Core CPU!

2006-09-13 Thread Robin Becker
Paul Rubin wrote: > Robin Becker <[EMAIL PROTECTED]> writes: >> Nobody seems to have mentioned POSH http://poshmodule.sourceforge.net >> which used almost to work. I assume it's busted for later pythons and >> the author says it's just a demonstr

Re: Help me use my Dual Core CPU!

2006-09-13 Thread Robin Becker
Paul Rubin wrote: > Robin Becker <[EMAIL PROTECTED]> writes: >> No I think they tried to just run a lot of processes at once and they >> got the 8 core by just substituting the two dual cores with two quads. > > Huh?! There are no quad core x86 cpu's as far as I k

Re: PATCH: Speed up direct string concatenation by 20+%!

2006-09-29 Thread Robin Becker
+ c), > it *doesn't* compute the intermediate strings (a + b). > > Upsides to this approach: wouldn't this approach apply to other additions eg list+list seq+seq etc etc. I suppose the utility of such an approach depends on the frequency with which multiple string

Re: Graph Data Structures

2006-11-25 Thread Robin Becker
Szabolcs Nagy wrote: > if you only want to do some analysis i think you need this one (as it's > pretty complete and simple): > https://networkx.lanl.gov/ seems to be broken at present with a python traceback coming out; not a good advert for python and/or trac --

Re: Graph Data Structures

2006-11-25 Thread Robin Becker
ed mode args = ('instance.__dict__ not accessible in restricted mode',) perhaps I'm seeing different apache processes or something -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Resource cleanup

2006-12-03 Thread Robin Becker
referring to a global in a method is actually a reference to that global or does the reference only occur when the code is executed? I have a vague feeling that I came across problems in the past about the order in which modules were finalized. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Resource cleanup

2006-12-03 Thread Robin Becker
ck your ass somewhere anyhow. I think this must be the right approach. Either the resources or the cleaner should hold everything required for cleanup. Probably the resource is the best place. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Printing Barcodes from webapp?

2006-12-06 Thread Robin Becker
over! well the code in reportlab/graphics/barcodes that deals with it should be adaptable if you're interested (only around 300 lines). I have a feeling that the UK/AU 4state codes aren't as exotic, but not having actually implemented them it's hard to say. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: merits of Lisp vs Python

2006-12-15 Thread Robin Becker
m Delaney is it time to mention the storm troopers and A H*? This thread certainly needs shutting down :) -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: cxfrozen linux binaries run on FreeBSD?

2006-12-15 Thread Robin Becker
> >> On Dec 15, 5:52 am, robert <[EMAIL PROTECTED]> wrote: >>> When i freeze a python app (simple - no strange sys calls) for x86 Linux, >>> does this stuff run well also on x86 FreeBSD? >>> >>> Robert I would guess not, but perhaps you c

Re: cxfrozen linux binaries run on FreeBSD?

2006-12-15 Thread Robin Becker
Robin Becker wrote: > robert wrote: >> i80and wrote: >>> I haven't personally used freeze (Kubuntu doesn't seem to install it >>> with the python debs), but based on what I know of it, it makes make >>> files. I'm not a make expert, but if Fre

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Robin Becker
guessing there might be a case sensitivity issue in the unpacking somewhere. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Robin Becker
le the console+debug mode > and see what the traceback is. I'd be very glad to fix the problem for you. No problem I'll give it a whirl tomorrow. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: [ANN] PyInstaller 1.3 released

2006-12-20 Thread Robin Becker
le the console+debug mode > and see what the traceback is. I'd be very glad to fix the problem for you. No problem I'll give it a whirl tomorrow. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: [ANN] PyInstaller 1.3 released

2006-12-21 Thread Robin Becker
Robin Becker wrote: > Giovanni Bajo wrote: > >> yeah that's pretty cryptic. It's a known bug which I need to come around >> and fix it. Anyway, the message itself is harmless: if the program then >> exits, there is *another* problem. >> >> I

per interpreter storage for C extensions

2006-12-28 Thread Robin Becker
en a way to tell which interpreter I'm being called in? Anything too costly will probably bust any speedup. Luckily I don't think we have too many of these cached variables so it's possible we may be able to get away with just dropping the caching for some and eliminating others

Re: per interpreter storage for C extensions

2006-12-28 Thread Robin Becker
Chris Mellon wrote: > On 12/28/06, Robin Becker <[EMAIL PROTECTED]> wrote: >> As part of some django usage I need to get some ReportLab C extensions into a >> state where they can be safely used with mod_python. . >> > > Just off the top of my head,

Re: per interpreter storage for C extensions

2006-12-28 Thread Robin Becker
Robin Becker wrote: > Chris Mellon wrote: >> On 12/28/06, Robin Becker <[EMAIL PROTECTED]> wrote: >>> As part of some django usage I need to get some ReportLab C extensions into >>> a >>> state where they can be safely used with mod_python. > ..

Re: per interpreter storage for C extensions

2006-12-30 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker schrieb: >> Is there a simple/cheap way for C code to cache these sorts of module >> level globals on a per interpreter basis? Is there even a way to tell >> which interpreter I'm being called in? > > There is no cheap way to

Re: good library for pdf

2006-01-26 Thread Robin Becker
n has a prebuilt action that applies a watermark to pdfs. > Transparency, size and placement are all editable. Obviously, no use if > you want to do this with Python, but it might suit your needs. > > Rob C > -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

frozen codecs

2006-02-23 Thread Robin Becker
I'm having a problem with freeze vs Python-2.4. I need to get various codecs into the freeze, but suspect I need to explicitly import them. Must I just import codecs or all the ones I'm likely to use? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: django and mod_python

2006-03-05 Thread Robin Becker
[EMAIL PROTECTED] wrote: > Hi, > > I read the mod_python documentation on the Django site but I'm getting > this error: > > EnvironmentError: Could not import DJANGO_SETTINGS_MODULE > 'accesshiphop.settings' (is it on sys.path?): No module named > accesshiphop.settings > > Here's my httpd.conf:

python24.zip

2005-05-20 Thread Robin Becker
the default for some other kind of python installation? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: python24.zip

2005-05-21 Thread Robin Becker
's import hook treatment > > When there is an importer "i" for a path "p" and > this importer cannot find module "m", then "p" is > treated as a directory and 5 file system operations > are tried to locate "p/m".

detached subprocess

2005-05-23 Thread Robin Becker
before the child ends its sleep. Of course it may be that it's just the handles that are being held. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: detached subprocess

2005-05-23 Thread Robin Becker
Robin Becker wrote: . > before the child ends its sleep. Of course it may be that it's just the > handles > that are being held. After further tests with procexp it seems that the parent is allowed to die, but its output is held up (perhaps apache is waiting on an eof) u

Re: python24.zip

2005-05-23 Thread Robin Becker
porting from them > may still succeed if though stat fails. so is there implication of multiplicative behaviour? ie if we have N importers and F leading failure syspath entries before the correct one is found do we get order N*F failed stats/opens etc etc? -- Robin Becker -- http

Re: python24.zip

2005-05-23 Thread Robin Becker
Martin v. Löwis wrote: > Robin Becker wrote: > >>ie if we have N importers and F leading failure syspath entries before >>the correct one is found do we get order N*F failed stats/opens etc etc? > > > No. Each path hook is supposed to provide a decision as to whether

BUG pythonw vs subprocess

2005-06-01 Thread Robin Becker
._make_inheritable(p2cread) File "c:\python\lib\subprocess.py", line 650, in _make_inheritable DUPLICATE_SAME_ACCESS) WindowsError: [Errno 6] The handle is invalid C:\Tmp> -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: BUG pythonw vs subprocess

2005-06-02 Thread Robin Becker
ible to get pythonw apps eg tkinter guis to use subprocess properly? Seems a bit daft to me. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: BUG pythonw vs subprocess

2005-06-02 Thread Robin Becker
stdin, but I don't know how to tell it to ignore stdin. The value None seems to be used to signal that the existing stdin is used and that fails. I believe the solution is just to use PIPE for stdin as well and then I don't have to write to it. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: For review: PEP 343: Anonymous Block Redux and Generator Enhancements

2005-06-04 Thread Robin Becker
Ilpo Nyyssönen wrote: ... > > with locking(mutex), opening(readfile) as input: > ... with EXPR as x: BLOCK EXPR can be a tuple so the above would be ambiguous. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

SimpleXMLRPCServer security

2005-06-04 Thread Robin Becker
. Switching uid at startup allows the client code to be private; so is that a strategy for protecting the encryption/decryption which obfuscates the xmlrpc channel? Anyone done this sort of thing before? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: For review: PEP 343: Anonymous Block Redux and Generator Enhancements

2005-06-04 Thread Robin Becker
Kent Johnson wrote: > Robin Becker wrote: > >> Ilpo Nyyssönen wrote: >> >>> >>> with locking(mutex), opening(readfile) as input: >>> ... >> >> >> with EXPR as x: >> BLOCK >> >> EXPR can be a tuple so the a

Re: Q: functional/equational language, smells a little of Python

2005-06-05 Thread Robin Becker
John J. Lee wrote: > > What's a fast object library? > ferrarilib :) -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

subprocess module and blocking

2005-06-12 Thread Robin Becker
a process state of POLL). I assume that the subprocess is filling up the pipe and then failing to wake up again. I had expected that subprocess would take care of this for me, but possibly I'm being utterly clueless and stupid. What should I do to avoid blocking in the subprocess? -

Re: subprocess module and blocking

2005-06-14 Thread Robin Becker
d data. > Unfortunately select isn't an option for windows (I think that's only for sockets). I guess I need to read repeatedly from the stdout etc to get the output. Clearly the poll call can't return a status until we've finished reading. > > Dieter -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

non OO behaviour of file

2005-06-15 Thread Robin Becker
def write(self,s): self._f.write(s) if '\n' in s: self._f.flush() I wondered if I could make a file subclass somehow fail the PyFile_Check which allows the optimization. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: non OO behaviour of file

2005-06-15 Thread Robin Becker
s not a better way that I know of. I keep a > slightly-more generalized Surrogate class around to deal with this > pattern, and then my LineFlusherFile would be a subclass of that. But > it's the same thing, really. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: non OO behaviour of file

2005-06-15 Thread Robin Becker
Jp Calderone wrote: > On Wed, 15 Jun 2005 16:38:32 +0100, Robin Becker <[EMAIL PROTECTED]> wrote: > >>Michael Hoffman wrote: >>. >> >>>Well, you could use python -u: >>> >> >>unfortunately this is in a detached process and I am ju

pyhon 2.5.1 build fails

2007-06-04 Thread Robin Becker
ata.o so I guess it's not being built for some reason. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: pyhon 2.5.1 build fails

2007-06-04 Thread Robin Becker
Robin Becker wrote: > I am getting an error while building python-2.5.1 on a freebsd 6.1 machine as > a > normal user > > ./configure --prefix=/home/me/mypython --enable-unicode=ucs2 > > seems to work fine, but make install fails whilst running > > Compiling > /

safe cgi parameter

2007-06-04 Thread Robin Becker
_ a<&>b ie always wrap the value, but access to the original is possible via __raw__. However, if you do anything like x.strip() the original is lost. I'm not sure that's a bad thing, but I thought I would ask what others do for this problem. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: Baffled on Windows.

2007-06-07 Thread Robin Becker
s shadowed so then we start having to recur and we'll have names like my_my_new.py my_my_list.py .. my_my_my_new.py . I leave as an exercise the algorithm which chooses the appropriate version of new/list to use :) -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: The Modernization of Emacs

2007-06-18 Thread Robin Becker
t they go very deep. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

avoid script running twice

2007-06-18 Thread Robin Becker
work(). Is there a smart way to avoid running simultaneously. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: avoid script running twice

2007-06-18 Thread Robin Becker
(or whether to do some of the > remaining work, etc.). > that might work, but this runs on someone's java solaris box with possible many connections going on. I doubt I'd be able to guarantee a particular port. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: avoid script running twice

2007-06-18 Thread Robin Becker
Wildemar Wildenburger wrote: > Robin Becker wrote: > > Well I can think of a dumb way: create a temporary file during the > transaction and have your script check for that before running its main > body. > > > I think thats the most hassle free way of doing

Re: avoid script running twice

2007-06-19 Thread Robin Becker
.errno != EAGAIN: > raise > print >>sys.stderr, "exiting, another copy currently running" > > import time > time.sleep(2) > > (I tested it on linux only!) > many interesting suggestions, unfortunately I'm not exactly sure about the filesystem to be used. I think it might be some kind of NFS which might impact some of these solutions. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: simplifying algebraic expressions

2007-06-26 Thread Robin Becker
mework. The implication is that you know better than the overall fitness requirement. The additional expressions and redundancies allow for extra mutation and combination possibilities which is a good thing for the whole population. If you must, add the requirement to the target ie gi

16bit hash

2007-06-27 Thread Robin Becker
Is the any way to get an efficient 16bit hash in python? -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: 16bit hash

2007-06-27 Thread Robin Becker
Josiah Carlson wrote: > Robin Becker wrote: >> Is the any way to get an efficient 16bit hash in python? > > hash(obj)&65535 > > - Josiah yes I thought of that, but cannot figure out if the internal hash really distributes the bits evenly. Particularly since it seems

Re: 16bit hash

2007-06-28 Thread Robin Becker
do the latter so I hoped to pursue a python based approach which has a low probability of busting. Originally I thought the range was a 16bit number which is why I started with 16bit hashes. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

Re: 16bit hash

2007-06-28 Thread Robin Becker
Thomas Jollans wrote: > Robin Becker wrote: ... >> I'm not sure my postscript is really good enough to do the latter so I >> hoped to pursue a python based approach which has a low probability of >> busting. Originally I thought the range was a 16bit number which is w

Re: 16bit hash

2007-06-28 Thread Robin Becker
ent and then I need a fairly robust way to generate reasonable candidates. -- Robin Becker -- http://mail.python.org/mailman/listinfo/python-list

<    1   2   3   4   5   6   7   8   >