Re: semicolon at end of python's statements

2013-09-02 Thread albert visser
e might be about). Somehow this makes sense to me. But then, I also like 'x = y if else z'. Moreover, I'm Dutch (...) Albert Visser -- Using Opera's mail client: http://www.opera.com/mail/ -- http://mail.python.org/mailman/listinfo/python-list

Re: print function and unwanted trailing space

2013-09-12 Thread Albert Hopkins
On Wed, Sep 11, 2013, at 07:36 AM, Wayne Werner wrote: > On Sat, 31 Aug 2013, candide wrote: > > # - > > for i in range(5): > >print(i, end=' ') # <- The last ' ' is unwanted > > print() > > # - > > Then why not define end='' instead?

How to display ReST properly on pypi?

2013-09-14 Thread Michel Albert
In general, I write my README files using the ReST syntax. But when I do, they don't show up formatted on pypi (see for example https://pypi.python.org/pypi/config_resolver/3.3.0). How do I get it to be formatted properly? Also, is there a way to specify that the "description" field in setup.py

Re: How to display ReST properly on pypi?

2013-09-14 Thread Michel Albert
, 14 September 2013 11:53:12 UTC+2, Chris “Kwpolska” Warrick wrote: > On Sat, Sep 14, 2013 at 11:08 AM, Michel Albert wrote: > > > In general, I write my README files using the ReST syntax. But when I do, > > they don't show up formatted on pypi (see for example > >

DNS query against a specific server.

2013-09-30 Thread Michel Albert
Hi, ``socket.gethostbyname`` sends the DNS resolution query to the DNS server specified by the OS. Is there an easy way to send a query to a *different* server? I see that twisted.names allows you to do this, but, having all of twisted as dependency to my project when all I need to do is a sim

Re: DNS query against a specific server.

2013-09-30 Thread Michel Albert
On Monday, 30 September 2013 14:36:34 UTC+2, William Ray Wing wrote: > On Sep 30, 2013, at 7:42 AM, Michel Albert <***> wrote: > > > > > Hi, > > > > > > ``socket.gethostbyname`` sends the DNS resolution query to the DNS server > > specified

Re: DNS query against a specific server.

2013-09-30 Thread Michel Albert
On Monday, 30 September 2013 14:54:41 UTC+2, Ervin Hegedüs wrote: > Hello, > > > > On Mon, Sep 30, 2013 at 04:42:29AM -0700, Michel Albert wrote: > > > Hi, > > > > > > ``socket.gethostbyname`` sends the DNS resolution query to the DNS server >

Re: Why doesn't input code return 'plants' as in 'Getting Started with Beautiful Soup' text (on page 30) ?

2015-07-12 Thread Albert Visser
ulSoup(f,"lxml") should have been something like >>> with open("C:\Beautiful Soup\ecologicalpyramid.html","r")as f: ... soup = BeautifulSoup(f,"lxml") -- Vriendelijke groeten / Kind regards, Albert Visser Using Opera's mail client: http://www.opera.com/mail/ -- https://mail.python.org/mailman/listinfo/python-list

Re: Problem configuring apache to run python cgi on Ubuntu 14.04

2015-09-21 Thread Albert Visser
orking. Can anybody help me out? Thanks in advance. Which Python are you running? If it's Python 3, change the shebang accordingly because "python" is assuming Python 2. -- Vriendelijke groeten / Kind regards, Albert Visser Using Opera's mail client: http://www.op

Re: [SciPy-User] Convert 3d NumPy array into 2d

