Re: Performance of int/long in Python 3

2013-04-02 Thread Neil Hodgson
rusi wrote: ... a 'micro-benchmark' - I'd just like to avoid adding email access to get this over the threshold. What does that last statement mean? Its a reference to a comment by Jamie Zawinski (relatively famous developer of Netscape Navigator and other things): "Every program at

Re: Performance of int/long in Python 3

2013-04-02 Thread Neil Hodgson
Chris Angelico: I'd be curious to know the sorts of characters used. Given that it's probably a narrow-vs-wide Python difference we're talking here, the actual distribution of codepoints may well make a difference. I was going to upload it but then I thought of potential client -confidenti

Re: Performance of int/long in Python 3

2013-04-02 Thread Neil Hodgson
Terry Jan Reedy: What system *and* what compiler and compiler options. Unless 3.2 and 3.3 are both compiler with the same compiler and settings, we do not know the source of the difference. The version signatures are: 3.2.3 (default, Apr 11 2012, 07:15:24) [MSC v.1500 32 bit (Intel)] 3.3.

Re: Performance of int/long in Python 3

2013-04-03 Thread Neil Hodgson
Reran the programs taking a bit more care with the encoding of the file. This had no effect on the speeds. There are only a small amount of paths that don't fit into ASCII: ASCII 1076101 Latin1 218 BMP 113 Astral 0 # encoding:utf-8 import codecs, os, time from os.path import join, getsize w

Re: Performance of int/long in Python 3

2013-04-03 Thread Neil Hodgson
Roy Smith: On the other hand, how long did it take you to do the directory tree walk required to find those million paths? I'll bet a long longer than 0.78 seconds, so this gets lost in the noise. About 2 minutes. But that's just getting an example data set. Other data sets may be loaded

Re: Performance of int/long in Python 3

2013-04-03 Thread Neil Hodgson
rusi: Can you please try one more experiment Neil? Knock off all non-ASCII strings (paths) from your dataset and try again. Results are the same 0.40 (well, 0.001 less but I don't think the timer is that accurate) for Python 3.2 and 0.78 for Python 3.3. Neil -- http://mail.python.org/

Re: Performance of int/long in Python 3

2013-04-03 Thread Neil Hodgson
Dave Angel: That would seem to imply that the speed regression on your data is NOT caused by the differing size encodings. Perhaps it is the difference in MSC compiler version, or other changes made between 3.2 and 3.3 Its not caused by there actually being different size encodings but tha

Re: Performance of int/long in Python 3

2013-04-03 Thread Neil Hodgson
Neil Hodgson, replying to self: The assembler (32-bit build) for each PyUnicode_READ looks like Don't have 64-bit MSVC 2010 set up but the code from 64-bit MSVC 2012 is better since there are an extra 8 registers in 64-bit mode: ; 10431: c1 = PyUnicode_READ(kind1, dat

Re: Is Unicode support so hard...

2013-04-20 Thread Neil Hodgson
Hi jmf, This gives me plenty of ideas to test the "flexible string representation" (FSR). I should recognize this FSR is failing particulary very well... This is too vague for me. Which string representation should Python use? 1) UTF-32 2) UTF-8 3) Python 3.3 -- 1, 2, or 4 bytes per

Re: calculate system disk space

2005-12-10 Thread Neil Hodgson
Heiko Wundram: > Under Windows you don't have sparse files though, so there > are no fields ... Does too! http://msdn.microsoft.com/library/en-us/fileio/fs/fsctl_set_sparse.asp They're fairly rare though. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: mail attachment with non-ascii name

2005-12-11 Thread Neil Hodgson
Bernard Delmée: > I am using the "email" module to decode incoming messages. > (with msg = email.message_from_file( msg_file )) > Sometimes an attachment has its name (as returned by > msg.walk().part.get_filename()) not in ASCII (e.g. > '=?iso-8859-1?q?somefile=2ezip?=') How can I turn that into

Re: Difference between ActivePython and Python.org

2005-12-14 Thread Neil Hodgson
S.Chang: > Anyone knows the difference(s) between the Python binaries from > ActiveState and Python.org? As well as the differences mentioned by others, ActivePython does not include SSL (Secure Socket Layer) and thus HTTPS support. It would be helpful if the ActivePython "What's Included"

