[issue43431] Subprocess timeout causes output to be returned as bytes in text mode

2021-03-08 Thread Jordan Macdonald
Jordan Macdonald added the comment: Eryk Sun: Well, I think step 1 should be to update the documentation for Python 3.7 through 3.10 on `subprocess.run()` and `subprocess.TimeoutExpired` to clearly state that `TimeoutExpired.stdout` and `TimeoutExpired.stderr` will be in bytes format even

[issue43431] Subprocess timeout causes output to be returned as bytes in text mode

2021-03-07 Thread Jordan Macdonald
New submission from Jordan Macdonald : Passing the argument `text=True` to `subprocess.run()` is supposed to mean that any captured output of the called process is automatically decoded and retuned to the user as test instead of bytes. However, if you give a timeout and that timeout expires

[issue42853] `OverflowError: signed integer is greater than maximum` in ssl.py for files larger than 2GB

2021-01-07 Thread Andrew MacDonald
New submission from Andrew MacDonald : When attempting to read a large file (> 2GB) over HTTPS the read fails with "OverflowError: signed integer is greater than maximum". This occurs with Python >=3.8 and I've been able to reproduce the problem with the below snippet of co

[issue13474] Mention of "-m" Flag Missing From Doc on Execution Model

2018-05-16 Thread Hamish MacDonald
Change by Hamish MacDonald <elusiven...@gmail.com>: -- pull_requests: +6571 ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue13474] Mention of "-m" Flag Missing From Doc on Execution Model

2018-05-16 Thread Hamish MacDonald
Change by Hamish MacDonald <elusiven...@gmail.com>: -- keywords: +patch pull_requests: +6570 stage: needs patch -> patch review ___ Python tracker <rep...@bugs.python.org> <https://bugs.pyt

Express thanks

2017-08-21 Thread Hamish MacDonald
I wanted to give a shout out to the wonderfully passionate contributions to python I've witnessed following this and other mailing lists over the last little bit. The level of knowledge and willingness to help I've seen are truly inspiring. Super motivating. Probably the wrong forum for such a

Re: can I overload operators like =, - or something like that?

2012-04-20 Thread Jacob MacDonald
On Thursday, April 19, 2012 11:09:52 PM UTC-7, Ben Finney wrote: alex23 wuwe...@gmail.com writes: On Apr 20, 5:54 am, Jacob MacDonald jaccar...@gmail.com wrote: On Thursday, April 19, 2012 12:28:50 PM UTC-7, dmitrey wrote: can I somehow overload operators like =, - or something like

Re: How do you refer to an iterator in docs?

2012-04-20 Thread Jacob MacDonald
On Friday, April 20, 2012 6:41:25 AM UTC-7, Roy Smith wrote: In article 4f910c3d$0$29965$c3e8da3$54964...@news.astraweb.com, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: I refer you to your subject line: How do you refer to an iterator in docs? In documentation, I

Re: How do you refer to an iterator in docs?

2012-04-19 Thread Jacob MacDonald
On Thursday, April 19, 2012 5:21:20 AM UTC-7, Roy Smith wrote: Let's say I have a function which takes a list of words. I might write the docstring for it something like: def foo(words): Foo-ify words (which must be a list) What if I want words to be the more general case of

Re: os.system()

2012-04-19 Thread Jacob MacDonald
On Thursday, April 19, 2012 11:09:22 AM UTC-7, Yigit Turgut wrote: When I use os.system() function, script waits for termination of the windows that is opened by os.system() to continue thus throwing errors and etc. How can i tell Python to let it go and keep on with the next execution after

Re: can I overload operators like =, - or something like that?

