Dave Johansen added the comment:
Ok, so I understand the issue now. `timestamp()` for naive datetime instances
applies the local timezone offset (
https://docs.python.org/3.6/library/datetime.html#datetime.datetime.timestamp
). This is surprising because naive datetime instances usually
Dave Johansen added the comment:
The use case was parsing user input of ISO 8601 date strings and converting
them to UNIX epochs. The input "0001-01-01T00:00:00" is valid, parses to a
valid `datetime` and it seems like a reasonable expectation that all of the
functions should work
Dave Johansen added the comment:
That's a valid `datetime` (i.e. within the min and max values) and `tzinfo` is
`None` so I think it's completely reasonable to assume that `timestamp()` will
return the correct value.
--
___
Python tracker <
New submission from Dave Johansen:
This worked in Python 3.6.0 and before:
```
from datetime import datetime
d = datetime(1, 1, 1, 0, 0, 0)
d.timestamp()
```
The error output is:
```
ValueError: year 0 is out of range
```
But it used to return `-62135658000.0`.
Appears to be related to https
On 04/04/2017 01:50 PM, Rob Gaddi wrote:
On 04/04/2017 10:23 AM, Dave wrote:
I don't care for the idea of replacing the data file for every save. My
preference would to append to the existing data file - makes more sense.
However, that is not how json works. So, I'm considering other
On 04/04/2017 10:17 AM, Michael Torrie wrote:
On 04/03/2017 11:31 PM, dieter wrote:
Dave <dbola...@fastmail.fm> writes:
I created a python program that gets data from a user, stores the data
as a dictionary in a list of dictionaries. When the program quits, it
saves the data file. My
to do that. The advice I have seen on the web is to load the
data when the program starts, append the new user input to the list,
then re-write the data file. Is that the best way, or is there a better
way?
Thanks,
Dave
--
https://mail.python.org/mailman/listinfo/python-list
Dave Anderson added the comment:
Sorry, should have shown sudo ls -l output for 3.6:
[vagrant@developer tmp]$ sudo ls -l Python-3.6.0
total 1016
-rw-r--r-- 1 caturra games 10910 Dec 22 18:21 aclocal.m4
-rwxr-xr-x 1 caturra games 42856 Dec 22 18:21 config.guess
-rwxr-xr-x 1 caturra games
New submission from Dave Anderson:
Downloaded https://www.python.org/ftp/python/3.6.0/Python-3.6.0.tgz
Extracted on CentOS6 with sudo tar -xf Python-3.6.0.tgz
Result:
[vagrant@developer tmp]$ ls -l Python-3.6.0
ls: cannot access Python-3.6.0/Tools: Permission denied
ls: cannot access Python
Dave Brondsema added the comment:
Yes, exactly.
--
___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue29443>
___
___
Python-bugs-list
Dave Brondsema added the comment:
A colleague has pointed out to me that this is available in the 2nd step within
"Modify". I didn't realize there were more options after the first "Modify"
screen. So perhaps the UI could be improved, b
New submission from Dave Brondsema:
If you miss the checkbox to set the "PATH" when installing Python for the first
time, there isn't any easy way to set it again. (And for new programmers,
having it set automatically is extremely useful). Uninstalling and
re-installing does w
Dave Jones added the comment:
I confess I'm going to have to read a bit more about Python internals before I
can understand Eryk's analysis (this is my first encounter with "cell
objects"), but many thanks for the rapid analysis and patch!
I'm not too concerned about the state be
New submission from Dave Jones:
While investigating a bug report in one of my libraries
(https://github.com/waveform80/picamera/issues/355) I've come across a
behaviour that appears in Python 3.6 but not prior versions. Specifically,
calling super() in a sub-class of a ctypes scalar type
New submission from Dave Jones:
While attempting to diagnose something (unrelated to this issue) under python
3.6, I used the following steps to clone and build a non-root python
installation:
$ mkdir py36
$ hg clone https://hg.python.org/cpython
$ cd cpython
$ hg update 3.6
Dave T added the comment:
Its on a windows 10
It doesn't come with the run application but the debug
--
nosy: +Dave T
versions: +Python 2.7 -Python 3.5
Added file: http://bugs.python.org/file45298/Py 2.7.JPG
___
Python tracker <
I am trying to associate the .py file extension with idle...where IS idle?
Can you make it a bit more difficult to load/use your software please.
--
https://mail.python.org/mailman/listinfo/python-list
Dave Sawyer added the comment:
No problem. I did a pull and reposted with additional fixes suggested by
Berker and one copy/paste error I spotted.
On Sat, Jun 4, 2016 at 11:34 PM, SilentGhost <rep...@bugs.python.org> wrote:
>
> SilentGhost added the comment:
>
> Thanks f
Dave Sawyer added the comment:
Updated optional parameters. Fixed executescript which takes a single
parameter. The English is correct - one needs to looks at the verbs to be sure
they match in tense and number. Like "He OPENS the fridge, GRABS the milk, and
DRINKS it." This meth
Dave Sawyer added the comment:
hurray! My first commit
--
___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27113>
___
___
Python-bugs-
Dave Sawyer added the comment:
This can go into bugfix branches. In fact, it's most likely to be helpful there
because they are more likely to be running with a version of sqlite 10 years
old. I use the sqlite3_libversion_number() call because I'm testing against the
version of sqlite
New submission from Dave Sawyer:
Starting in sqlite version 3.3.1 (Jan 2006) multiple threads can share the same
connection. Python allows you do use this with the check_same_thread parameter
of sqlite3.connect() method. It's almost certain users have a late enough
version of sqlite
Dave Sawyer added the comment:
Hi Thomas and Senthil, for the serialized setting I mentioned earlier "The
serialized mode is default on both Mac and Windows so we can probably skip
validating that. I did like mentioning the user needs to serialize the writes.
They could use one t
New submission from Dave Sawyer:
The three execute methods of the connection object return the created cursor.
The term "intermediate" implies the cursor is totally handled by the execute
method, not that the user will get ownership of the object.
When the user doesn't
Dave Sawyer added the comment:
Changed doc to note that not only must it be used on 1 thread if true, but that
thread must be the thread that created it.
--
___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/i
Dave Sawyer added the comment:
The user probably has a recent enough version. This is guaranteed on Windows
since Python bundles 3.6 or later. On mac or Linux it will use the version
installed on the machine. I'll make a separate patch to check the version in
sqlite3.py so it will give
Dave Sawyer added the comment:
The revised patch says "connections" plural for true and "connection" singular
for false. How about "the connection" since the method returns a connection.
I'm wondering though about the lack of explanation or WHY for this parame
Changes by Dave Sawyer <kingsaw...@gmail.com>:
--
title: sqlite3 open parameter "check_same_thread" not documented -> sqlite3
connect parameter "check_same_thread" not documented
___
Python tracker <rep...@bugs.pyt
New submission from Dave Sawyer:
The sqlite3.connect method has 6 parameters. 5 of them are documented. See
below and search for "check_same_thread". Patch adds documentation for this
parameter.
sqlite3.connect(database[, timeout, detect_types, isolation_level,
check_same_threa
kevind0...@gmail.com wrote:
>from Tkinter import *
>
>def butContinue():
>root1.destroy()
As Christian said, you're destroying the root window and its children,
so instead use root1.quit() here.
> ...
>
>root1.mainloop()
>
>print entryName.get("1.0", "end-1c" )
>print entryPWord.get("1.0",
New submission from Dave Hibbitts:
__len__() always returns an int which on windows machines is tied to the size
of a c long and is always 32 bits even if it's compiled for 64 bit. len()
however returns an int for values less than sys.maxint and a long above that.
Returning an int in __len__
Dave Farrance <df@see.replyto.invalid> wrote:
>It occurs to me now that the trackback might misidentify the module in
>use, if say, you'd named a file "numbers.py" then got rid of it later
>leaving a "numbers.pyc" somewhere. If so, see where it is:
>
>
It occurs to me now that the trackback might misidentify the module in
use, if say, you'd named a file "numbers.py" then got rid of it later
leaving a "numbers.pyc" somewhere. If so, see where it is:
import numbers
print numbers.__file__
--
https://mail.python.org/mailman/listinfo/python-list
jenswaelk...@gmail.com wrote:
> File "/usr/lib/python2.7/decimal.py", line 3744, in
>_numbers.Number.register(Decimal)
>AttributeError: 'module' object has no attribute 'Number'
Your decimal module seems broken. Confirm that in the Python shell:
import numbers
print numbers.Number
I'm
gemjack...@gmail.com wrote:
>This fixed my problem with thkinter. sudo cp ~/.Xauthority ~root/
Which means that you were creating a GUI window with Python as root,
which is to be avoided if you can. If you can't avoid it and you're
running it with sudo in a bash console, rather than a root
--
https://mail.python.org/mailman/listinfo/python-list
I'd like to install Numba on Debian Jessie to work with the system
Python 2.7.9 (rather than installing Anaconda).
When I follow the instructions at
https://github.com/numba/numba#custom-python-environments
...I get errors when trying to install Numba either with the git clone
method or
Dave Farrance <df@see.replyto.invalid> wrote:
>I'd like to install Numba on Debian Jessie to work with the system
>Python 2.7.9 (rather than installing Anaconda).
OK, never mind. Fixed.
By Googling the first error code, finding a suggested fix for that,
running again, Googling t
Stallone Carl wrote:
>I am currently using python 3.5.0 and I have been trying to write a program
>using turtle but is not seem to be working. I have followed all tutarial on
>the web and when i compare it with my code my am duing everything the same
>way but it still
sam Rogers wrote:
> I have downloaded python 2.7 with no problem. It works. I am trying to get
>pyserial to work. I have tried many different solutions. I am not sure if it
>works or not. How can I be sure? I am using windows 7. I did not see any help
>at python.org.
"D'Arcy J.M. Cain" wrote:
>On Fri, 4 Dec 2015 18:28:22 -0500
>Terry Reedy wrote:
>> Tk widgets, and hence IDLE windows, will print any character from
>> \u to \u without raising, even if the result is blank or ?.
>> Higher codepoints fail, but
I was taking it for granted that you knew how to set environment
variables, but just in case you don't: In the shell, (are you using
BASH?), put this:
export PYTHONIOENCODING=UTF-8
...then run your script.
Remember that this is *not* a permanent fix.
--
"D'Arcy J.M. Cain" wrote:
>...
>utf-8
>Traceback (most recent call last):
> File "./g", line 5, in
>print(u"\N{TRADE MARK SIGN}")
>UnicodeEncodeError: 'ascii' codec can't encode character '\u2122' in
>position 0: ordinal not in range(128)
I *presume* that you're
Alan Bawden wrote:
>Chris Angelico writes:
> ...
>> Python 2.7.8 (2.4.0+dfsg-3, Dec 20 2014, 13:30:46)
>> [PyPy 2.4.0 with GCC 4.9.2] on linux2
>> Type "help", "copyright", "credits" or "license" for more information.
>> tuple([]) is tuple([])
>> False
Cecil Westerhof wrote:
>On Wednesday 25 Nov 2015 23:58 CET, Laura Creighton wrote:
>>
>> Your Suse system probably wants to use python for something. If your
>> system python is damaged, you badly need to fix that, using the
>> system package managers tools, before Suse does
Marko Rauhamaa <ma...@pacujo.net> wrote:
>Dave Farrance <df@see.replyto.invalid>:
>
>> (Conversely, I see that unlike CPython, all PyPy's numbers have
>> unchanging ids, even after exiting PyPy and restarting, so it seems
>> that PyPy's numerical ids are &quo
Ben Finney <ben+pyt...@benfinney.id.au> wrote:
>Dave Farrance <df@see.replyto.invalid> writes:
>
>> Marko Rauhamaa <ma...@pacujo.net> wrote:
>>
>> >Dave Farrance <df@see.replyto.invalid>:
>> >
>> >> (Conversely, I see that
fl wrote:
>Hi,
>I find the following code snippet, which is useful in my project:
> ...
>correctly. Could you see something useful with variable 'sz'?
So that's example code in "An Introduction to the Kalman Filter" by Greg
Welch and Gary Bishop, and no, that construct was
Steven D'Aprano wrote:
>On Mon, 16 Nov 2015 05:15 pm, Gregory Ewing wrote:
>
>> Ints are not the only thing that // can be applied to:
>>
>> >>> 1.0//0.01
>> 99.0
>
>Good catch!
Hmmm. I see that the float for 0.01 _is_ slightly larger than 0.01
>>> Decimal(0.01)
Dave Jones added the comment:
Ah, sorry about that - force of habit. I did wonder if it was preferable to
have a nicely wrapped patch, or to have a clean diff but obviously figured
wrong! I'll know for future :)
--
___
Python tracker <
fl wrote:
>I read the following code snippet. A question is here about '@'.
>I don't find the answer online yet.
I recommend this:
"Understanding Python Decorators in 12 Easy Steps!"
http://simeonfranklin.com/blog/2012/jul/1/python-decorators-in-12-steps/
--
Dave Jones added the comment:
As suggested, doc patch attached to new issue 25615.
--
___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/i
PythonDude wrote:
>On Thursday, 12 November 2015 22:57:21 UTC+1, Robert Kern wrote:
>> He simply instantiated the two vectors as row-vectors instead of
>> column-vectors,
>> which he could have easily done, so he had to flip the matrix expression.
>
>Thank you very
New submission from Dave Jones:
As suggested in issue 21748, this is a minor documentation change to make
explicitly clear that glob.glob returns unsorted results (on the basis that the
existing specification references shell behaviour which is always sorted).
--
assignee: docs@python
Dave Jones added the comment:
>From the bash man-page: "... If one of these characters appears, then the word
>is regarded as a pattern, and replaced with an *alphabetically sorted* list of
>filenames matching the pattern".
I would agree that glob.glob shouldn't sort its re
Random832 wrote:
>The opposite of line buffering is not no buffering, but full
>(i.e. block) buffering, that doesn't get flushed until it runs
>out of space. TextIOWrapper has its own internal buffer, and its
>design apparently doesn't contemplate the possibility of using
Tim Golden wrote:
>I'm afraid you've been bitten by the fact that we no longer support
>Windows XP and haven't communicated this very well. We have a new
>version of the installer almost ready for release which indicates this
>much earlier (and more obviously). I'm
Rob Gaddi wrote:
>So, this is odd. I'm running Ubuntu 14.04, and my system did a kernel
>upgrade from the repository from 3.13.0-63-generic to 3.13.0-65-generic.
>And pyserial (2.7, installed through pip) stopped working.
When KDE's "Plasma 5" appeared
I'm trying to set up the basics of a timer-scheduled function in
matplotlib and I can't figure out how to stop the timer. Maybe the
stop() method is dysfunctional in Ubuntu 14.04 or maybe I'm getting the
syntax wrong.
If anybody's got matplotlib installed, can you try this code and tell me
if it
Laura Creighton <l...@openend.se> wrote:
>In a message of Thu, 01 Oct 2015 18:45:06 +0100, Dave Farrance writes:
>>Yet the documentation says that it's mandatory for the GUI backend base
>>to implement stop() but that single_shot is optional. Ho hum.
>
>report as a b
Laura Creighton <l...@openend.se> wrote:
>In a message of Thu, 01 Oct 2015 17:36:50 +0100, Dave Farrance writes:
>>I'm trying to set up the basics of a timer-scheduled function in
>>matplotlib and I can't figure out how to stop the timer. Maybe the
>>stop() method is dy
Laura Creighton <l...@openend.se> wrote:
>In a message of Thu, 01 Oct 2015 20:03:26 +0100, Dave Farrance writes:
>>Laura Creighton <l...@openend.se> wrote:
>>
>>>In a message of Thu, 01 Oct 2015 18:45:06 +0100, Dave Farrance writes:
>>>>Yet the do
"ast" wrote:
>DISPLAYSURF = pygame.display.set_mode((400, 300))
>pygame.display.set_caption('Hello World!')
>
>The first line opens a 400x300 pygame window.
>The second one writes "Hello World" on top of it.
>
>I am just wondering how function set_caption finds the windows
Dave Hein added the comment:
Thanks. I installed py34-readline and rebuilt my virtualenv; all is well now.
I put in a MacPorts ticket when their bugtracker gets back online.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org
New submission from Dave Hein:
With 3.4.3 from an OS X terminal prompt, if I just enter the interactive Python
REPL environment (by just entering the command python from the command line)
and then exit (via exit() or Ctrl-D), then stdout appears to be broken ... I
see no stdout output
shiva upreti katewinslet...@gmail.com wrote:
Hi
I am new to linux. I tried various things in attempt to install kivy. I
installed python 2.7.10
Just to make clear what others have said -- replacing Ubuntu 14.04's
system Python 2.7.6 is a bad idea and will break stuff, so if you really
must have
Dwight GoldWinde dwi...@goldwinde.com wrote:
Here are the results I got below, showing the same error. The first line
says,
2.7.6 (default, Sep 9 2014, 15:04:36)”. Does that mean I am running the
old Python? How could that be since I am SURE I downloaded 3.4.3 (it even
gives the folder name as
ryguy7272 ryanshu...@gmail.com wrote:
PERFECT!! SO SIMPLE!!
I don't know why the author didn't do that in the book.
The book is evidently giving you code snippets to enter into Python's
own interactive interpreter, i.e., you enter python at the command
line, then you manually type each command
Fabien fabien.mauss...@gmail.com wrote:
another solution with less (([[]])), and less ;. There are way too
many ; in Matlab ;)
import numpy as np
v1 = [1, 2, 3]
v2 = [4, 5, 6]
v3 = [7, 8, 9]
v4 = [10, 11, 12]
np.hstack([[v1, v2], [v3, v4]]).T
Out[]:
array([[ 1, 4],
[ 2, 5],
[
Rustom Mody rustompm...@gmail.com wrote:
On Saturday, June 6, 2015 at 10:20:49 AM UTC+5:30, Steven D'Aprano wrote:
On Sat, 6 Jun 2015 01:20 pm, Rustom Mody wrote:
As a parallel here is Dijkstra making fun of AI-ers use of the word
'intelligent'
Steven D'Aprano st...@pearwood.info wrote:
On Mon, 1 Jun 2015 07:36 pm, Marko Rauhamaa wrote:
However, I constantly run into engineers who don't understand what
zero means.
Okay, I'll bite.
What does zero mean, and how do engineers misunderstand it?
There are two hard things in computer
Laura Creighton l...@openend.se wrote:
If you are giving a talk about Decimal -- and trying to stamp out the
inappropriate use of floats you have to first inform people that
what they learned as 'decimals' as children was not floating point,
despite the fact that we write them the same way. ...
Skip Montanaro skip.montan...@gmail.com wrote:
P.S., Dave, your omitthis and andthis kind of sucks for the rest of us.
And I just invalidated your attempts at
obscurity by replying to your correct email address. I suggest you just
omit that stuff going forward. Unfortunately,
I now I have a crap
Peter Otten __pete...@web.de wrote:
so both +0.0 and -0.0 would be skipped anyway.
Maybe the coder was simply aiming for visibility. The unary minus can
be hard to spot in some circumstances. e.g.: I've sneaked a unary minus
into this maths proof, which makes it horrible (although correct):
u
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote:
I'd like to do a little survey, and get a quick show of hands.
How many people have written GUI or text-based applications or scripts where
a Move file to trash function would be useful?
Would you like to see that in the standard
On 05/14/2015 01:02 PM, BartC wrote:
On 14/05/2015 17:09, Chris Angelico wrote:
On Fri, May 15, 2015 at 1:51 AM, BartC b...@freeuk.com wrote:
OK, the answer seems to be No then - you can't just trivially compile
the C
modules that comprise the sources with the nearest compiler to hand.
So much
On 05/13/2015 07:24 PM, 20/20 Lab wrote:
I'm a beginner to python. Reading here and there. Written a couple of
short and simple programs to make life easier around the office.
Welcome to Python, and to this mailing list.
That being said, I'm not even sure what I need to ask for. I've never
On 05/13/2015 08:45 PM, 20/20 Lab wrote:
You accidentally replied to me, rather than the mailing list. Please
use reply-list, or if your mailer can't handle that, do a Reply-All, and
remove the parts you don't want.
On 05/13/2015 05:07 PM, Dave Angel wrote:
On 05/13/2015 07:24 PM, 20/20
On 05/12/2015 03:58 PM, zljubisic...@gmail.com wrote:
On Tuesday, May 12, 2015 at 9:49:20 PM UTC+2, Ned Batchelder wrote:
If you need to use globals, assign them inside a parse_arguments
function that has a global statement in it.
This advice is consistent with Chris' define things before
On 05/11/2015 07:46 AM, Skybuck Flying wrote:
Hello,
Sometimes it can be handy to interrupt/reset/reposition a running script.
For example something externally goes badly wrong.
os.kill()
then in your process, handle the exception, and do whatever you think is
worthwhile.
--
DaveA
--
On 05/11/2015 08:35 AM, Steven D'Aprano wrote:
On Mon, 11 May 2015 09:57 pm, Dave Angel wrote:
On 05/11/2015 07:46 AM, Skybuck Flying wrote:
Hello,
Sometimes it can be handy to interrupt/reset/reposition a running
script.
For example something externally goes badly wrong.
os.kill
On 05/10/2015 05:10 PM, zljubisic...@gmail.com wrote:
No, we can't see what ROOTDIR is, since you read it from the config
file. And you don't show us the results of those prints. You don't
even show us the full exception, or even the line it fails on.
Sorry I forgot. This is the output of
On 05/09/2015 11:33 PM, Chris Angelico wrote:
On Sun, May 10, 2015 at 12:45 PM, Steven D'Aprano
steve+comp.lang.pyt...@pearwood.info wrote:
This is the point where some people try to suggest some sort of complicated,
fragile, DWIM heuristic where the compiler tries to guess whether the user
On 05/09/2015 09:51 PM, Vincent Davis wrote:
On Sat, May 9, 2015 at 5:55 PM, Dave Angel da...@davea.name wrote:
1) you're top-posting, putting your response BEFORE the stuff you're
responding to.
I responded to my own email, seemed ok to top post on myself saying it was
resolved.
Yeah, I
On 05/09/2015 07:01 PM, Vincent Davis wrote:
Not sure what I was doing wrong, it seems to work now.
I still see two significant things wrong:
1) you're top-posting, putting your response BEFORE the stuff you're
responding to.
2) both messages are in html, which thoroughly messed up parts
On 05/09/2015 05:04 PM, vjp2...@at.biostrategist.dot.dot.com wrote:
Thanks.. I suspected it wasn't meant to be taken as in the file
THe one thing I'm not sure if Jython is suppsosedto keep running
after the initisl stuff is loaded in..
To put the question in purely DOS terms if you run a
On 05/09/2015 03:59 AM, david jhon wrote:
Hi, I am sorry for sending in five attachments, I cloned the code from here
https://bitbucket.org/msharif/hedera/src: Let me explain it here:
Please don't top-post. Your earlier problem description, which I could
make no sense of, is now located
On 05/09/2015 06:31 AM, zljubisic...@gmail.com wrote:
title = title[:232]
title = title.replace( , _).replace(/, _).replace(!, _).replace(?,
_)\
.replace('', _).replace(':', _).replace(',',
_).replace('#34;', '')\
.replace('\n', '_').replace('#39',
On 05/08/2015 06:53 AM, Frank Millman wrote:
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote in message
news:554c8b0a$0$12992$c3e8da3$54964...@news.astraweb.com...
On Fri, 8 May 2015 06:01 pm, Frank Millman wrote:
Hi all
[...]
However, every time I look at my own code, and I
On 05/08/2015 02:42 AM, Chris Angelico wrote:
On Fri, May 8, 2015 at 4:36 PM, Rustom Mody rustompm...@gmail.com wrote:
On Friday, May 8, 2015 at 10:39:38 AM UTC+5:30, Chris Angelico wrote:
Why have the concept of a procedure?
On Friday, Chris Angelico ALSO wrote:
With print(), you have a
On 05/08/2015 06:59 AM, Denis McMahon wrote:
On Wed, 06 May 2015 00:23:39 -0700, Palpandi wrote:
On Wednesday, May 6, 2015 at 12:07:13 PM UTC+5:30, Palpandi wrote:
Hi,
What are the ways to encrypt python files?
No, I just want to hide the scripts from others.
You can do that by deleting
On 05/07/2015 06:24 AM, Chris Angelico wrote:
On Thu, May 7, 2015 at 8:10 PM, Marko Rauhamaa ma...@pacujo.net wrote:
Stefan Zimmermann zimmermann.c...@gmail.com:
And last but not least, Popen behavior on Windows makes it difficult
to write OS-independent Python code which calls external
On 05/06/2015 09:55 AM, Chris Angelico wrote:
On Wed, May 6, 2015 at 11:12 PM, Dave Angel da...@davea.name wrote:
I had guessed that the order of multiplication would make a big difference,
once the product started getting bigger than the machine word size.
Reason I thought that is that if you
On 05/06/2015 02:26 AM, Steven D'Aprano wrote:
On Wednesday 06 May 2015 14:05, Steven D'Aprano wrote:
My interpretation of this is that the difference has something to do with
the cost of multiplications. Multiplying upwards seems to be more expensive
than multiplying downwards, a result I
On 05/06/2015 04:27 PM, noydb wrote:
I have a zip file containing several files and I want to extract out just the
.xml file. I have that code. Curious if this xml file can be extracted into
memory. If so, how to? I only need to move the file around, and maybe read
some tags.
Thanks for
On 05/06/2015 11:36 AM, Alain Ketterlin wrote:
Yes, plus the time for memory allocation. Since the code uses r *=
..., space is reallocated when the result doesn't fit. The new size is
probably proportional to the current (insufficient) size. This means
that overall, you'll need fewer
On 05/06/2015 06:11 PM, Stefan Zimmermann wrote:
Hi.
I don't like that subprocess.Popen(['command']) only works on Windows if there
is a command.exe in %PATH%.
As a Windows user you would normally expect that also command.bat and
command.cmd can be run that way.
and command.com.
If
On 05/05/2015 05:39 PM, Ian Kelly wrote:
On Tue, May 5, 2015 at 3:23 PM, Ian Kelly ian.g.ke...@gmail.com wrote:
On Tue, May 5, 2015 at 3:00 PM, Dave Angel da...@davea.name wrote:
def loop(func, funcname, arg):
start = time.time()
for i in range(repeats):
func(arg, True
On 05/05/2015 11:25 AM, Cecil Westerhof wrote:
I have a file with quotes and a file with tips. I want to place random
messages from those two (without them being repeated to soon) on my
Twitter page. This I do with ‘get_random_message’. I also want to put
the first message of another file and
On 05/05/2015 02:19 PM, Paul Moore wrote:
You need to specify that you're using Python 3.4 (or whichever) when
starting a new thread.
I want to write a string to an already-open file (sys.stdout, typically).
However, I *don't* want encoding errors, and the string could be arbitrary
Unicode
101 - 200 of 4139 matches
Mail list logo