Re: access to preallocated block of memory?

2005-12-15 Thread Neil Hodgson
Greg Copeland: > I already have access to the block on memory...I > simply need information about existing python facilities which will > allow me to expose the block to python as a native type...from which I > can read byte for byte and optionally write to. As I originally said, > I have a point

Re: Visual Python : finished ?

2005-12-16 Thread Neil Hodgson
Microsoft's Visual Studio SDK team have produced some IronPython integration. Its available as source code but you have to sign up (including Passport ...) for a Visual Studio SDK license. Info: http://blogs.msdn.com/aaronmar/archive/2005/12/09/502202.aspx Download: http://affiliate.vsipmem

Re: Calling foreign functions from Python? ctypes?

2006-01-06 Thread Neil Hodgson
Paul Watson: > Is there any plan to get ctypes batteries into > the standard Python build? It is unlikely that ctypes will be included in the standard Python build as it allows unsafe memory access making it much easier to crash Python. Neil -- http://mail.python.org/mailman/list

Re: Encoding sniffer?

2006-01-06 Thread Neil Hodgson
Ralf Muschall: > Diez B. Roggisch wrote: >>AFAIK iso-8859-1 has all codepoints taken - so you won't go beyond that >>in your example. > IIRC the range 128-159 (i.e. control codes with the high bit set) > are unused. ISO 8859-1 and ISO-8859-1 (extra hyphen) differ in that ISO-8859-1 inclu

Re: Calling foreign functions from Python? ctypes?

2006-01-06 Thread Neil Hodgson
Paul Watson: > Neil Hodgson wrote: >>It is unlikely that ctypes will be included in the standard Python >> build as it allows unsafe memory access making it much easier to crash >> Python. > Does extending Python with any C/C++ function not do the same t

Re: Calling foreign functions from Python? ctypes?

2006-01-09 Thread Neil Hodgson
Paul Watson: > I cannot find any way to get to GetVersionInfo in VBScript (cscript). Set objFSO = CreateObject("Scripting.FileSystemObject") Wscript.Echo objFSO.GetFileVersion("c:\bin\SciLexer.dll") Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: (Fucking) Unicode: console print statement and PythonWin: replacement for off-table chars HOWTO?

2006-01-10 Thread Neil Hodgson
Robert: > u'sytest3\\\u041f\u043e\u0448\u0443\u043a.txt' > > u'\u043a' is cyrillic: к > > no matter, I guess no (small) system can know all unicode ranges in use > wordwide. The real problem is: to get a smoot, smart an tolerant setup > by default - not a mixup of 4 codecs and (most bothersome)

Re: Client side web programming

2006-01-10 Thread Neil Hodgson
Pramod Subramanyan wrote: > Using cookielib and urllib2, I've come up with a workable solution. Its > damn slow though - which is probably orkut's fault - deletes about > 10-15 scraps a minute - so to get through 14000 scraps its probably > gonna take around 23 hours. It'll be interesting to

Re: A bug for unicode strings in Python 2.4?

2006-01-10 Thread Neil Hodgson
Thomas Moore: u=u'\u9019\u662f\u4e2d\u6587\u5b57\u4e32' u.split() > > [u'\u9019\u662f\u4e2d\u6587\u5b57\u4e32'] > > > I think u should get split. Where do you think "這是中文字串" should be split and why? Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: (Fucking) Unicode: console print statement and PythonWin: replacement for off-table chars HOWTO?

2006-01-11 Thread Neil Hodgson
Robert: > After "is_platform_unicode = ", scintilla displays some unicode > as you showed. but the win32-functions (e.g. MessageBox) still do not > pass through wide unicode. Win32 issues are better discussed on the python-win32 mailing list which is read by more of the people interested in

Re: Unicode style in win32/PythonWin

2006-01-13 Thread Neil Hodgson
Thomas Heller: > Hm, I don't know. I try to avoid converting questionable characters at > all, if possible. Then, it seems the error-mode doesn't seem to change > anything with "mbcs" encoding. WinXP, Python 2.4.2 on the console: > u"abc\u034adef".encode("mbcs", "ignore") > 'abc?def'