2014-08-27 Thread Maximilian Albert
[source] 2014-08-27 16:08 GMT+01:00 phinn stuart : > Hi everyone, how can I convert (1L, 480L, 1440L) shaped numpy array into > (480L,

Re: Sequencing images using tkinter?

2014-08-30 Thread Albert Visser
myButton1.config(image=myImage, width="100", height="200") sleep(0.2) myButton1=Button(canvas1, text='OK', justify = LEFT, command=rotate) myButton1.place(x=500,y=300) myGui.mainloop() Hope this helps -- Vriendelijke groeten / Kind regards, A

Re: error in except

2013-02-04 Thread Albert Hopkins
On Mon, Feb 4, 2013, at 04:49 PM, Rodrick Brown wrote: > For the life of me I cant figure out why this exception is being thrown. > How could I use pdb to debug this? > > $ python udp_local2.py server > File "udp_local2.py", line 36 > except: > ^ > SyntaxError: invalid syntax > >

Re: Best Practice Question

2013-02-05 Thread Albert Hopkins
[...] > By the way, did someone ever notice that r'\' fails ? I'm sure there's a > reason for that... (python 2.5) Anyone knows ? > > r'\' > SyntaxError: EOL while scanning single-quoted string > > "Even in a raw string, string quotes can be escaped with a backslash, but the backslash remains in

Re: Is Python programming language?

2013-02-08 Thread Albert Hopkins
On Fri, Feb 8, 2013, at 08:03 AM, gmspro wrote: > Hello all, > > One said, Python is not programming language, rather scripting language, > is that true? > According to Wikipedia[1] a "scripting languages" are a subset of "programming languages" so it goes that any "scripting language" is, be

Re: how to call shell?

2013-02-12 Thread Albert Hopkins
On Tue, Feb 12, 2013, at 12:12 AM, contro opinion wrote: > >>> import os > >>> os.system("i=3") > 0 > >>> os.system("echo $i") > > 0 > >>> > why i can't get the value of i ? Whenever you call os.system, a new shell is created and the command is run, system() then waits for the command to comple

Re: AttributeError: 'gr_hier_block2_sptr' object has no attribute 'set_callback'

2013-02-14 Thread Albert Hopkins
On Thu, Feb 14, 2013, at 04:39 PM, Dave Angel wrote: [... snip] > For those of us using text-based email, the program in this message is > totally unreadable. This is a text mailing-list, so please put your > email program in text mode, or you'll lose much of your audience. For those of us n

Re: Is Python "venerable"?

2013-02-20 Thread Albert Hopkins
On Tue, Feb 19, 2013, at 11:10 PM, Gene Heskett wrote: [...] > And even us old (78) farts are calling things Kewl now. 78??? Is that the year you were born or the years since you were born? -a -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Newbie

2013-02-24 Thread Albert Hopkins
> Most of what gets hung in art galleries these days is far less > visually pleasing than well-written code. +1 QOTW -- http://mail.python.org/mailman/listinfo/python-list

Re: Why is Ruby on Rails more popular than Django?

2013-03-06 Thread Albert Hopkins
On Wed, Mar 6, 2013, at 02:16 PM, Tim Johnson wrote: > I had problems getting django to work on my hostmonster account > which is shared hosting and supports fast_cgi but not wsgi. I put > that effort on hold for now, as it was just R&D for me, but > I would welcome you to take a look at

Top 10 python features

2013-03-17 Thread Albert Vonpupp
Hello pythonistas, I'm new to python and so far I'm really enjoying learning it. I would like to know what are the top 10 most important features (on your opinion) in python. I have to prepare a presentation on that and this is a very good chance to learn something new to me as well. Thanks a

Re: Top 10 python features

2013-03-20 Thread Albert Vonpupp
On Sunday, March 17, 2013 10:18:16 AM UTC-3, Albert Vonpupp wrote: > Hello pythonistas, > > > > I'm new to python and so far I'm really enjoying learning it. > > > > I would like to know what are the top 10 most important features (on your > opinion)

Re: ElementTree - Why not part of the core?

2005-12-14 Thread Istvan Albert
> $ python > Python 2.5a0 (#1, Dec 12 2005, 19:26:49) >>> import xml.etree.ElementTree as ET hip hip hurray! > http://svn.python.org/view/python/trunk/Lib/xml/etree/ don't know how this works, the link now seems to be: http://svn.python.org/view/python/trunk/Lib/xmlcore/etree/ -- http://mail.

Re: Some errors when running code in diveintopython: (

2005-12-23 Thread Istvan Albert
must be something with your settings ... I remeber once I had truly puzzling problem that manifested itself the same way ... Firefox and cygwin python would work fine but the windows python would raise errors when trying to connect via http ... ... finally I realized that the day before IE was s

Re: New release of Diet Python (0.2 Beta)!!!

2006-07-27 Thread Istvan Albert
The Eternal Squire wrote: > A developer's installation of PSF, including Pywin, WxPython, Numpy, > Scipy I believe can run up to 300 MB, no? you're missing the point, no one forces you to install all these, also it is very unlikely that someone would have these unless they needed them. -- http:

Re: A Universe Set

2006-10-04 Thread Istvan Albert
Jorgen Grahn wrote: > I have been craving for some similar things for a while, and I'm still not > sure if they are good ideas, or brain damage caused by studying functional > programming at Uni. This is a self correcting situation, as ayone who understands why they need this can surely write th

Re: switching to numpy and failing, a user story

2006-10-06 Thread Istvan Albert
sturlamolden wrote: > Those involved in the development of NumPy must receive some > compensation. Financial support to NumPy also ensure that the > developmentcan continue. I for one does not want to see NumPy as Then charge for NumPy ... or write a book *besides* the documentation. One in which

Re: switching to numpy and failing, a user story

2006-10-09 Thread Istvan Albert
Fernando Perez wrote: > It's funny how I don't see anyone complaining about any of the Python books > sold here (or at any other publishing house): That is maybe because the language is fairly well documented to begin with. Try to imagine for a moment how many people would use Python if on the fi

Re: ANN: SimpleJSONRPCServer

2006-10-09 Thread Istvan Albert
Sybren Stuvel wrote: > aum enlightened us with: > > I've built a module called SimpleJSONRPCServer, which is essentially > > the same as the familiar python library module SimpleXMLRPCServer, > > except that it uses the JSON-RPC protocol. > > Thanks a lot! I've used XML-RPC on a low-speed device, a

Re: paseline(my favorite simple script): does something similar exist?

2006-10-12 Thread Istvan Albert
RickMuller wrote: > One of my all-time favorite scripts is parseline, which is printed here is another way to write that: def parseline(line, format): trans = {'x':lambda x:None,'s':str,'f':float,'d':int,'i':int} return [ trans[f](w) for f,w in zip(format, line.split() ) ] >>> parseli

Re: invert or reverse a string... warning this is a rant

2006-10-20 Thread Istvan Albert
Carl Banks wrote: > Say you're using a function from a third-party library that finds the > first character in a string that meets some requirement. You need to > find the last such character. You seem to imply that invoking a function on a reversed input is somehow a generic solution to the pro

Re: invert or reverse a string... warning this is a rant

2006-10-20 Thread Istvan Albert
egbert wrote: > String reversal comes in handy when you do palindromes. Yes, that's where the big bucks are, the Palindrome Industry. It is the shortsightedness of the Python core developers that keeps the palindrome related functions and algorithms out of the standard library i. -- http://m

Re: multythreading app memory consumption

2006-10-23 Thread Istvan Albert
Roman Petrichev wrote: > try: > url = Q.get() > except Queue.Empty: > break This code will never raise the Queue.Empty exception. Only a non-blocking get does: url = Q.get(block=False) As mentioned before you should post working code if you expect peo

Re: Python 2.5 ; Effbot console ; thank ; pb release.

2006-10-24 Thread Istvan Albert
Martin v. Löwis wrote: > People certainly build it themselves, but then never share. I don't > know why that is - probably, it takes a different mindset to be on > the giving end than on the receiving end of free software. I've seen people share binary builds, for example you can get the windows

Re: Python's CRT licensing on Windows <-- FUD

2006-10-25 Thread Istvan Albert
sturlamolden wrote: > Maybe someone have gone through the trouble and got a clear answer from > Microsoft. As far as companies go the EULA is as clear of an answer as you can possibly hope for. As for the original post, don't bother with it this issue, the chances that MS will start harassing yo

Re: a good programming text editor (not IDE)

2006-06-15 Thread Istvan Albert
Scott David Daniels wrote: > To paraphrase someone else (their identity lost in my mental fog) about > learning VI: > "The two weeks you'll spend hating vi (or vim) as you learn it will > be repaid in another month, ad the rest is pure profit." Time and again I hear this (no shortage o

Re: a good programming text editor (not IDE)

2006-06-16 Thread Istvan Albert
Scott David Daniels wrote: > Surprise, surprise. One hour is not two weeks. I wrote: > pressing Ctrl-1 while editing the source will execute the python on the > current source *and* it displays the output in a lower pane as it runs > *and* it allows me to simultanously edit the file *while* th

new python icons for windows

2006-06-20 Thread Istvan Albert
I've been using the new python icons for windows for about two weeks now and I must say they've turned out to be far less functional than I thought. From purely visual standpoint the new icons look better, the old ones had a certain level of 'cuteness' associated to them .. I could see why that mig

Re: new python icons for windows

2006-06-21 Thread Istvan Albert
[EMAIL PROTECTED] wrote: > > For example it resembles the icon for text files. > > This is intentional: to make it obvious that .py files are the > readable, editable scripts, contrasting with .pyc's binary gunk - I think this is a mistake, it does not seem obious, all it does is just blends in

Re: SWIG problems with gcc and Cygwin?

2006-06-26 Thread Istvan Albert
Michael Yanowitz wrote: > Also, not sure if related but I do have a win32 Python 2.4.3 and > Cygwin Python 2.4.1. Not sure if there are any conflicts. Any advice > in making these two co-exist? SWIG will work with the windows and cygwin python, just make sure you don't mix the various platforms

Re: Looking for a high performance web server written in Python, and supports CGI/FastCGI

2006-07-06 Thread Istvan Albert
Jack wrote: > I will have to install lighttpd or other web servers. do that. If all you need is a webserver there's little reason to have it in python. Just use one of the several high quality open source webservers. -- http://mail.python.org/mailman/listinfo/python-list

Re: Looking for a high performance web server written in Python, and supports CGI/FastCGI

2006-07-07 Thread Istvan Albert
> >> I will have to install lighttpd or other web servers. > If it is a Python web server, it would be nice to extend it by putting code > right into the web server. The performance should be better than FastCGI > because it removes the cost to send the requests/replies back and forth. you'll nee

Re: multithreading and shared dictionary

2006-07-07 Thread Istvan Albert
Stéphane Ninin wrote: > Is a lock required in such a case ? I believe that assignment is atomic and would not need a lock. yet most of the other dictionary use cases are not threadsafe. For example I suspect that you'd get an error if you were iterating through the dictionary while another threa

Re: multithreading and shared dictionary

2006-07-08 Thread Istvan Albert
Marc 'BlackJack' Rintsch wrote: > It's not in Jython nor IronPython and maybe not forever in > CPython. Whether or not a feature is present in Jython or IronPython does not seem relevant, after all these languages emulate Python, one could argue that it only means that this emulation is incomplet

Re: sqlite 'ownership' problems

2006-09-03 Thread Istvan Albert
rdrink wrote: > created at the cmnd-line, e.g. 'test.db' with a table 'foo', I would > get the error "_sqlite.DatabaseError: no such table: foo". My suspition > was that this is a "feature" of sqlite ('flat file' vs. a dynamic db in > MySQL) where sqlite is 'sensetive' to who creates it... Most l

Re: Twisted vs POS (Plain-old sockets)

2006-09-04 Thread Istvan Albert
Guido Goldstein wrote: > You might have a look at asyncore/asychat in the standard library. > It does the async stuff for you and it's easy to understand and to > use. or Allegra might work http://laurentszyster.be/blog/allegra/ its anti-twisted melodrama comes at no extra charge. i. -- htt

Re: Are Python's reserved words reserved in places they dont need to be?

2006-09-12 Thread Istvan Albert
metaperl wrote: > --> python -i > >>> class = "algebra" > File "", line 1 > class = "algebra" > ^ > SyntaxError: invalid syntax Designing a syntax to avoid all possible newbie errors is impractical because as soon as you are finished with one iteration the new newbies will start m

Re: XSLT speed comparisons

2006-09-28 Thread Istvan Albert
Microsoft has put a lot of effort into their XML libraries as they are (or will be) the foundation of most of their software suites. I think you'll be hard pressed to find a library that exceeds it in both breadth of functionality and performance. Istvan -- http://mail.python.org/mailman/listin

Re: Leave the putdowns in the Perl community, the Python world does not need them

2006-09-29 Thread Istvan Albert
metaperl wrote: > I was shocked to see the personal insults hurled in this thread: > http://groups.google.com/group/comp.lang.python/browse_thread/thread/d0758cb9545cad4b Ahhh, no need to overreact, that's just the usual Friday night steel cage match: Fredrik vs "Poster Who is Convinced That The

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

2006-10-03 Thread Istvan Albert
I remember a similar patch from some time ago: http://mail.python.org/pipermail/python-dev/2004-August/046686.html i -- http://mail.python.org/mailman/listinfo/python-list

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

2006-10-03 Thread Istvan Albert
Larry Hastings wrote: > That patch addressed the same general problem, but took a completely > different approach. For the record, this patch (#980695) optimized "x Larry, Forgot to mention this, in case you haven't done so post your original message/patch on the python-dev lists since that's w

Re: Python to use a non open source bug tracker?

2006-10-03 Thread Istvan Albert
Giovanni Bajo wrote: > Does this smell "Bitkeeper fiasco" to anyone else than me? well, no company will spend money/effort/resources unless it benefits them some way. Once that benefit (or the perception of it) disappears the company will cut the lifeline. It's just common business sense. But th

Re: Python to use a non open source bug tracker?

2006-10-04 Thread Istvan Albert
Giovanni Bajo wrote: > I understand your point. OTOH, exactly because the tracker system is a far > lesser importance, it's amazing there is *ever* a need to evaluate non-FLOSS > solutions, when there are so many good free solutions around. Instead of I think you are missing the point. Switching

Re: why would anyone use python when java is there?

2006-11-30 Thread Istvan Albert
gavino wrote: > I want to learn to program and I can't seem to pick a direction. A Learning how to program and learning a programming language are completely different things. The former far more difficult then the latter. There is nothing better than Python to learn how to program because it i

Re: Why not just show the out-of-range index?

2006-12-07 Thread Istvan Albert
Russ wrote: > The message tells you where the error occurred, but it doesn't tell you > what the range and the offending index are. So here is a scenario, what should happen if by accident one uses a 50Mb string as an index? Should it be displayed? i. -- http://mail.python.org/mailman/listinf

Re: Initializing with the correct type

2006-12-07 Thread Istvan Albert
[EMAIL PROTECTED] wrote: > Hi all, > > I'm new to Python and I'm just wordering if my approch is correct. > Here's an example. I'm making sure that the length and types are > correct. Don't worry much about the type of parameters, it turns out passing wrong data into a constructor is a problem tha

Re: A Call to Arms for Python Advocacy

2006-12-07 Thread Istvan Albert
Roy Smith wrote: > I think it also appears to need faster hardware. It's running glacially > slow. runs fine here i. -- http://mail.python.org/mailman/listinfo/python-list

Re: merits of Lisp vs Python

2006-12-08 Thread Istvan Albert
Mark Tarver wrote: > seems to show that Python is a cut down (no macros) version of Lisp > with a worse performance. or maybe it shows that Lisp is an obfuscated version of Python with lots of parentheses, backward logic, and complicated constructs that run faster. i. -- http://mail.python.org

Re: Large files uploading

2006-12-13 Thread Istvan Albert
Lad wrote: > Or is there another way( besides FTP) how to upload large files to > server? You can upload via http. The primary problem is that the browser don't work well with large uploads (give little feedback on the process, IE may hang etc). You can workaround some limitations by using apple

Large XML Document Processing

2006-01-27 Thread Albert Leibbrandt
lot. Thanks Albert -- http://mail.python.org/mailman/listinfo/python-list

Re: HTML parsing bug?

2006-01-30 Thread Istvan Albert
> this is a comment in JavaScript, which is itself inside an HTML comment Don't nest HTML comments. Occasionaly it may break the browsers as well. (I remember this from one of the weirdest of bughunts : whenever the number of characters between nested HTML comments was divisible by four the page

Re: HTML parsing bug?

2006-02-02 Thread Istvan Albert
>> this is a comment in JavaScript, which is itself inside an HTML comment > Did you read the post? misread it rather ... -- http://mail.python.org/mailman/listinfo/python-list

Re: only a simple xml reader value

2006-02-08 Thread Albert Leibbrandt
[EMAIL PROTECTED] wrote: >I'm newbie with that xml stuff. > >The only thing I must read is the response I get from a EPP server. >A response like this: > > >http://www.eurid.eu/xml/epp/epp-1.0"; >xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; >xmlns:contact="http://www.eurid.eu/xml/epp/con

Re: cx_Oracle entry point error

2006-02-08 Thread Albert Leibbrandt
ws or linux? On both of these os's I only needed to install the binary. Have a look at this page on sourceforge http://sourceforge.net/project/showfiles.php?group_id=84168 cheers albert -- http://mail.python.org/mailman/listinfo/python-list

Re: how to remove using replace function?

2006-02-09 Thread Albert Leibbrandt
Rinzwind wrote: >Works for me. > > > >>>>txt = "an unfortunate in the middle" >>>>print txt.replace("", "") >>>> >>>> >an unfortunate in the middle > > > > >Though I don

Re: Inserting record with Microsoft Access

2006-02-09 Thread Albert Leibbrandt
. > >Thanks, >Jeff > > > > > I had to do something similiar in sql server and the experts back then told me that the only way is to write a stored procedure. aparently sql server does not have sequences and I am guessing that access is the same. cheers albert -- Albert

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-16 Thread Istvan Albert
As a non-native English speaker, On May 13, 11:44 am, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > - should non-ASCII identifiers be supported? why? No. I don't think it adds much, I think it will be a little used feature (as it should be), every python instructor will start their class by say

Re: Python Web Programming - looking for examples of solid high-traffic sites

2007-05-17 Thread Istvan Albert
On May 16, 5:04 pm, Victor Kryukov <[EMAIL PROTECTED]> wrote: > Our main requirement for tools we're going to use is rock-solid > stability. As one of our team-members puts it, "We want to use tools > that are stable, has many developer-years and thousands of user-years > behind them, and that we

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-17 Thread Istvan Albert
On May 16, 11:09 pm, Gregor Horvath <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] schrieb: > > > On May 16, 12:54 pm, Gregor Horvath <[EMAIL PROTECTED]> wrote: > >> Istvan Albert schrieb: > > >> So the solution is to forbid Chinese XP ? Who sai

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-17 Thread Istvan Albert
On May 17, 9:07 am, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > up. I interviewed about 20 programmers (none of them Python users), and > most took the position "I might not use it myself, but it surely > can't hurt having it, and there surely are people who would use it". Typically when you a

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-18 Thread Istvan Albert
On May 17, 2:30 pm, Gregor Horvath <[EMAIL PROTECTED]> wrote: > Is there any difference for you in debugging this code snippets? > class Türstock(object): Of course there is, how do I type the ü ? (I can copy/paste for example, but that gets old quick). But you're making a strawman argument by

Re: PEP 3131: Supporting Non-ASCII Identifiers

2007-05-19 Thread Istvan Albert
On May 19, 3:33 am, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > >That would be invalid syntax since the third line is an assignment > > with target identifiers separated only by spaces. > > Plus, the identifier starts with a number (even though 6 is not DIGIT > SIX, but FULLWIDTH DIGIT SIX,

Re: zip() function troubles

2007-07-26 Thread Istvan Albert
On Jul 26, 9:33 pm, Paul Rubin wrote: > Do a top or vmstat while that is happening and see if you are > swapping. You are allocating 10 million ints and 10 million tuple > nodes, = 20 million objects. Although, even at 100 bytes per object > that would be 1GB which wou

zip() function troubles

2007-07-26 Thread Istvan Albert
Hello all, I've been debugging the reason for a major slowdown in a piece of code ... and it turns out that it was the zip function. In the past the lists that were zipped were reasonably short, but once the size exceeded 10 million the zip function slowed to a crawl. Note that there was memory av

Re: zip() function troubles

2007-07-26 Thread Istvan Albert
On Jul 26, 7:44 pm, Paul Rubin <http://[EMAIL PROTECTED]> wrote: > Istvan Albert <[EMAIL PROTECTED]> writes: > > exceeded 10 million the zip function slowed to a crawl. Note that > > there was memory available to store over 100 million items. > > How many byte

Re: zip() function troubles

2007-07-27 Thread Istvan Albert
On Jul 27, 2:16 am, "Terry Reedy" <[EMAIL PROTECTED]> wrote: > References are not objects. yes this a valid objection, but in all fairness the example in the original post operates on comparably sized objects and also exhibited unexpected performance degradation as it turns out the garbage coll

Re: zip() function troubles

2007-07-27 Thread Istvan Albert
On Jul 27, 1:24 am, Peter Otten <[EMAIL PROTECTED]> wrote: > When you are allocating a lot of objects without releasing them the garbage > collector kicks in to look for cycles. Try switching it off: > > import gc > gc.disable() Yes, this solves the problem I was experiencing. Thanks. Istvan --

Re: zip() function troubles

2007-07-27 Thread Istvan Albert
On Jul 27, 2:18 pm, Raymond Hettinger <[EMAIL PROTECTED]> wrote: >> What was really surprising is that it works >> with no issues up until 1 million items" later editing made the sentence more difficult to read I should have said: "What was really surprising is that zip works with no issues up un

Re: This bit of code hangs Python Indefinitely

2007-08-08 Thread Istvan Albert
On Aug 8, 9:38 am, brad <[EMAIL PROTECTED]> wrote: > The problem is that I have 512 things to add to the queue, but my limit > is half that... whoops. Shouldn't the interpreter tell me that I'm an > idiot for trying to do this instead of just hanging? A message such as > this would be more appropri

Re: Misleading wikipedia article on Python 3?

2007-08-08 Thread Istvan Albert
On Aug 6, 6:49 am, Neil Cerutti <[EMAIL PROTECTED]> wrote: > Incidentally, from the second link I find it shocking that the > keyword parameter "file" shadows a builtin. It seems to endorse a > bad practice. I believe that the "file" builtin has been removed as well so it won't shadow anything.

Re: Misleading wikipedia article on Python 3?

2007-08-08 Thread Istvan Albert
On Aug 6, 6:11 am, Paul Rubin wrote: > Why on earth did they make this change? It just seems gratuitous. Having print a function (with parameters) makes is very easy to modify where the output goes. Say you want to have some prints go to one particular file, today you

Re: Misleading wikipedia article on Python 3?

2007-08-08 Thread Istvan Albert
On Aug 8, 12:08 pm, Paul Boddie <[EMAIL PROTECTED]> wrote: > However, for every enthusiast of one approach, there > will always be an enthusiast for another (see point #6): True. For example I for one also like the way the current print adds a newline, the vast majority of the time that is exact

Re: Misleading wikipedia article on Python 3?

2007-08-08 Thread Istvan Albert
On Aug 8, 2:00 pm, Neil Cerutti <[EMAIL PROTECTED]> wrote: > I thought, in fact, that open was on more shaky ground. ;) yeah, that too ... > I can't find any evidence of that in the PEPs. Do you have a reference? here is something: http://svn.python.org/view/python/branches/p3yk/Misc/NEWS?rev=

Re: Haskell like (c:cs) syntax

2007-08-29 Thread Istvan Albert
On Aug 29, 8:12 am, Ricardo Aráoz <[EMAIL PROTECTED]> wrote: > >> Caution : L[0] and L[1:] are COPIES of the head and tail of the list. > Sorry, should have written RETURN copies instead of ARE copies. L[0] does not return a copy, it does what is says, returns the object stored at index 0. i.

Re: Speed of Python

2007-09-07 Thread Istvan Albert
On Sep 7, 12:42 pm, "wang frank" <[EMAIL PROTECTED]> wrote: > Is my conclusion correct that Python is slower than matlab? There are ways to speed up code execution, but to see substantial improvement you'll need to use numpy and rework the code to operate on vectors/matrices rather than building

Re: MemoryError on reading mbox file

2007-09-12 Thread Istvan Albert
On Sep 12, 5:27 am, Christoph Krammer <[EMAIL PROTECTED]> wrote: > string = self._file.read(stop - self._file.tell()) > MemoryError This line reads an entire message into memory as a string. Is it possible that you have a huge email in there (hundreds of MB) with some attachment encoded as te

Re: Graphviz Python Binding for Python 2.5 on Windows?

2007-03-06 Thread Istvan Albert
On Mar 5, 5:16 pm, "Alex Li" <[EMAIL PROTECTED]> wrote: > I tried to avoid. Any suggestions? try the networkx package, it includes the pygraphviz module that can generate dot files: https://networkx.lanl.gov/wiki Istvan -- http://mail.python.org/mailman/listinfo/python-list

Re: Graphviz Python Binding for Python 2.5 on Windows?

2007-03-06 Thread Istvan Albert
On Mar 6, 3:18 pm, "Istvan Albert" <[EMAIL PROTECTED]> wrote: > try the networkx package, it includes the pygraphviz module that can > generate dot files: > > https://networkx.lanl.gov/wiki should've checked it before posting, it seems nowadays is a

web development with python - comparison

2007-03-26 Thread Istvan Albert
Here is a comprehensive review of python web apps: http://jesusphreak.infogami.com/blog/vrp1 Since this comes up every so often in this group. i. -- http://mail.python.org/mailman/listinfo/python-list

Re: I could use some help making this Python code run faster using only Python code.

2007-09-20 Thread Istvan Albert
On Sep 20, 7:13 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > How come it's not? Then I noticed you don't have brackets in > the join statement. So I tried without them and got If memory serves me right newer versions of python will recognize and optimize string concatenation via the += op

Re: Zope review

2007-09-21 Thread Istvan Albert
On Sep 20, 7:44 pm, Norm <[EMAIL PROTECTED]> wrote: > without meaning to start a flame war between the various python web > tools, I was wondering if anyone had a review of the status of Zope. > For example, is it being used for new projects or just maintenance? Zope is heavily used. It is a matu

Re: Zope review

2007-09-21 Thread Istvan Albert
On Sep 21, 7:04 pm, "Sean Tierney" <[EMAIL PROTECTED]> wrote: > someone could contrast Zope w/ another Python framework like Twisted. > I've been investing some time in learning Zope/Plone and would love to > hear someone speak to alternatives. Twisted is a networking engine, Zope is a web appli

Re: Newbie completely confused

2007-09-24 Thread Istvan Albert
Two comments, > ... > self.item3 = float(foo[c]); c+=1 > self.item4 = float(foo[c]); c+=1 > self.item5 = float(foo[c]); c+=1 > self.item6 = float(foo[c]); c+=1 > ... this here (and your code in general) is mind boggling and not in a good way, as for you original question, I don't think that read

Re: Tracking memory usage and object life time.

2007-09-26 Thread Istvan Albert
On Sep 26, 8:06 am, Berteun Damman <[EMAIL PROTECTED]> wrote: > that have been created after I don't need them anymore. I furthermore > don't really see why there would be references to these larger objects > left. (I can be mistaken of course). This could be tricky because you have a graph that

Re: setuptools without unexpected downloads

2007-09-27 Thread Istvan Albert
On Sep 26, 2:09 am, Ben Finney <[EMAIL PROTECTED]> wrote: > behaviour with a specific invocation of 'setup.py'. But how can I > disallow this from within the 'setup.py' program, so my users don't > have to be aware of this unexpected default behaviour? I don't have the answer for this, but I can

Re: Python + Shoutpy + Twisted Locks

2007-10-07 Thread Michel Albert
On Oct 6, 4:21 am, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Fri, 05 Oct 2007 04:55:55 -0300, exhuma.twn <[EMAIL PROTECTED]> escribi?: > > > [...] What I found > > is that "libshout" is blocking, which should be fine as the whole > > thing runs in it's separate thread. But the application

Re: Yet another comparison of Python Web Frameworks

2007-10-07 Thread Istvan Albert
IMO this is not as much a framework comparison rather than an evaluation of the individual components that make up Pylons. The framework is the sum of all its parts. Programmers should not need to know that that a package named Beaker is used for sessions, Routes for url mapping, PasteDeploy for

Re: Yet another comparison of Python Web Frameworks

2007-10-07 Thread Istvan Albert
On Oct 7, 12:24 pm, Michele Simionato <[EMAIL PROTECTED]> wrote: > Here we disagree: I think that a programmer should know what he > is using. My point was that they should not *need* to know. Too much information can be detrimental. > > Where is the session data stored: in memory, files, databa

Re: NUCULAR fielded text searchable indexing

2007-10-09 Thread Istvan Albert
On Oct 9, 7:26 am, [EMAIL PROTECTED] wrote: > No, it doesn't stand for anything. It also reminds me of someone we all know, and I wish it didn't. As the latin proverb says "Nomen est omen". Calling your package "docindexer" would draw a lot more people. It is hard to justify to a third party tha

Re: NUCULAR fielded text searchable indexing

2007-10-09 Thread Istvan Albert
On Oct 9, 9:14 am, [EMAIL PROTECTED] wrote: > a great tradition of tounge-in-cheek package names, like > "Cold fusion", for example. Cold Fusion is a super cool name. Nobody will every think of it as representing something odd or silly. > too late now. sorry again, why would it be late? is the

Re: Yet another comparison of Python Web Frameworks

2007-10-10 Thread Istvan Albert
On Oct 9, 11:57 pm, [EMAIL PROTECTED] wrote: > Since you are starting a new project you may want to look into > something new and different > > http://mdp.cti.depaul.edu/examples This is actually a neat framework! I'm a somewhat of fan of web- frameworks and I used most major ones and I like to po

<    1   2   3   4   5   6   7   8   9   10   >