I have a substantial wxpython-based application that I'm trying to port from
python-2 to -3.
Almost everything is working properly, except for a few small but important
sections that use
the OGL library. That executes without any exceptions, but the objects created
within the
On Sat, 23 Feb 2019 14:56:03 +1100, Chris Angelico wrote:
> On Sat, Feb 23, 2019 at 2:51 PM Frank Miles
> wrote:
>>
>> I have a Debian/Linux machine that I just upgraded to the newer
>> "testing"
>> distribution. I'd done that earlier to another machin
I have a Debian/Linux machine that I just upgraded to the newer "testing"
distribution. I'd done that earlier to another machine and all went
well. With the latest machine, python2 is OK but python3 can barely run
at all. For example:
$ python3
Python 3.7.2+ (default, Feb 2 2019, 14:31:48)
On Wed, 12 Apr 2017 04:18:45 -0700, Masoud Afshari wrote:
> filename ="Ex_resample" +'_sdf_'+ str(n)+'.dat'
> with open(filename, 'rb') as f: #read binary file data = np.fromfile(f,
> dtype='float64', count=nx*ny) #float64 for Double precision float numbers
> Ex = np.reshape(data, [ny, nx],
On Tue, 04 Apr 2017 08:01:42 -0700, venkatachalam.19 wrote:
> Hello All,
>
> I am writing a python code for processing a data obtained from a sensor. The
> data from sensor is obtained by executing a python script. The data obtained
> should be further given to another python module where the
On Tue, 28 Mar 2017 15:38:38 -0400, Terry Reedy wrote:
> On 3/28/2017 2:51 PM, Frank Miles wrote:
>> I tried running a bit of example code from the py2.7 docs
>> (16.6.1.2. Exchanging objects between processes)
>> only to have it fail. The code is simply:
>
I tried running a bit of example code from the py2.7 docs
(16.6.1.2. Exchanging objects between processes)
only to have it fail. The code is simply:
#
from multiprocessing import Process, Queue
def f(q):
q.put([42, None, 'hello'])
if __name__ == '__main__':
q = Queue()
On Thu, 11 Feb 2016 14:29:04 +, cl wrote:
> I am trying out wxGlade on Linux, version 0.7.1 of wxGlade on xubuntu
> 15.10.
>
> I have already written something using wxPython directly so I have the
> basics (of my Python skills and the environment) OK I think.
>
> I am having a lot of
On Fri, 24 Jul 2015 19:31:36 +0100, Paulo da Silva wrote:
[snip]
Which technology is better?
matplotlib?
tkinter?
wxwidgets?
qt?
Sadly - I don't think wxpython has been ported to python3 yet.
--
https://mail.python.org/mailman/listinfo/python-list
miles added the comment:
The attachment includes the patch file
--
keywords: +patch
nosy: +milesli
Added file: http://bugs.python.org/file38274/thread.py.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue23382
New submission from miles:
Maybe can not shutdown ThreadPoolExecutor when call the method shutdown.
Though the variable of _shutdown is set to true in the method of shutdown, it
may also reads the variable of _shutdown from cpu cache in the method of
_worker, and the worst case
miles added the comment:
the attachment includes the new code
--
Added file: http://bugs.python.org/file38002/thread.py
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue23382
miles added the comment:
The attachment includes the new code
--
Added file: http://bugs.python.org/file37997/thread.py
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue23382
I need to evaluate a complicated function over a multidimensional space
as part of an optimization problem. This is a somewhat general problem
in which the number of dimensions and the function being evaluated can
vary from problem to problem.
I've got a working version (with loads of
On Tue, 05 Aug 2014 20:06:05 +, Frank Miles wrote:
I need to evaluate a complicated function over a multidimensional space
as part of an optimization problem. This is a somewhat general problem
in which the number of dimensions and the function being evaluated can
vary from problem
On Tue, 14 Jan 2014 07:26:10 -0800, ngangsia akumbo wrote:
When i run this code on my pc it actually runs but signals that the app is
not responding.
[snip most of the code]-
def main():
ex = wx.App()
Example(None)
ex.Mainloop()
if __name__ == __main__:
main()
When
On Thu, 12 Dec 2013 16:18:22 -0500, Larry Martell wrote:
On Thu, Dec 12, 2013 at 11:51 AM, bob gailer bgai...@gmail.com wrote:
On 12/11/2013 9:07 PM, Larry Martell wrote:
Nope. Long before that I was working on computers that didn't boot when
you powered them up, You had to manually key in a
On Tue, 22 Oct 2013 16:40:32 +, Steven D'Aprano wrote:
On Tue, 22 Oct 2013 15:39:42 +, Grant Edwards wrote:
No, I was thinking of an array. Arrays aren't automatically
initialised in C.
If they are static or global, then _yes_they_are_. They are zeroed.
Not that I don't
On Tue, 14 May 2013 08:05:53 -0700, Christian Jurk wrote:
Hi folks,
This questions may be asked several times already, but the development
of relevant software continues day-for-day. For some time now I've been
using xhtml2pdf [1] to generate PDF documents from HTML templates (which
are
On Thu, 09 May 2013 23:35:53 +0800, chandan kumar wrote:
Hi all,I'm new to python and facing issue using serial in python.I'm
facing the below error
ser.write(port,command)NameError: global name 'ser' is not defined
Please find the attached script and let me know whats wrong in my script
On 1/18/2013 7:32 PM, Roy Smith wrote:
Can whoever manages the mailing list block this bozo?
In article db2dnygmdpv4agtnnz2dnuvz_o-dn...@giganews.com,
kalvinmanual1 kalvinmanu...@gmail.com wrote:
I have solutions manuals to all problems and exercises in these textbooks. To
get one in an
On Sunday, November 18, 2012 8:18:53 PM UTC-6, Mark Lawrence wrote:
On 18/11/2012 19:31, Terry Reedy wrote:
The question was raised as to how much spam comes from googlegroups.
I don't know the answer but I take the greatest pleasure in hurtling
onto the dread googlegroups and gmane to
On 10/9/2012 1:07 AM, Bob Martin wrote:
in 682592 20121008 232126 Prasad, Ramit ramit.pra...@jpmorgan.com wrote:
Thomas Bach wrote:=0D=0A Hi there,=0D=0A =0D=0A On Sat, Oct 06, 2012 at =
03:08:38PM +, Steven D'Aprano wrote:=0D=0A =0D=0A my_tuple =3D my_=
tuple[:4]=0D=0A a,b,c,d =3D
On Sunday, November 18, 2012 1:35:00 PM UTC-6, Terry Reedy wrote:
The question was raised as to how much spam comes from googlegroups.
Not all, but more that half, I believe. This one does.
From: MoneyMaker livewebcams...@gmail.com
...
Message-ID:
On 10/31/2012 2:35 PM, ru...@yahoo.com wrote:
On 10/31/2012 09:11 AM, Grant Edwards wrote: On 2012-09-16, ??
nikos.gr...@gmail.com wrote:
Iam positng via google groups using chrome, thats all i know.
Learn something else. Google Groups is seriously and permanently
broken, and
On 10/31/2012 4:38 PM, Mark Lawrence wrote:
On 31/10/2012 19:35, ru...@yahoo.com wrote:
On 10/31/2012 09:11 AM, Grant Edwards wrote: On 2012-09-16,
?? nikos.gr...@gmail.com wrote:.
Broken? Yes. But so is every piece of software in one way
or another. Thunderbird is one of the
On 9/16/2012 9:12 PM, Dave Angel wrote:
On 09/16/2012 09:07 PM, Jadhav, Alok wrote:
Hi Everyone,
I have a simple program which reads a large file containing few million
rows, parses each row (`numpy array`) and converts into an array of
doubles (`python array`) and later writes into an `hdf5
with multiple levels of quoting.
The incompatibility tends to insert a blank line after every line.
With multiple levels of quoting, this gives blank line groups that
often roughly double in size for every level of quoting.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
On 9/16/2012 10:44 AM, pandora.ko...@gmail.com wrote:
Whaen i tried to post just now by hitting sumbit, google groups told me that
the following addresssed has benn found in this thread! i guess is used them
all to notify everything!
cdf072b2-7359-4417-b1e4-d984e4317...@googlegroups.com
On 9/16/2012 8:14 PM, alex23 wrote:
On Sep 17, 10:55 am, Roy Smith r...@panix.com wrote:
They didn't buy the service. They bought the data. Well, they really
bought both, but the data is all they wanted.
I thought they'd taken most of the historical data offline now too?
Some of it, but
the rest of
us. Again, not something you have much control over, except to stop
using Google Groups.
Could this mean that Google wants all the spam posted through Google
Groups to look obnoxious to the rest of Usenet that the spammers will go
elsewhere?
Robert Miles
--
http://mail.python.org/mailman
On 7/25/2012 8:56 AM, andrea crotti wrote:
I have some long running processes that do very long simulations which
at the end need to write things on a database.
At the moment sometimes there are network problems and we end up with
half the data on the database.
The half-data problem is
not sure whether I still could,
though.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
On 7/26/2012 5:51 AM, Jaroslav Dobrek wrote:
And the cool thing is: you can! :)
In Python 2.6 and later, the new Py3 open() function is a bit more hidden,
but it's still available:
from io import open
filename = somefile.txt
try:
with open(filename, encoding=utf-8) as
On 7/23/2012 1:10 PM, Dennis Lee Bieber wrote:
On Mon, 23 Jul 2012 16:42:51 +0200, Henrik Faber hfa...@invalid.net
declaimed the following in gmane.comp.python.general:
If that was written by my coworkers, I'd strangle them.
My first real assignment, 31 years ago, was porting an
On 7/23/2012 11:18 AM, Albert van der Horst wrote:
In article 5006b48a$0$29978$c3e8da3$54964...@news.astraweb.com,
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote:
SNIP.
Even with a break, why bother continuing through the body of the function
when you already have the result? When
On 7/10/2012 1:08 PM, Demian Brecht wrote:
I also judge candidates on their beards
(http://www.wired.com/wiredenterprise/2012/06/beard-gallery/). If the beard's
awesome enough, no questions needed. They're pro.
You should hire me quickly, then, since I have a beard, already turning
partly
has a version of Python available, in case you're interested.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
are moving toward newsgroups where no one
reports the spam.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
to discard every post they get
that contains any HTML. This may be because Google Groups often
adds HTML even if you don't ask for it, and those servers want
to avoid the poor signal to noise ratio from Google Groups.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
- as in 5 minutes after I tell it to post.
Robert Miles
--
http://mail.python.org/mailman/listinfo/python-list
On 27/04/2012 5:57 a.m., Kiuhnm wrote:
On 4/26/2012 19:48, Paul Rubin wrote:
Roy Smithr...@panix.com writes:
x = [a for a in iterable while a]
from itertools import takewhile
x = takewhile(bool, a)
I see that as a 'temporary' solution, otherwise we wouldn't need 'if'
inside of list
On Wed, 25 Apr 2012 23:03:36 +0200, Kiuhnm wrote:
On 4/25/2012 22:05, Frank Miles wrote:
I have an exceedingly simple function that does a named import. It
works perfectly for one file r- and fails for the second x.
If I reverse the order of being called, it is still x that fails, and
r
I have an exceedingly simple function that does a named import.
It works perfectly for one file r- and fails for the second x.
If I reverse the order of being called, it is still x that fails,
and r still succeeds.
os.access() always reports that the file is readable (i.e. true)
If I simply
Changes by Chris Miles miles.ch...@gmail.com:
--
nosy: -chrismiles
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13405
___
___
Python-bugs-list
/recipes/576755-sorting-big-files-the-python-26-way/
--
http://mail.python.org/mailman/listinfo/python-list
--
--
Alistair Miles
Head of Epidemiological Informatics
Centre for Genomics and Global Health http://cggh.org
The Wellcome Trust Centre for Human Genetics
Roosevelt Drive
Oxford
OX3 7BN
Darryl Miles darryl.mi...@darrylmiles.org added the comment:
With regards to create test cases for certain situations, sure this would be
possible but not with pure python since your APIs deny/inhibit the particular
things required to force a situation for a test case.
With regards
Darryl Miles darryl.mi...@darrylmiles.org added the comment:
I am unable to get make test to run from an unpatched version in SVN (details
below of make output).
Please find attached an updated patch for your consideration (and testing, as I
can't test it due to 'make test' SIGSEGV on CentOS
Darryl Miles darryl.mi...@darrylmiles.org added the comment:
To explain why you need 2 modes, a client/server would expect to do the
following pseudo actions for maximum efficiency:
set_socket_timeout(600_SECONDS) # or useful default
send_data_over_ssl(QUIT\r\n)
shutdown
Darryl Miles darryl.mi...@darrylmiles.org added the comment:
In order to build Python with a specific version of OpenSSL followed the CYGWIN
instructions and edited Modules/Setup to make it read (note - I added
-L$(SSL) into the linker options too, since by default on CentOS 5.4 i386
OpenSSL
Darryl Miles darryl.mi...@darrylmiles.org added the comment:
I've updated my attachment to the bug, if you read the old one please re-read
the updated version (since some points in there were not accurate).
With regards to the OpenSSL error return -1/ERROR_SYSCALL with errno==0 being
observed
Changes by Darryl Miles darryl.mi...@darrylmiles.org:
Removed file: http://bugs.python.org/file16838/python_ssl.c.txt
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8108
don't know of any reason that using sockets and
doing a packet capture would interfere with each other. What are you
trying to accomplish with the packet sniffing, though?
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
= self.im_self()
if obj is None: return None
return types.MethodType(self.im_func, obj, self.im_class)
# could alternately act like a callableproxy
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 16, 2009, at 10:39 PM, Steven D'Aprano wrote:
On Wed, 16 Sep 2009 22:08:40 -0700, Miles Kaufmann wrote:
On Sep 16, 2009, at 9:33 PM, Steven D'Aprano wrote:
I have two threads, one running min() and the other running max()
over
the same list. I'm getting some mysterious results which
, but not necessarily to your application). But a
threaded approach is somewhat silly, since the GIL ensures that they
*won't* walk over the same list simultaneously (two separate lists,
for that matter).
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
,
encoding=sys.stdout.encoding,
errors='xmlcharrefreplace')
http://mail.python.org/pipermail/python-list/2009-August/725100.html
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
to your code, and can then use those comments to restore the
correct indentation to a mangled version. (Most forums offer some
sort of whitespace-preserving [code] tag, though; and pindent is
relatively old, and apparently not well maintained (no support for
with blocks)).
-Miles
--
http
; they couldn't be
instantiated directly (from Python code), so you had to call the str()
function to create an object of type string. I think there may have
been some discussion of renaming the built-ins to match PEP 8 for
Python 3, but if so I doubt it got very far.
-Miles
--
http://mail.python.org
Changes by Chris Miles miles.ch...@gmail.com:
--
nosy: +chrismiles
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2320
___
___
Python-bugs-list
Changes by Miles Kaufmann mile...@umich.edu:
Removed file: http://bugs.python.org/file14796/urllib_parse.py3k.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5468
following it via the python-list@ mailing
list. The list owners do a great job of keeping the level of spam at
a minimum, though there are occasional false positives (like your
post, apparently, since I'm only seeing the replies).
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
Miles Kaufmann mile...@umich.edu added the comment:
I've attached a patch that provides similar functionality to Dan Mahn's
urlencode(), as well as providing encoding and errors parameters to
parse_qs and parse_qsl, updating the documentation to reflect the added
parameters, and adding test
and the class namespace, which would
be a nightmare of special cases (adding/deleting class attributes?
descriptors? __getattr__?) and require an implementation completely
separate from that of normal nested scopes.
-Miles
P.S. Just for fun:
import types
def make_class(*bases):
Decorator
On Aug 27, 2009, at 4:49 PM, kj wrote:
Miles Kaufmann mile...@umich.edu writes:
Guido's design justifications:
http://mail.python.org/pipermail/python-dev/2000-November/010598.html
Ah! Clarity! Thanks! How did you find this? Did you know of
this post already? Or is there some special
; besides, when I'm putting together a command and its
arguments, it's as convenient to build a list (['mycmd', 'myarg']) as
it is a string (if not more so).
-Miles
[1]: http://apple.slashdot.org/article.pl?sid=01/11/04/0412209#comment_2518563
--
http://mail.python.org/mailman/listinfo/python-list
.
It sounds like you should either be storing that name as an attribute
of the object, or using a dictionary ({'a': a, 'b': b, ...}).
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
?
In a diamond-inheritance situation, you may end up skipping methods
besides just B.method().
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
reading of the Python source (and svn
history), since it doesn't seem to be documented, so take it with a
grain of salt.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
On Jul 21, 2009, at 8:08 PM, Ronn Ross wrote:
Hello I'm trying to read an xml file using minidome. The xml looks
like:
rootNode
project
namemyProj/name
path/here//path
/project
/rootNode
My code looks like so:
from xml.dom.minidom import parse
dom = parse(myfile.xml)
for
On Jul 15, 2009, at 4:26 PM, David Bolen wrote:
Miles Kaufmann mile...@umich.edu writes:
On Jul 14, 2009, at 5:06 PM, David Bolen wrote:
Are you sure? It seems to restrict them in the same block, but
not in
the entire file. At least I was able to use both space and tab
indented blocks
the same obvious error ?
Try again with:
l = [('foo','bar'), ('foo', ''), ('', 'bar'), ('', '')]
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
?
No -- but in the not(not... example it doesn't short-circuit.
No; like 'A or B', 'not (not A and not B)' does in fact short-circuit
if A is True. (The 'and' condition does not have to evaluate the
right operand when 'not A' is False.)
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
generates bytecode such that all references to that name within the
function will be looked up in the local scope only, including those
before the assignment statement.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
(without replacing them all), which previously would have been
allowed, is now an error.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
and a) or (not a and b)
def xor(*args):
return reduce(xor2, args)
You may also find this question interesting:
http://stackoverflow.com/questions/432842/
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
in
goto fast_next_opcode are ticks.
Please correct me if _I'm_ wrong! :)
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
of to
directly hook into function namespace access and manipulation.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
On Jun 30, 2009, at 6:46 AM, venutaurus...@gmail.com wrote:
I have to write an automted script which will test my c
program. That program when run will ask for the commands.
Keep in mind that, if your test script checks the program's output
before giving it input, you can run into
to
work.
...
Notice that you are calling .group() on the match object instead
of .groups(). Without any arguments, .group() is equivalent
to .group(0), which means return the entire matching string.
http://docs.python.org/library/re.html#re.MatchObject.group
-Miles
--
http
and evaluate a dozen different ones.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
structure in
sorted order
if it doesn't exist, else retrieve it.
That's pretty much the bisect module in a nutshell. It manipulates a
sorted list using binary search.
With O(n) insertions and removals, though. A decent self-balancing
binary tree will generally do those in O(log n).
-Miles
a similar exception (Name or service not known), the root
problem may be a misconfiguration in your /etc/hosts or /etc/
resolv.conf files.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
: on dirs ... ok (Important)
Verifying: fifo ... ok
Verifying: devices ... ok
Verifying: combo-tests ...
Sub-test: xattrs + rsrc forks ... ok
Sub-test: lots of metadata ... ok
-Miles
--
http://mail.python.org/mailman/listinfo/python
are added (by AbstractHTTPHandler.do_request_) only if
they are missing.
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
# are not visible to enclosed functions
class Foo(object):
bar = ['a', 'b', 'c']
def _gen(_0):
for b in _0:
yield (bar.index(b), b)
baaz = list(_gen(iter(bar))
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
MethodType(self._func, cls if obj is None else obj, cls)
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
Changes by Miles Kaufmann mile...@umich.edu:
--
nosy: +milesck
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6234
___
___
Python-bugs-list mailing
Miles Kaufmann mile...@umich.edu added the comment:
parse_qs and parse_qsl should also grow encoding and errors parameters to
pass to the underlying unquote().
--
nosy: +milesck
___
Python tracker rep...@bugs.python.org
http://bugs.python.org
On Jun 9, 2009, at 6:05 AM, Diez B. Roggisch wrote:
Also as list-comps are going away and are replaced by
list(generator-expression)
Where did you hear that?
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
floating point number N such that a = N = b
for a = b
That's wrong. Where did you get it?
http://docs.python.org/library/random.html
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
you the source.
Sounds like di(), which can be written:
import _ctypes
di = _ctypes.PyObj_FromPtr
def can(o): return str(id(o))
def uncan(s): return di(int(s))
http://www.friday.com/bbum/2007/08/24/python-di/
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
from itertools import imap
def all_same(iterable):
it = iter(iterable)
return all(imap(partial(eq, it.next()), it))
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
You could try the python wrapper for OpenCV,
here is the link: http://code.google.com/p/ctypes-opencv/
Regards
Miles
--
http://mail.python.org/mailman/listinfo/python-list
into the SQL query for you; it will look something like
this (though the exact details will vary depending on what module
you're using):
cursor.execute('INSERT INTO my_table VALUES (?, ?, ?)', ['test',1,'two'])
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
it is done!
I believe those programs are able to do so because they are Finder
plugins--it's not something that a separate program could do. This
isn't really a Python question, though; you'd probably have better
luck finding answers on a OS X-related list.
-Miles
--
http://mail.python.org/mailman
should be illegal. ;)
-Miles
P.S. ... really, though.
--
http://mail.python.org/mailman/listinfo/python-list
of the generator that needs it. However, for small n,
the tee-based solution has the advantage of having most of the work
done in C instead of in Python generator functions; in my limited
benchmarking, the point where your version becomes faster is somewhere
around n=65.
-Miles
--
http://mail.python.org
://code.activestate.com/recipes/465156/
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
a tuple of N generators.
from itertools import islice, tee
def demux(iterable, n):
return tuple(islice(it, i, None, n) for (i, it) in
enumerate(tee(iterable, n)))
-Miles
--
http://mail.python.org/mailman/listinfo/python-list
1 - 100 of 210 matches
Mail list logo