Re: Shrinky-dink Python (also, non-Unicode Python build is broken)

2006-01-16 Thread Neil Hodgson
Larry Hastings: > First and foremost: turning off Py_USING_UNICODE *breaks the build* > on Windows. The following list of breakages were all fixed with > judicious applications of #ifdef Py_USING_UNICODE: > * The implementation of "multi-byte codecs" (CJK codecs) implicitly > assumes that they

Re: Shrinky-dink Python (also, non-Unicode Python build is broken)

2006-01-16 Thread Neil Hodgson
Giovanni Bajo: > - There will be some opposition to the obvious policy of "keeping the bare > minimum inside the DLL" because of inefficiencies in the Python build > system. It is also non-optimal for those that do want the full set of modules as separate files can add overhead for block si

Re: Shrinky-dink Python (also, non-Unicode Python build is broken)

2006-01-17 Thread Neil Hodgson
Larry Hastings: > As for future development of Windows-specific Python features... > doesn't that generally happen in modules, rather than the Python > interpreter, these days? Either in Mark Hammond's pywin32 (what used > to be called "win32all"), or perhaps done in Python using ctypes. > There

Re: The Python cross? Was New Python.org website

2006-01-18 Thread Neil Hodgson
Steve Holden: > The history of this choice is lost in the mists of time. Many other > proposals were made and discussed at around the same time, to the extent > that it became clear no one choice could win universal approval. The two snakes have just been arguing (over decorator syntax, the

Re: problem in executing a file

2006-07-13 Thread Neil Hodgson
Ernesto: > import os > os.system("file.exe parameters") > > but I received an error like "cmd.exe : permission deneided" > > Probably I don't have the permission to execute the file. However, the server > administrator said me that he cannot give me the permission, but I can also > use > ed exe

Re: building an index for large text files for fast access

2006-07-24 Thread Neil Hodgson
Yi Xing: > Since different lines have different size, I > cannot use seek(). So I am thinking of building an index for the file > for fast access. Can anybody give me some tips on how to do this in > Python? It depends on the size of the files and the amount of memory and disk you may use

Re: Intermittent "permission denied" errors when using os.rename and a recently deleted path??

2006-07-26 Thread Neil Hodgson
Russell Warren: > I've been having a hard time tracking down a very intermittent problem > where I get a "permission denied" error when trying to rename a file to > something that has just been deleted (on win32). Are you running a background file accessing tool like Google Desktop Search or

Re: Intermittent "permission denied" errors when using os.rename and a recently deleted path??

2006-07-26 Thread Neil Hodgson
Russell Warren: > I'm actually running both... but I would think that once os.remove > returns that the file is actually gone from the hdd. Why would either > application be blocking access to a non-existent file? Does it actually tell you the target is the problem? I see an "OSError: [Errn

Re: Backup GMAIL Messages with Python

2006-08-05 Thread Neil Hodgson
Gregory Piñero: > I was wondering what methods you experts > would reccomend for this task? While you can write a script, its quite easy to turn on POP and run a client side mail client like Thunderbird. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: Proposal: [... for ... while cond(x)]

2006-08-08 Thread Neil Hodgson
Eighty: > So does no one have a comment on this? Similar proposals have appeared before (such as on python-dev about a year ago) and haven't attracted much positive comment. The benefits appear to be small compared to the cost of making the language larger. You could try the formal route

Re: (Boost.Python) How to load header files?

2006-08-08 Thread Neil Hodgson
Qun Cao wrote: > I have a C++ class foo.cpp, defined in foo.h, I wrote a wrapper class > for it to generate a python module. > > #include "Foo.h" If you are on Windows it shouldn't matter but try to keep capitalisation consistent: #include "foo.h". > The problem is that when I bjam it, the

Re: Unicode/utf-8 data in SQL Server

2006-08-08 Thread Neil Hodgson
bjorn: > I also > tried creating an Excel VB macro using the StrConv function, but (a) it > isn't entirely clear to me that this function can do this, and (b) the > third argument to the function is an LCID, a Locale ID, which is > numeric and not defined anywhere I can find it... http://www.micr

Re: knowing when file is flushed to disk

2006-08-09 Thread Neil Hodgson
John Pote: > Is there some way from my Python script to know when the data is actually on > the disk. BTW server OS is Linux. Presumably calling flush() and close() on > the output file will initiate the disk write, but do they wait for the > actual disk write or immediately return leaving the

Re: Boost Install

2006-08-11 Thread Neil Hodgson
Jeff: > I have attempted to follow some online install directions which do not > seem to work. I am using VS2005. VS2003 is more likely to work since that was the compiler used for the python executables distributed by python.org. > I have tried, bjam "--with-python-version[=2.4] and just g

Re: Basic Boost.Python Question

2006-08-14 Thread Neil Hodgson
Hoop: > I am starting on an application that will developed in VS2005, probably > using C++/CLI. I haven't heard any reports of Boost.Python code being compatible with C++/CLI so you may need to add an adaptation layer. To run inside .NET, I'd choose IronPython. Neil -- http://mail.py

Re: Basic Boost.Python Question

2006-08-15 Thread Neil Hodgson
Hoop: > I have never heard of IronPython. Do you know if you can embedd the > Python interpreter ? I think so as I've read of people embedding the console on the mailing list. My experience is in using a C# library within a Python application. Neil -- http://mail.python.org/mailman/li

Re: COM Error -- Urgent help

2006-10-17 Thread Neil Hodgson
Teja: > ie=win32com.client.Dispatch('internetexplorer.application') > ie.Visible=1 > > class GenericFunctions: > def __init__(self): > print "In Constructor of Generic Functions" > def MyNavigate(self,dest): > ie.Navigate(dest) You are using an interface created on th

Re: multythreading app memory consumption

2006-10-23 Thread Neil Hodgson
Roman Petrichev: > Dennis Lee Bieber wrote: >> How much stack space gets allocated for 150 threads? > Actually I don't know. How can I get to know this? On Linux, each thread will often be allocated 10 megabytes of stack. This can be viewed and altered with the ulimit command. Neil -

Re: uninstall and Windows file associations

2006-11-01 Thread Neil Hodgson
Roger Miller: > When I installed Python 2.5 (on Windows XP) I left 2.4 in place "just > in case". Today I decided to remove it. However after doing so (from > the control panel) I found that Windows no longer knows about the > Python file types and associations. Is this behavior expected, Th

Re: Keyboard interrupts, Idle vs. SciTE

2006-11-02 Thread Neil Hodgson
John Ladasky: > Under SciTE, I do not get my "exiting program" message. Instead, I get > the standard SciTE abort message: > > >> Process failed to respond; forcing abrupt termination... >> Exit code: 1 > > > I much prefer the SciTE environment to Idle. Is there any way that I > can rewrite

Re: Python less error-prone than Java

2006-06-03 Thread Neil Hodgson
Alan Morgan wrote: > Since Java doesn't allow function overloading that clearly can't be > the way. J2SE 5.0 allows generic classes and functions that operate > on generic containers. There are some gotchas, but it's not drastically > more complex than the original int-only java code. Doesn

Re: python-dev Summary for 2006-05-01 through 2006-05-15

2006-06-14 Thread Neil Hodgson
Radovan: > This summary is tagged as being in ISO-8859-1 encoding: > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > However, it really is in UTF-8, which results in this mojibake: > >> Martin v. Löwis and Marc-Andre Lemburg discussed how to include both Its a good thing we

Re: a good programming text editor (not IDE)

2006-06-15 Thread Neil Hodgson
John Salerno: > Based on another thread, I tried out Scite, but no matter what I do it > doesn't seem to remember the window size and position, or any options I > choose (like showing line numbers). It seems to always reset itself each > time I open it. SciTE is configured by modifying opt

Re: poplib Q

2006-07-06 Thread Neil Hodgson
SuperHik: > I did ofc, but I noticed something strange... > *my* socket module really doesn't have SSL object, > even tho it's listed in the documentation... > (not the online docs, but docs that came with my Python version) > ffs how can that be! You are probably using ActiveState's distribu

Re: [ANN] IronPython 1.0 released today!

2006-09-06 Thread Neil Hodgson
Chris: > I'm no code guru but it sounds interesting. So can I import numpy, > scipy, matplotlib, wxpython etc like I do now with CPython and expect, > short of a few tweaks, that my code will work? No, IronPython is currently unable to load CPython DLLs. Neil -- http://mail.python.or

Re: OT: What encoding is this?

2006-09-09 Thread Neil Hodgson
> http://www.loppen.dk/side.php?navn=getin > > I'm guessing ISO-8859-15, but the page doesn't indicate and it's none of the > ones available in Safari. It decodes to the same text using ISO-8859-1, ISO-8859-15, or Windows-1252. More pages without declarations are produced on Windows so

Re: does anybody earn a living programming in python?

2006-09-25 Thread Neil Hodgson
For the last 5 years most of my jobs have been Python based. At two of those places Python has been the main but not only language used. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: Using win32gui.SendMessage and SysListView32 control

2006-12-03 Thread Neil Hodgson
[EMAIL PROTECTED]: > This page seems to imply that the control can be queried with messages, > however, my problem seems to be that pywin32.win32con does not define a > constant for the LVM series of messages. These are defined in win32/lib/commctrl.py in my installation. Neil -- http:/

Re: Using non-ascii symbols

2006-01-27 Thread Neil Hodgson
Having a bit of a play with some of my spam reduction code. Original: def isMostlyCyrillic(u): if type(u) != type(u""): u = unicode(u, "UTF-8") cnt = float(sum(0x400 <= ord(c) < 0x500 for c in u)) return (cnt > 1) and ((cnt / len(u)) > 0.5) Using more mathematical ope

Re: Thread imbalance

2006-02-05 Thread Neil Hodgson
Ivan Voras wrote: > opinion, but by "good threading implementation" I mean that all threads > in the application should run "natively" on the underlying (p)threads > library at all times, without implicit serialization. For example, Java > and perl do this, possibly also lua and C#. Lua h

Re: Thread imbalance

2006-02-06 Thread Neil Hodgson
Ivan Voras: > I mentioned it because, as far as I know the Lua's intepreter doesn't do > implicit locking on its own, and if I want to run several threads of > pure Lua code, it's possible if I take care of data sharing and > synchronization myself. Lua's interpreter will perform synchroni

Re: UTF16, BOM, and Windows Line endings

2006-02-06 Thread Neil Hodgson
Fuzzyman: > How should I handle line-endings for UTF16 ? Is it possible that other > programs (on windows) will have line endings as u'\r\n' ? Yes, try Notepad and save as Unicode. For the text Fuzzy End of lines >>> contents = open("C:\\fuzzy.txt", "rb").read() >>> contents '\xff\xfeF\x

Re: UTF16, BOM, and Windows Line endings

2006-02-06 Thread Neil Hodgson
Fuzzyman: > Thanks - so I need to decode to unicode and *then* split on line > endings. Problem is, that means I can't use Python to handle line > endings where I don't know the encoding in advance. > > In another thread I've posted a small function that *guesses* line > endings in use. You

Re: How to check...

2006-02-11 Thread Neil Hodgson
Lad: > How can I check that a string does NOT contain NON English characters? It depends on how you define the set of English characters which is as much a matter of opinion or authority as fact. The following may be regarded as English despite containing 9 (8 unique) non-ASCII charac

Re: Yet another GUI toolkit question...

2006-02-11 Thread Neil Hodgson
Kevin Walzer: > Do these screenshots look "non-native" to you? > > http://www.wordtech-software.com/ireveal-mac.png Yes. I don't use a Mac much but the following are really obvious. The column header icons don't fit within the header. The scroll bar is squished up too thin. The icons are f

Re: commenting out blocks of code

2006-02-17 Thread Neil Hodgson
Hi Steven, > I see the developers of Scite are either newbies to GUI programming, or > they operate in a world of their own. Ctrl-Q is reserved for Quit (or > Exit) in every GUI API I know of. I am the developer responsible for SciTE and the Ctrl+Q decision. Ctrl+Q is not reserved for Qui

Re: commenting out blocks of code

2006-02-19 Thread Neil Hodgson
Atanas Banov: > here is something you both seems to have not considered: imagine you > make decision if ^Q has to comment or uncomment based on the 1st line > and not on each line individually in the block. When first implementing Ctrl+Q, this looked to have similar advantages and disadvantag

Re: Unicode and MoinMoin

2006-02-26 Thread Neil Hodgson
Greg: > The only issue I'm having relates to Unicode. MoinMoin and python are > pretty unforgiving about files that contain Unicode characters that > aren't included in the coding properly. I've spent hours reading about > Unicode, and playing with different encoding/decoding commands, but at > th

Re: XP rich text cut-n-paste

2006-03-05 Thread Neil Hodgson
Paddy: > Scintilla does indeed have the feature, and googling for the term "copy > as RTF" lead me to http://www.pnotepad.org/ which also has the feature. Its actually implemented in SciTE rather than Scintilla by the ugly technique of writing out an RTF file and then copying that to the cl

Re: gtk/qt scintilla help !

2005-05-01 Thread Neil Hodgson
Fabien: > There is a lexPOV.cxx file in the package, but I can not find any POV > keywords in any file ( there are about 150 POV keywords). Did i miss it, > and if not, how do I create one and include it for the library building ? The Scintilla web site, documentation and mailing list are: h

Re: Is Python suitable for a huge, enterprise size app?

2005-05-18 Thread Neil Hodgson
Steve M: > ... discusses the problem with memory allocation in CPython. > Apparently CPython is not good at, or incapable of, releasing > memory back to the operating system. I'm fairly sure Java does not give memory back to the operating system either. A quick search did not give a defin

Re: Fw: evidence john bokma al jazeera connection ?

2005-05-21 Thread Neil Hodgson
There is a response to this on John's web site: http://johnbokma.com/mexit/2005/05/19/daniel-joseph-min.html Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: Problem accessing Python Business Forum

2005-05-26 Thread Neil Hodgson
John: > Every time I attempt to look at the Python Business > Forum (www.python-in-business.org), I encounter an error that starts > like this: > ... Laura Creighton responded about this on python-dev: # The machine is at work, and anybody who wants to fix it # is welcome to. The problem is

Re: using boost to return list

2005-06-04 Thread Neil Hodgson
GujuBoy: > i am trying to make a "cpp" file which will make an array and pass it > to python as a list. > > how is this possible...i am using BOOST...please can someone point me > at some examples This returns a list when called from Python. static list retrieval_as_list(SplitText &self, in

Re: error in usin list with boost

2005-06-05 Thread Neil Hodgson
GujuBoy: > i have created a "cpp" file which has the followin code and when i try > to compile it..it does not know what "list" is..it says its > undefined..i also tried using #include I would have expected this (except the cstdint.h line which may not be needed but it was in the code I cop

Re: GUI builders considered harmful (Was: anygui, anydb, any opinions?)

2005-06-05 Thread Neil Hodgson
Mike Meyer: > The obvious solution would be for the system to detect all these > environmental factors, and scale the applications > accordingly. However, things like viewing distance and the quality of > my eyesight are hard to detect automatically, and it would be a pain > to have to enter all t

Re: getmtime differs between Py2.5 and Py2.4

2007-06-01 Thread Neil Hodgson
Joe Salmeri: > I can see that you guys have already spent alot of time investigating this > but surely the results should match what Windows Explorer says or what the > dir command returns??? One problem I have seen is that Windows Explorer and its File Properties sheet sometimes cache tim

Re: Getting the home directory in Python and a bug in os.path.expanduser

2007-07-07 Thread Neil Hodgson
Edward Diener: > Probably most reliable on Windows is a Windows API function, if it > exists, for getting the home directory, as opposed to using environment > variables, but I can not find any Windows API for it at present. Look at SHGetFolderPath(CSIDL_PROFILE, ...) for Windows Me/2000 or

Re: Python's handling of unicode surrogates

2007-04-19 Thread Neil Hodgson
Adam Olsen: > To solve this I propose Python's unicode type using UTF-16 should have > gaps in its index, allowing it to only expose complete unicode scalar > values. Iteration would produce surrogate pairs rather than > individual surrogates, indexing to the first half of a surrogate pair > woul

Re: Python's handling of unicode surrogates

2007-04-20 Thread Neil Hodgson
ate positions so is proportional to log(number of surrogates). Code (not thoroughly tested): /** @file surstr.cxx ** A simple Unicode string class that stores in UTF-16 ** but indexes by character. **/ // Copyright 2007 by Neil Hodgson <[EMAIL PROTECTED]> // This source code is publi

Re: No speedup on multi-processor machine?

2007-04-21 Thread Neil Hodgson
Fuzzyman: > IronPython is *definitely* not restricted by the GIL. IronPython is currently mostly slower than CPython although the particular problem should be tested to see if IronPython helps. Some recent benchmarks between IronPython and CPython: http://sparcs.kaist.ac.kr/~tinuviel/py

Re: how to serialize a COM object ?

2007-04-24 Thread Neil Hodgson
vml wrote: > I have a COM object. > > I would like to pass this com object from a server to a client through > a socket. As Diez mentioned, this may be possible through Distributed COM (DCOM). Its not very popular any more with techniques such as SOAP being more widely implemented. DCOM is

Re: use urllib library to have an upload status bar

2007-04-27 Thread Neil Hodgson
shirish: > We have a bug-reporting system in ubuntu called apport. Apparently > apport uses a python library called urllib. As of now, apport does a > bouncing bar while uploading which doesn't give the user idea as to > how much is being uploaded. Here is a Python project that has implemen

Re: Python-URL! - weekly Python news and links (Apr 30)

2007-05-01 Thread Neil Hodgson
Cameron Laird: > ... but the *references* in that object are unlikely to be > meaningful on the second machine (or, in many cases, on the > original machine, if at a sufficiently later time). The marshaling of the object is responsible for persisting any contained references in a format that

Re: My newbie annoyances so far

2007-05-06 Thread Neil Hodgson
Alex Martelli: > Can you run a generic benchmark "inside the current implementation of > Flash" to check out its Javascript performance? I can't, so, ... I can't either (without going to a lot of effort) so here is a page comparing SpiderMonkey and Tamarin from someone with an adobe.com add

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-13 Thread Neil Hodgson
Paul Rubin wrote: >> Plenty of programming languages already support unicode identifiers, > > Could you name a few? Thanks. C#, Java, Ecmascript, Visual Basic. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-14 Thread Neil Hodgson
Martin v. Löwis: > This PEP suggests to support non-ASCII letters (such as accented > characters, Cyrillic, Greek, Kanji, etc.) in Python identifiers. I support this to ease integration with other languages and platforms that allow non-ASCII letters to be used in identifiers. Python has a s

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-14 Thread Neil Hodgson
Anton Vredegoor: > Ouch! Now I seem to be disagreeing with the one who writes my editor. > What will become of me now? It should be OK. I try to keep my anger under control and not cut off the pixel supply at the first stirrings of dissent. It may be an idea to provide some more help f

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-14 Thread Neil Hodgson
Martin v. Löwis: > Specification-wise, C99 and C++98 also support Unicode identifiers, > although many compilers still don't. Ada 2005 allows Unicode identifiers and even includes the constant 'π' in Ada.Numerics. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-16 Thread Neil Hodgson
Lorenzo Gatti: > Ok, maybe you considered listing characters but you earnestly decided > to follow an authority; but this reliance on the Unicode standard is > not a merit: it defers to an external entity (UAX 31 and the Unicode > database) a foundation of Python syntax. PEP 3131 uses a simil

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-16 Thread Neil Hodgson
Eric Brunel: > ... there is no > keyboard *on Earth* allowing to type *all* characters in the whole > Unicode set. My keyboard in conjunction with the operating system (US English keyboard on a Windows XP system) allows me to type characters from any language. I haven't learned how to ty

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-16 Thread Neil Hodgson
Eric Brunel: > Funny you talk about Japanese, a language I'm a bit familiar with and > for which I actually know some input methods. The thing is, these only > work if you know the transcription to the latin alphabet of the word you > want to type, which closely match its pronunciation. So if y

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-16 Thread Neil Hodgson
Eric Brunel: > Have you ever tried to enter anything more than 2 or 3 characters like > that? No, only for examples. Lengthy texts are either already available digitally or are entered by someone skilled in the language. > I did. It just takes ages. Come on: are you really serious about

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-17 Thread Neil Hodgson
Martin v. Löwis: > ... regardless of whether this PEP gets accepted > or not (which it just did). Which version can we expect this to be implemented in? Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-18 Thread Neil Hodgson
Istvan Albert: > But you're making a strawman argument by using extended ASCII > characters that would work anyhow. How about debugging this (I wonder > will it even make it through?) : > > class 6자회담관련론조 >6자회 = 0 >6자회담관련 고귀 명=10 That would be invalid syntax since the third line is a

Re: List Moderator

2007-05-21 Thread Neil Hodgson
Grant Edwards: > To quantify things for curiosity's sake, I just scanned through > the last 1000 postings in c.l.p. There was exactly 1 spam > message and two replies to spam messages complaining about > them. Looking at all my cached messages, I saw 9 including replies. Only one reply went

Re: File Read Cache - How to purge?

2007-08-21 Thread Neil Hodgson
Signal: > So it seems the file is being cached, however on my system only ~2MB > of additional memory is used when the program is run. This 2MB of > memory is released when the script exits. You are not measuring the memory used by the cache. This may help: http://www.microsoft.com/technet/ar

Re: pure python for sms

2007-08-30 Thread Neil Hodgson
Gerardo Herzig: > Hi dudes. Im looking for a python implementation for sending sms to a > cell phone. I was try using some free pages, but i want to use a python. > Do i need a cellphone conected to my machine? Or can i send sms to some > cell via some python library? This is likely to cos

Re: RFC: Assignment as expression (pre-PEP)

2007-04-05 Thread Neil Hodgson
[EMAIL PROTECTED]: > else: > my_match = capper_re.match(f): > if my_match: > capper = capper_re.match(f).group(1) > if capper == 'JJ' or capper == 'JeffreyJacobs': > capper = 'Jeffrey C. Jacobs' > p

Re: Hosting Companies: Help for Python Users?

2007-04-09 Thread Neil Hodgson
Steve Holden: > Dennis Lee Beiber: > > > Too many 3rd-party modules still aren't available in 2.5 > > versions for my tastes... > > This applies particularly (though not exclusively) to the Windows > platform, for various reasons -- the most common one is that Linux > developers frequently d

Re: tuples, index method, Python's design

2007-04-15 Thread Neil Hodgson
Paul Rubin: > I still don't get it. UTF-16 is just a data compression scheme, right? > I mean, s[17] isn't the 17th character of the (unicode) string regardless > of which memory byte it happens to live at? It could be that that accessing > it takes more than constant time, but that's hidden by

Re: Try this

2007-09-16 Thread Neil Hodgson
GeorgeRXZ: > Then Open the Notepad and type the following sentence, and save the > file and close the notepad. Now reopen the file and you will find out > that, Notepad is not able to save the following text line. This is a known issue with Notepad. See the "Unicode detection" section of htt

Re: Python does not play well with others

2007-02-03 Thread Neil Hodgson
Paul Rubin: > I thought J2SE comes with JSP. Maybe that's not a "framework" in the > fancy sense though. J2SE does not include JSP. Neil -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Source Code Beautifier

2007-02-27 Thread Neil Hodgson
Franz Steinhaeusler: > Hello, I did not find any reasonable pyhton source code beautifier > program (preferable gui). > ... > convert: > ... > from "is" to "==" and "is not" to "!=" (ok a find replace could do that > easily also), but in a program that would be more comfortable. That's an unsa

Re: After running for four days, Python program stalled

2007-12-12 Thread Neil Hodgson
John Nagle: > Had a Python program stall, using no time, after running OK for four days. > Python 2.4, Windows. Here's the location in Python where it's stalled. > Any idea what it's waiting for? > 77FA144B int 3# STALLED HERE Its a breakpoint instru

Re: Python DLL in Windows Folder

2007-12-25 Thread Neil Hodgson
Markus Gritsch: > I assume that your Python applications are .py files. To be able to > run them it would be perfectly ok if the Python DLL would be located > beside the python.exe in the Python installation folder. Your Python application may not be being run by python.exe but as an in-pro

Re: MinGW and Python

2006-04-25 Thread Neil Hodgson
sturlamolden: > Uh .. I actually think it could be an EULA violation to publish mingw > vs. msvc benchmarks without permission from Microsoft. I don't want to > part of anything illegal or have M$ lawyers breathing down my back. If > we are going to do this, then we must do it properly and get the

<    1   2   3   >