Ian Kelly ian.g.ke...@gmail.com:
I already mentioned this earlier in the thread, but a balanced binary
tree might implement += as node insertion and then return a different
object if the balancing causes the root node to change.
True.
Speaking of which, are there plans to add a balanced tree
On Sat, Mar 8, 2014 at 1:34 AM, Marko Rauhamaa ma...@pacujo.net wrote:
Speaking of which, are there plans to add a balanced tree to the
batteries of Python? Timers, cache aging and the like need it. I'm
using my own AVL tree implementation, but I'm wondering why Python
still doesn't have one.
Ian Kelly ian.g.ke...@gmail.com:
Peeking at the code, it appears to use a heapq-based priority queue.
Why would a balanced binary tree be better?
AFAIK, a heap queue doesn't allow for the deletion of a random element
forcing you to leave the canceled timers in the queue to be deleted
later.
How to recovery the default Library/Python/ folder on Mac?
I delete it by some mistakes..., I have tried the following steps:
- Step 1. Download and install Python DMG from Python.org .
Result: There are no Python folders under Library after I installed the
Python DMG.
-
Hi,
(Please forgive (or correct) my mistakes, i am non native)
http://www.python.org/community/sigs/retired/parser-sig/towards-standard/
* Formatting bug
* Needs breadcrumb navigation (Where am i?)
(i came there via http://theory.stanford.edu/~amitp/yapps/)
* blue background makes top links
I did some work in c# and java and I converted some application to Python; I
noticed Python is much slower than the other languages.
Is this normal ?
Thanks
--
https://mail.python.org/mailman/listinfo/python-list
On 08/03/2014 03:49, Chris Angelico wrote:
On Sat, Mar 8, 2014 at 2:21 PM, thrinaxodon...@gmail.com wrote:
I think it's better if you (CENSORED) off.
Teddybubu, please understand that the above comment is from a spammer
and does not reflect the prevailing attitude of this list. I don't
like
On Sun, Mar 9, 2014 at 12:13 AM, Mark Lawrence breamore...@yahoo.co.uk wrote:
On 08/03/2014 03:49, Chris Angelico wrote:
On Sat, Mar 8, 2014 at 2:21 PM, thrinaxodon...@gmail.com wrote:
I think it's better if you (CENSORED) off.
Teddybubu, please understand that the above comment is from a
On Sat, Mar 8, 2014 at 11:53 PM, JCosta generalco...@gmail.com wrote:
I did some work in c# and java and I converted some application to Python; I
noticed Python is much slower than the other languages.
Is this normal ?
Thanks
The first thing to look at is the conversion. If you convert
On 3/8/14 7:44 AM, Nils-Hero Lindemann wrote:
Hi,
(Please forgive (or correct) my mistakes, i am non native)
http://www.python.org/community/sigs/retired/parser-sig/towards-standard/
* Formatting bug
* Needs breadcrumb navigation (Where am i?)
(i came there via
python debuginfo is installed...
Still,py-bt, py-locals.etc cannot read python frame
--
https://mail.python.org/mailman/listinfo/python-list
1. install gdb from source with configure option --with-python
2. install python from source with configure option --with-pydebug
3. Got error in gdb here:
2.6.6 (r266:84292, Jan 22 2014, 09:42:36)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-4)]
(gdb) py-bt
Undefined command: py-bt. Try help.
(gdb)
On 2014-03-08 04:53, JCosta wrote:
I did some work in c# and java and I converted some application to
Python; I noticed Python is much slower than the other languages.
Is this normal ?
It depends.
Did you write C#/Java in Python (i.e., use C# or Java idioms in
Python), or did you write
On 3/8/14 8:31 AM, Ned Batchelder wrote:
On 3/8/14 7:44 AM, Nils-Hero Lindemann wrote:
Hi,
(Please forgive (or correct) my mistakes, i am non native)
http://www.python.org/community/sigs/retired/parser-sig/towards-standard/
* Formatting bug
* Needs breadcrumb navigation (Where am i?)
(i
On 08/03/2014 13:32, Wesley wrote:
python debuginfo is installed...
Still,py-bt, py-locals.etc cannot read python frame
If you don't provide context people are less likely to help you.
--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.
On Fri, 07 Mar 2014 16:15:36 -0800, Dan Stromberg wrote:
On Fri, Mar 7, 2014 at 3:11 AM, Steven D'Aprano
steve+comp.lang.pyt...@pearwood.info wrote:
Assertions are not bad! They're just misunderstood and abused.
You should read this guy's blog post on when to use assert:
Now I use gdb python -p pid
then, import libpython
py-bt is null, py-locals raise here:
Unable to locate python frame
What's going on...
--
https://mail.python.org/mailman/listinfo/python-list
So, let me clarify here, in order to try, I get a clean machine.
Centos 6.5 64bit.
Now , I try this:
1. install gdb 7.7 from source , with configure option --with-python
2. install python 2.6.6 from source, with configure option --with-pydebug
3. run a python script
4. from command line, gdb
Hello,
The source for the site is on github, and they are taking and resolving
issues there: https://github.com/python/pythondotorg/issues
Thanks for pointing me to the right place. I copypasted my mail to ...
https://github.com/python/pythondotorg/issues/266
also i added a comment to ...
for line in all_kbd:
if line.string == None:
I modified your code slightly:
for line in all_kbd:
print(line)
sys.exit()
if line.string == None:
Running the new script yields:
$ python shibly.py
kbd class=command
cp -v --remove-destination /usr/share/zoneinfo/
em
JCosta generalco...@gmail.com:
I did some work in c# and java and I converted some application to
Python; I noticed Python is much slower than the other languages.
Is this normal ?
Yes. The main reason is the dot notation, which in C through Java is
implemented by the compiler as a fixed
Sábado, 8 de Março de 2014 12:53:57 UTC, JCosta escreveu:
I did some work in c# and java and I converted some application to Python; I
noticed Python is much slower than the other languages.
Is this normal ?
Thanks
...
Thanks for the help (Chris, Tim and Marko) and it´s
On 08/03/2014 18:30, JCosta wrote:
Sábado, 8 de Março de 2014 12:53:57 UTC, JCosta escreveu:
I did some work in c# and java and I converted some application to Python; I
noticed Python is much slower than the other languages.
Is this normal ?
Thanks
...
Thanks for the help
On 3/8/14 7:53 AM, JCosta wrote:
I did some work in c# and java and I converted some application to Python; I
noticed Python is much slower than the other languages.
Is this normal ?
Thanks
Your question, and the replies so far in this thread, have overlooked
the difference between
On Sat, Mar 8, 2014 at 12:34 AM, Marko Rauhamaa ma...@pacujo.net wrote:
Ian Kelly ian.g.ke...@gmail.com:
I already mentioned this earlier in the thread, but a balanced binary
tree might implement += as node insertion and then return a different
object if the balancing causes the root node to
On 08/03/2014 19:58, Dan Stromberg wrote:
On Sat, Mar 8, 2014 at 12:34 AM, Marko Rauhamaa ma...@pacujo.net wrote:
Ian Kelly ian.g.ke...@gmail.com:
I already mentioned this earlier in the thread, but a balanced binary
tree might implement += as node insertion and then return a different
object
Mark Lawrence breamore...@yahoo.co.uk:
I believe that there are advantages to leaving specialist data
structures on pypi or other sites, plus it means Python in a Nutshell
can still fit in your pocket and not a 40 ton articulated lorry,
unlike the Java equivalent.
An ordered map is a
On Friday, March 7, 2014 4:38:54 PM UTC-8, Dennis Lee Bieber wrote:
On Fri, 7 Mar 2014 10:03:35 -0800 (PST), John Ladasky
j...@sbcglobal.net declaimed the following:
More than once, I have queried Google with the phrase Why isn't FORTRAN
dead yet? For some reason, it lives on. I can't
In article 87eh2ctmht@elektro.pacujo.net,
Marko Rauhamaa ma...@pacujo.net wrote:
If I had to choose between a hash table and AVL (or RB) tree in the
standard library, it would definitely have to be the latter. It is more
generally usable, has fewer corner cases and probably has an equal
Ian Kelly wrote:
class LessThanFilter:
def __init__(self, the_list):
self._the_list = the_list
def __getitem__(self, bound):
return [x for x in self._the_list if x bound]
filter = LessThanFilter([10, 20, 30, 40, 50])
filter[25] += [15, 17, 23]
Should that last line
Ian Kelly wrote:
I already mentioned this earlier in the thread, but a balanced binary
tree might implement += as node insertion and then return a different
object if the balancing causes the root node to change.
That would be a really bad way to design a binary tree
implementation. What if
On Sat, Mar 8, 2014 at 1:21 PM, Marko Rauhamaa ma...@pacujo.net wrote:
If I had to choose between a hash table and AVL (or RB) tree in the
standard library, it would definitely have to be the latter. It is more
generally usable, has fewer corner cases and probably has an equal
performance even
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
I realize I shouldn't write code that depends on any relevant
implementation details, but knowing some of the more common
implementation options would probably help build an intuition for
what's going on
On 2014-03-09 02:08, Dan Stromberg wrote:
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
I realize I shouldn't write code that depends on any relevant
implementation details, but knowing some of the more common
implementation options would probably
On Sat, Mar 8, 2014 at 5:40 PM, Gregory Ewing
greg.ew...@canterbury.ac.nz wrote:
Ian Kelly wrote:
class LessThanFilter:
def __init__(self, the_list):
self._the_list = the_list
def __getitem__(self, bound):
return [x for x in self._the_list if x bound]
filter =
On 2014-03-09 02:40, MRAB wrote:
On 2014-03-09 02:08, Dan Stromberg wrote:
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
I realize I shouldn't write code that depends on any relevant
implementation details, but knowing some of the more common
On Sat, 08 Mar 2014 18:08:38 -0800, Dan Stromberg wrote:
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
There are various common ways to store Unicode strings in RAM.
The first, UTF-16, treats every character [aside: technically, a code
point]
On Sat, Mar 8, 2014 at 5:45 PM, Gregory Ewing
greg.ew...@canterbury.ac.nz wrote:
Ian Kelly wrote:
I already mentioned this earlier in the thread, but a balanced binary
tree might implement += as node insertion and then return a different
object if the balancing causes the root node to change.
On Sun, Mar 9, 2014 at 1:08 PM, Dan Stromberg drsali...@gmail.com wrote:
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
I realize I shouldn't write code that depends on any relevant
implementation details, but knowing some of the more common
In article 531bd709$0$29985$c3e8da3$54964...@news.astraweb.com,
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote:
There are various common ways to store Unicode strings in RAM.
The first, UTF-16.
[...]
Another option is UTF-32.
[...]
Another option is to use UTF-8 internally.
On Sunday, March 9, 2014 8:20:49 AM UTC+5:30, Steven D'Aprano wrote:
No version of Python has, to my knowledge, used UTF-8 internally. Some
other languages, such as Go and Haskell, do, and consequently string
processing is slow for them.
Haskell: Its more like: Heres the menu, take your pick
On Sun, Mar 9, 2014 at 2:01 PM, Roy Smith r...@panix.com wrote:
In article 531bd709$0$29985$c3e8da3$54964...@news.astraweb.com,
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote:
There are various common ways to store Unicode strings in RAM.
The first, UTF-16.
[...]
Another
On 3/8/14 9:08 PM, Dan Stromberg wrote:
OK, I know that Unicode data is stored in an encoding on disk.
But how is it stored in RAM?
I realize I shouldn't write code that depends on any relevant
implementation details, but knowing some of the more common
implementation options would probably
Anybody has suggestions?
This really makes me crazy...
--
https://mail.python.org/mailman/listinfo/python-list
On Sun, 09 Mar 2014 03:50:49 +, Steven D'Aprano wrote:
... UTF-16 ... the letter A is stored as two bytes 0x0041 (or 0x4100
depending on your platform's byte order) ...
At the risk of being pedantic, the two bytes are 0x00 and 0x41, and the
order in which they appear in memory depends on
Hello,
I have tried to process.popen to run java program with Japanese language.
test.java is compiled with utf8
'日本語' below means Japanese in Japanese.
but it does not work. Anyone who knows this matter well. Please help.
Jun
python code
sentence = '日本語'
filename = 'japanese'
java_file =
Norman Denayer added the comment:
I guess it's logical to have the value turned to '' in the reader, but I
would expect the same transformation in the writer.
If the write function would write for an empty string, will it solve your
issue?
--
keywords: +patch
nosy: +Norman.Denayer
New submission from Domenico Mustara:
Not a new issue, many Python users have already written about this error. In
line 128 of IOBinding.py file, please change 'str = str.split(\n, 2)[:2] to
lst = str.split(\n, 2)[:2]. This error prevents IDLE from working correctly
when a .py file is loaded.
Changes by Pramod Jadhav jadhavpamu2...@gmail.com:
--
nosy: pramod.jadhav
priority: normal
severity: normal
status: open
title: how to import json file in mongodb using pymongo
versions: Python 2.7
___
Python tracker rep...@bugs.python.org
New submission from Pramod Jadhav:
import sys
import envoy
from bson import json_util # Comes with pymongo
from pymongo import MongoClient
from pprint import pprint
import json
client =
pymongo.MongoClient('mongodb://user:user...@ds033499.mongolab.com:33499/enron')
r =
Nick Coghlan added the comment:
pip 1.5.3 has been bundled and cherry picked to the release clone.
--
resolution: - fixed
stage: commit review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
Nick Coghlan added the comment:
After attempting to fix these docs in place, I now think that's a doomed
effort. However, we can't just delete them, because they still contain details
that haven't been moved to the distutils module docs or the Python Packaging
User Guide yet.
So, what I'm
New submission from Milan Oberkirch:
Accorcing to coveragepy there was only one line missing for full line coverage
in Lib/email/policy.py so I added an test to cover it.
It checks that the function email.policy.EmailPolicy.header raises an
ValueError if the second parameter includes newlines
Antoine Pitrou added the comment:
Agreed with David's latest analysis.
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18678
___
Nick Coghlan added the comment:
I like the way the attached patch has worked out - I think it's complete from a
structural point of view.
The two missing pieces are to fill in the contents for the new Installing and
Distributing guides, and those will be kept deliberately short, since we want
R. David Murray added the comment:
Indeed it has been reported before, and fixed. (It's a little hard to find the
issue by searching the tracker, though.) Issue 19426.
--
nosy: +r.david.murray
resolution: - duplicate
stage: - committed/rejected
status: open - closed
superseder: -
R. David Murray added the comment:
This tracker is for reporting bugs in CPython and the Python standard library.
pymongo is not part of the standard library. Please use the pymongo support
channels for your question. (Their help channels...it does not look like this
is a bug report.) You
Changes by R. David Murray rdmur...@bitdance.com:
--
components: +email
nosy: +barry, r.david.murray
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20871
___
Richard Oudkerk added the comment:
I am not sure method_to_typeid and create_method were really intended to be
public -- they are only used by Pool proxies.
You can maybe work around the problem by registering a second typeid without
specifying callable. That can be used in method_to_typeid:
New submission from R. David Murray:
We just added context manager support to dbm to close the object automatically,
but the 'close' method that gets called is not documented for any of the dbm
objects. Since it is part of the public API (it is shown in the example), I
think it should be.
Ned Deily added the comment:
More specifically, the bug that causes the problem was first released in the
2.7.6 release candidate 1 (pre-release, 2013-10-26) and fixed in the official
2.7.6 final release (2013-11-10). So it is somewhat surprising that you would
continually re-encounter it.
Roundup Robot added the comment:
New changeset 1853679c6f71 by R David Murray in branch 'default':
whatsnew: base65 encodings. (#17618)
http://hg.python.org/cpython/rev/1853679c6f71
--
___
Python tracker rep...@bugs.python.org
Roundup Robot added the comment:
New changeset b861c7717c79 by R David Murray in branch 'default':
whatsnew: Wave_write handles unseekable files. (#5202)
http://hg.python.org/cpython/rev/b861c7717c79
--
___
Python tracker rep...@bugs.python.org
Roundup Robot added the comment:
New changeset 200207e50cbf by R David Murray in branch 'default':
whatsnew: dbm.open is context manager. (#19282)
http://hg.python.org/cpython/rev/200207e50cbf
--
___
Python tracker rep...@bugs.python.org
Roundup Robot added the comment:
New changeset b72615222c98 by R David Murray in branch 'default':
whatsnew: sunau/aifc/wave writeframes[raw] accept any bytes-like (#8311)
http://hg.python.org/cpython/rev/b72615222c98
--
___
Python tracker
Roundup Robot added the comment:
New changeset 1853679c6f71 by R David Murray in branch 'default':
whatsnew: base65 encodings. (#17618)
http://hg.python.org/cpython/rev/1853679c6f71
--
nosy: +python-dev
___
Python tracker rep...@bugs.python.org
R. David Murray added the comment:
I had to edit that paragraph for another issue, so I fixed the wording along
the lines Éric suggested while I was at it.
Hmm. But it still needs to be fixed in 3.3 (and 2.7, I presume) :(
--
resolution: - fixed
Marcus Smith added the comment:
Legacy version. nice.
btw,
http://packaging.python.org/en/latest/tutorial.html#creating-and-using-virtual-environments;
will certainly end up including pyvenv command examples as well. currently
just mentioned in a footnote.
like I mentioned on
Michael Foord added the comment:
That's correct.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20145
___
___
Python-bugs-list mailing list
Alexander Mohr added the comment:
how about instead we rename the new parameter to dirs_exists_ok or something
like that since the method already allows for existing files.
--
___
Python tracker rep...@bugs.python.org
Nick Coghlan added the comment:
Thanks for the feedback!
Could you lob that last one at the pythondotorg issue tracker on GitHub (
https://github.com/python/pythondotorg/issues)?
--
___
Python tracker rep...@bugs.python.org
Nick Coghlan added the comment:
And regarding moving the still-relevant content to the main distutils docs,
yeah that's still a good idea. However, that's going to take a fair bit
more work, since you'll need to evaluate the legacy content to decide what
needs preserving, and I don't know the
Elias Zamaria added the comment:
I am not sure. I am not on the python-ideas mailing list, and I am not sure
what adding and maintaining the discussion would entail, or if I would have
the time to do it or want to deal with the clutter in my inbox. I just
committed this patch because it seemed
Alexander Mohr added the comment:
I personally dont think this is worth investing the time for a discussion.
If the maintainers dont want to accept this or a minor variation without a
discussion ill just keep my local monkeypatch :) thanks again for the
quick patch Elias!
On Mar 8, 2014 4:03
Changes by mélomane knorman...@gmail.com:
--
nosy: mélomane
priority: normal
severity: normal
status: open
title: ID
versions: Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20873
R. David Murray added the comment:
I don't understand why PendingDeprecationWarning was used here.
DeprecationWarnings are silent by default. I'm also not clear on why this is
being delayed until 3.6, instead of being changed in 3.5 after a deprecation,
given that the default is considered
New submission from mélomane:
First time using Python on my personal computer. Updated the mac version to
3.3. Then installed ActiveTcl 8.6.1.0, then tried deleting and installing
8.5.15.0. I tried opening IDLE from the applications folder, then from
terminal. After that failed to work, I
R. David Murray added the comment:
This isn't really a python question, it's a mac question. Unless there is
something the mac installer should be doing to detect this situation..but...are
you running the python that comes with the OS, or did you install it yourself?
Because if it is the
Ned Deily added the comment:
The fact that ls shows a UID of 501 instead of your user name Charlotte
strongly suggests you have an inconstantly defined user account. Suggest you
try cresting a new Administrator user via System Preferences - User
Groups and try logging into that user and see
Ned Deily added the comment:
The fact that ls shows a UID of 501 instead of your user name Charlotte
strongly suggests you have an inconstantly defined user account. Suggest you
try cresting a new Administrator user via System Preferences - User
Groups and try logging into that user and see
Changes by Ned Deily n...@acm.org:
--
Removed message: http://bugs.python.org/msg212953
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20873
___
Ned Deily added the comment:
er, inconstantly - inconsistently
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20873
___
___
Python-bugs-list
Matheus Vieira Portela added the comment:
As far as I noticed, in bdist_rpm.py, the _make_spec_file() method generates an
.spec file for RPM build and attaches the install script to setup.py install
-O1 --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES.
Later, the .spec refers to the record
analyst added the comment:
Hi,
I am new to Python Development. I would like to propose a patch for this
issue.
--
keywords: +patch
nosy: +analyst
Added file: http://bugs.python.org/file34309/7262.patch
___
Python tracker rep...@bugs.python.org
84 matches
Mail list logo