2012-04-19 Thread Jacob MacDonald
On Thursday, April 19, 2012 12:28:50 PM UTC-7, dmitrey wrote: hi all, can I somehow overload operators like =, - or something like that? (I'm searching for appropriate overload for logical implication if a then b) Thank you in advance, D. I don't believe that you could overload those

Strange affinity side effect with multiprocessing.

2010-11-21 Thread Greg MacDonald
Hi Everyone, I'm having a strange problem with the multiprocessing package and Panda3D. Importing panda modules causes multiprocessing to only use one of my cores. I've created an example test case. It uses an infinite loop to ping the cores so you'll have to manually kill the python processes.

Re: Python Developer - HFT Trading firm - Chicago, IL

2010-08-21 Thread Scott MacDonald
Possibly relevant: http://www.nanex.net/FlashCrash/FlashCrashAnalysis_NBBO.html On Sat, Aug 21, 2010 at 4:22 PM, Lawrence D'Oliveiro l...@geek-central.gen.new_zealand wrote: In message a10be304-96dc-4fb3-bf9f-35652477e...@f20g2000pro.googlegroups.com, Raymond Hettinger wrote: On Aug 21,

[issue1761028] pickle - cannot unpickle circular deps with custom __hash__

2009-05-19 Thread Tristam MacDonald
Changes by Tristam MacDonald swiftco...@gmail.com: -- nosy: +swiftcoder ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1761028 ___ ___ Python-bugs

[issue1761028] pickle - cannot unpickle circular deps with custom __hash__

2009-05-19 Thread Tristam MacDonald
Tristam MacDonald swiftco...@gmail.com added the comment: Is there any sign of a patch or workaround for this issue? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1761028

Re: import urllib2 fails with Python 2.6.1 on Vista

2009-01-19 Thread Scott MacDonald
I think I set it a long time ago to get the python VTK bindings working... On Mon, Jan 19, 2009 at 5:58 AM, Gabriel Genellina gagsl-...@yahoo.com.arwrote: En Sun, 18 Jan 2009 16:08:07 -0200, Scott MacDonald scott.p.macdon...@gmail.com escribió: Ah yes, with your help I seem to have solved

Re: import urllib2 fails with Python 2.6.1 on Vista

2009-01-18 Thread Scott MacDonald
or something like that? Thanks, Scott On Sun, Jan 18, 2009 at 12:44 AM, Gabriel Genellina gagsl-...@yahoo.com.arwrote: En Sat, 17 Jan 2009 17:13:00 -0200, Scott MacDonald scott.p.macdon...@gmail.com escribió: I googled a bit this morning search for an answer to this problem but have come up

Re: import urllib2 fails with Python 2.6.1 on Vista

2009-01-18 Thread Scott MacDonald
Ah yes, with your help I seem to have solved my own problem. I had PYTHONPATH defined to point to the 2.5 directory. Thanks! Scott On Sun, Jan 18, 2009 at 11:01 AM, Scott MacDonald scott.p.macdon...@gmail.com wrote: Yes, I see your point. Not sure how that would happen. It is possible

import urllib2 fails with Python 2.6.1 on Vista

2009-01-17 Thread Scott MacDonald
I googled a bit this morning search for an answer to this problem but have come up empty so far. Can anyone help? Python 2.6.1 (r261:67517, Dec 4 2008, 16:51:00) [MSC v.1500 32 bit (Intel)] on win32 Type help, copyright, credits or license for more information. import urllib2 Traceback (most

Re: Python Dictionary Algorithm Question

2008-12-16 Thread Scott MacDonald
You might be interested in the Beautiful Code book: http://oreilly.com/catalog/9780596510046/ It has a chapter on Python's dict implementation that is pretty good. On Tue, Dec 16, 2008 at 10:51 AM, Brigette Hodson brigettehod...@gmail.comwrote: Hello! I am in a beginning algorithms class this

Re: Programming exercises/challenges

2008-11-18 Thread Scott MacDonald
What size of a project are you looking to work on? I enjoy learning in a similar way as you it seems. Recently I have been interested in data visualization problems. Maybe trying to replicate something from a website like: http://www.visualcomplexity.com/vc/ would interest you? Scott On Tue,

Re: import pysqlite2 or import sqlite3?

2007-11-22 Thread Mike MacDonald
On Nov 21, 3:02 pm, Hertha Steck [EMAIL PROTECTED] wrote: Hello, I'm using Python 2.5.1, Pysqlite 2.3.5 and SQLite 3.4.1 on Gentoo Linux. I've always imported pysqlite using from pysqlite2 import dbapi2 and that works. If I try import sqlite3 I get Traceback (most recent call last):

Re: Probably simple syntax error

2007-07-02 Thread Dustin MacDonald
Ah. Thank you everyone. Sorry for not replying earlier, real life got in the way :) Gerry Herron, Tim Delaney, Mark Peters: Thank you. Switching from parentheses to square brackets fixed the code, and yes, Tim, you were right. It was a list I was working with. And thanks for those links Tim.

Probably simple syntax error

2007-07-01 Thread Dustin MacDonald
Hi everyone. This is my first time posting to this newsgroup, and although I maintain my netiquette I might've missed something specific to the newsgroup, so hopefully you can avoid flaming me if I have :) I apologize for the length of this post but I figure the more information the better. My

Re: Confusion over calling a nested function inside a parent function

2006-12-22 Thread MacDonald
Pyenos wrote: [code] class WORK: def getwork(self): def choosetable(self):pass choosetable() #TypeError: choosetable() takes exactly 1 #argument (0 given) [/code] Calling choosetable() at the above location gives me the error described above.

Re: how to match u'\uff00' - u'\uff0f' in re module?

2006-07-10 Thread MacDonald
yichao.zhang wrote: I'm trying to match the characters from u'\uff00' to u'\uff0f'. the code below and get a TypeError. p = re.compile(u'\uff00'-u'\uff0f') Traceback (most recent call last): File interactive input, line 1, in ? TypeError: unsupported operand type(s) for -: 'unicode' and

Re: Killing a thread

2006-06-11 Thread MacDonald
Fredrik Lundh wrote: [EMAIL PROTECTED] wrote: it cannot be done in a portable way, so that's not very likely. def __run(self): Hacked run function, which installs the trace. sys.settrace(self.globaltrace) self.__run_backup() self.run = self.__run_backup I'm not

Interpreting Unicode scripts

2006-02-05 Thread Keith MacDonald
, Keith MacDonald -- http://mail.python.org/mailman/listinfo/python-list

Re: Interpreting Unicode scripts

2006-02-05 Thread Keith MacDonald
That document did help, thanks, although I was initially disconcerted to see that it's written in the future tense. Anyway, it works with Python 2.4. Keith MacDonald Fredrik Lundh [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] reading PEP 263 might help: http

Reading in external file - error checking and line numbers...

2005-09-07 Thread Hugh Macdonald
it accurately to the user Hope this made sense - let me know if I've confused you at all. -- Hugh Macdonald -- http://mail.python.org/mailman/listinfo/python-list

Re: Reading in external file - error checking and line numbers...

2005-09-07 Thread Hugh Macdonald
there will be... This is why I'd much rather, if I can, do this without exceptions and just be able to print out my own error message with the problem line number marked Or am I asking too much? ;) -- Hugh Macdonald -- http://mail.python.org/mailman/listinfo/python-list

C API : Creating a Py_Method object from a C function.

2005-07-11 Thread Hugh Macdonald
! -- Hugh Macdonald -- http://mail.python.org/mailman/listinfo/python-list

Hacking the scope to pieces

2005-05-24 Thread Hugh Macdonald
of moduleLoader.loadModule working back up the scope and placing the imported module in the main global scope. Any idea how to do this? -- Hugh Macdonald -- http://mail.python.org/mailman/listinfo/python-list

Re: Hacking the scope to pieces

2005-05-24 Thread Hugh Macdonald
I will take a look! Thanks Skip -- Hugh -- http://mail.python.org/mailman/listinfo/python-list

Re: Hacking the scope to pieces

2005-05-24 Thread Hugh Macdonald
Maybe I misunderstood what you meant, but I couldn't quite manage to get this one working My initial hopes about __import__() were that I could define it inside my new module (moduleLoader) and, when the module is imported, it could do stuff (like try to hold onto the vars() and globals()