paul j3 added the comment:
`parse_args` just calls `parse_known_args`, and then raises an error if `rest`
is not empty. So it is `parse_known_args` that is doing the abbreviation
matching.
Abbreviation matching is done relatively early, when `_parse_known_args` first
loops through the
Nick Coghlan added the comment:
The specific proposal was to use __spec__.name when __name__ == __main__
to avoid the pickle compatibility issues described in PEP 395 when using
the -m switch.
runpy has to be updated first, though.
--
___
Python
Dima Tisnek added the comment:
re: cert_paths = [...]
This approach is rather problematic, there's no guarantee that a path trusted
on one system is trusted on another.
I saw this in setuptools branch, where it does:
for path in cert_path:
if os.path.exists(path)
return path
Changes by STINNER Victor victor.stin...@gmail.com:
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15495
___
___
Python-bugs-list
Christian Heimes added the comment:
All these paths are on directories that are supposed to be read-only for
untrusted users. You can't protect yourself against a malicious admin anyway.
For Python 3.4 the ssl module uses the cert path that are configured with
OpenSSL. The paths and
Eli Bendersky added the comment:
I don't see how these implementation details are relevant. The patch adds a
link to the existing abbreviations section, which mentions parse_args - so it's
clear that this behavior exists in both.
Yes, #14910 (to which I pointed in the original message in this
New submission from anatoly techtonik:
https://bitbucket.org/rirror/peps
PEP repository readme lacks information about how to send Python Enhancement
Proposal step-by-step.
1. hg clone https://bitbucket.org/rirror/peps
2. cd peps
3. # choose number
4. cp ??? pep-{{number}}.txt
5. # commit
6.
New submission from cost6:
for-each does not iterate over all entries of collection, if one removes
elements during the iteration.
Example (misbehaving) code:
def keepByValue(self, key=None, value=[]):
for row in self.flows:
if not row[key] in value:
flows.remove(row)
Christian Heimes added the comment:
The process is well explained in the PEP templates right at the top of the PEP
list:
http://www.python.org/dev/peps/pep-0009/
http://www.python.org/dev/peps/pep-0012/
New PEP authors should get in touch with experienced core developers or mentors
in order
STINNER Victor added the comment:
PEP process entrypoint
Do you work with developers of the distutils-* objects? It looks like Daniel
Holth works on such PEP for example:
https://mail.python.org/pipermail/distutils-sig/2013-July/021854.html
You may join this mailing list:
Roundup Robot added the comment:
New changeset 395a266bcb5a by Eli Bendersky in branch '2.7':
Issue #19815: Fix segfault when parsing empty namespace declaration.
http://hg.python.org/cpython/rev/395a266bcb5a
--
nosy: +python-dev
___
Python tracker
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
components: +Unicode
nosy: +ezio.melotti
stage: needs patch - committed/rejected
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19819
___
anatoly techtonik added the comment:
The entrypoint here means the point of entry for new Python Enhancement
Proposals. Christian, what you propose is a 4th order link for someone who
knows what PEPs are, and clones PEP repository to submit own proposal.
What I propose it to make PEP
Marc-Andre Lemburg added the comment:
Anatoly, please read http://www.python.org/dev/peps/pep-0012/
The process you are describing is not correct. In particular, the discussion
happens before sending in a pull request.
As for discussion of the PEP process: that should happen on python-dev,
Antoine Pitrou added the comment:
Calling it _PyThread_set_key_value is prone to confusion.
Ideally we would fix PyThread_set_key_value's behaviour. Are there users of the
function outside from CPython?
--
___
Python tracker rep...@bugs.python.org
Roundup Robot added the comment:
New changeset 68f1e5262a7a by Eli Bendersky in branch '3.3':
Issue #19815: Fix segfault when parsing empty namespace declaration.
http://hg.python.org/cpython/rev/68f1e5262a7a
New changeset 2b2925c08a6c by Eli Bendersky in branch 'default':
Issue #19815: Fix
Eli Bendersky added the comment:
Thanks for the report patches. Fixed in all active branches.
--
resolution: - fixed
stage: needs patch - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
Antoine Pitrou added the comment:
An option is to rename the C errno module to _errno and leave it
unchanged, and provide a Python errno module which enum API.
I agree it sounds reasonable.
Using enum for errno should not slow down Python startup time.
enum imports OrderedDict from
Antoine Pitrou added the comment:
Note that even if errno is migrated to enum, OSErrors raised by the interpreter
will still have a raw int errno...
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19624
Eli Bendersky added the comment:
If I don't see any further objections I'll go ahead and commit this by the end
of the week
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19814
___
anatoly techtonik added the comment:
The process you are describing is not correct. In particular, the discussion
happens before sending in a pull request.
Post the link to correct process into README.rst and then this issue can be
closed.
As for python-dev, I thought it is too obvious and
Marc-Andre Lemburg added the comment:
I'm not sure whether changing the errno module to use enums would be
conceptually correct:
enums declare a fixed set of permitted values, but errno values can be any
integer, are platform dependent and are sometimes not unique (e.g. EWOULDBLOCK
= EAGAIN,
Christian Heimes added the comment:
The ticket has been closed by two people. Why do you keep re-opening the ticket?
--
resolution: - invalid
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19822
Eli Bendersky added the comment:
Committed in 90b56ec318b6
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
versions: +Python 3.2 -Python 3.4, Python 3.5
___
Python tracker rep...@bugs.python.org
Matthew Barnett added the comment:
This issue is best posted to python-list and only posted here if it's agreed
that it's a bug.
Anyway:
1. You have self.flows and flows, but haven't said what they are.
2. It's recommended that you don't modify a collection while iterating over it,
but,
cost6 added the comment:
Sorry for that, i will move it to python-list.
--
resolution: - works for me
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19823
___
Marc-Andre Lemburg added the comment:
On 28.11.2013 15:45, anatoly techtonik wrote:
anatoly techtonik added the comment:
The process you are describing is not correct. In particular, the discussion
happens before sending in a pull request.
Post the link to correct process into
Christian Heimes added the comment:
My patch could be much simpler and easier if we could just drop support for
ancient versions of OpenSSL. My idea requires at least OpenSSL 0.9.8f (release
2007) with SNI support. Six years are a lot for crypto software. All relevant
platforms with vendor
Antoine Pitrou added the comment:
My patch could be much simpler and easier if we could just drop
support for ancient versions of OpenSSL. My idea requires at least
OpenSSL 0.9.8f (release 2007) with SNI support.
What are you talking about? Your patch doesn't use HAS_SNI.
--
STINNER Victor added the comment:
2013/11/28 Antoine Pitrou rep...@bugs.python.org:
Calling it _PyThread_set_key_value is prone to confusion.
Ideally we would fix PyThread_set_key_value's behaviour. Are there users of
the function outside from CPython?
PyThread_set_key_value() is defined
STINNER Victor added the comment:
I read again the following blog post:
http://blogs.msdn.com/b/oldnewthing/archive/2011/12/16/10248328.aspx
I understood the purpose of PROC_THREAD_ATTRIBUTE_HANDLE_LIST.
Let say that two Python threads create a Popen object with a pipe for stdout:
* Thread A
Charles-François Natali added the comment:
Antoine Pitrou added the comment:
Calling it _PyThread_set_key_value is prone to confusion.
Ideally we would fix PyThread_set_key_value's behaviour. Are there users of
the function outside from CPython?
The question is why does it behave this way
Changes by Christian Heimes li...@cheimes.de:
Removed file: http://bugs.python.org/file32831/check_hostname.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19509
___
New submission from anatoly techtonik:
http://docs.python.org/2/library/string.html#template-strings
This class could be more useful with the following example:
from string import Template
t = Template('$who likes $what')
who = 'tim'
what = 'kung pao'
t.substitute(locals())
'tim likes
paul j3 added the comment:
For a programmer who needs to turn off this abbreviation matching now, a simple
solution is to subclass ArgumentParser:
class MyParser(ArgumentParser):
def _get_option_tuples(self, option_string):
return []
This could be the place to
anatoly techtonik added the comment:
The ticket has been closed by two people. Why do you keep re-opening the
ticket?
Because you're not providing any arguments. If it is not important for you,
just ignore. If something is not clear - ask. What you do is just closing the
stuff, because you
STINNER Victor added the comment:
The question is why does it behave this way in the first place?
Maybe for sub-interpreters?
The code is old. I don't think that it's related to subinterpreter.
PyThread_set_key_value() is used in _PyGILState_Init() and PyGILState_Ensure(),
but its behaviour
Christian Heimes added the comment:
The patches in the dependency tickets are using SNI. The problem is, a non-None
server_hostname argument raises an error when OpenSSL doesn't support the
feature.
Here is a demo patch for my idea. It makes it very easy to add hostname
matching to existing
Changes by Barry A. Warsaw ba...@python.org:
--
nosy: +barry
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19824
___
___
Python-bugs-list mailing
Barry A. Warsaw added the comment:
On Nov 28, 2013, at 05:07 PM, anatoly techtonik wrote:
This class could be more useful with the following example:
from string import Template
t = Template('$who likes $what')
who = 'tim'
what = 'kung pao'
t.substitute(locals())
'tim likes kung pao'
Antoine Pitrou added the comment:
The patches in the dependency tickets are using SNI.
They all check for HAS_SNI, which is simple enough.
If you want to discuss a minimum supported OpenSSL version, that's fine with
me, but it should be a separate discussion (on python-dev?).
If you think
STINNER Victor added the comment:
Anatoly, please stop reopening the issue, it's *really* annoying. Not
only you failed to understand correctly your problem (it looks like
nor Christian nor Marc-Andre nor me understood your request), but it
looks like you don't care of our answers.
PEP
anatoly techtonik added the comment:
There is nothing to add to the class itself. It is about expanding docs section
with helpful examples. `string.Template` is undervalued, because it is hard to
see how it can be more useful than standard string formatting functions. But
for people coming
Alex Gaynor added the comment:
Using locals() in this fashion is a serious anti-pattern, I'm -∞ on the docs
suggesting it.
--
nosy: +alex
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19824
New submission from anatoly techtonik:
--
anatoly t.
--
messages: 204688
nosy: techtonik
priority: normal
severity: normal
status: open
title: test b.p.o email interface
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19825
Changes by Giampaolo Rodola' g.rod...@gmail.com:
--
nosy: +giampaolo.rodola
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19822
___
___
anatoly techtonik added the comment:
Closing by email using [status=closed;resolution=invalid] suffix in header.
--
resolution: - invalid
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19825
Charles-François Natali added the comment:
I'm with Antoine, this is *really* going too far.
SOCK_CLOEXEC and friends are useful to avoid race conditions: there's
no such concern with the non-blocking flag.
Shaving one or two syscalls is IMO completely useless, and doesn't
justify the extra code
Kristján Valur Jónsson added the comment:
Deja vu, this has come up before. I wanted to change this because native TLS
implementation become awkward.
https://mail.python.org/pipermail/python-dev/2008-August/081847.html
--
___
Python tracker
Kristján Valur Jónsson added the comment:
See also issue #10517
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19787
___
___
Python-bugs-list
New submission from anatoly techtonik:
I found this to be convenient:
http://techtonik.rainforce.org/2013/11/roundup-tracker-create-issues-by-email.html
And this is missing from here:
http://docs.python.org/release/2.7/bugs.html#using-the-python-issue-tracker
Anf from here:
Guido van Rossum added the comment:
OK, let's forget about it.
--
resolution: - wont fix
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19813
anatoly techtonik added the comment:
@Alex, have you seen
http://pythonhosted.org/flufl.i18n/docs/using.html#substitutions-and-placeholders?
I really like the brevity, and it is the function that does the magic, so it
is fully transparent and you don't need to instantiate string.Template
Georg Brandl added the comment:
Closing for the hopefully final time. Anatoly, if you keep reopening this
ticket you have to expect removal of tracker privileges.
--
nosy: +georg.brandl
resolution: postponed - rejected
status: open - closed
___
Claudiu.Popa added the comment:
It was used by pydoc.py until 2006, when it was removed with this commit:
Changeset:
37821 (3135648026c4) Second phase of refactoring for runpy, pkgutil, pydoc, and
setuptools.
Is it worth to fix this?
--
nosy: +Claudiu.Popa
New submission from STINNER Victor:
Attached patch avoids a syscall on socket.setblocking() and socket.settimeout()
when possible: use ioctl(FIONBIO) when available (not only on VMS), or use
fcntl() but only call fcntl() twice if the flags changed.
The fcntl() optimization was suggested by
Barry A. Warsaw added the comment:
A few notes about flufl.i18n's style. We chose this (extracted from the GNU
Mailman project) because $strings are *way* less error prone for translators
than %s strings, especially when you consider that some languages change the
order of placeholders. The
STINNER Victor added the comment:
I don't see what I can do against a -10 vote! :-)
I opened the issue #19827 for the simple syscall optimization.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19813
Matthias Klose added the comment:
re-opening. the patch did break autopilot running with 2.7 on Ubuntu. I don't
yet understand what this patch is supposed to fix.
--
nosy: +doko
resolution: fixed -
status: closed - open
___
Python tracker
Matthias Klose added the comment:
see https://launchpad.net/bugs/1255505
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19352
___
___
STINNER Victor added the comment:
Attached patch fix PyThread_set_key_value() instead of adding a new function.
I prefer fix_set_key_value.patch instead of pythread_set_key_value.patch
because I feel bad of keeping a buggy function and having to decide between a
correct and a buggy version of
Kristján Valur Jónsson added the comment:
But yes, I'd like to see this behave like normal.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19787
___
Kristján Valur Jónsson added the comment:
Please see the rather long discussion in http://bugs.python.org/issue10517
There were issues having to do with fork.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19787
STINNER Victor added the comment:
Please see the rather long discussion in http://bugs.python.org/issue10517
There were issues having to do with fork.
Python has now a _PyGILState_Reinit() function.
I don't see how fix_set_key_value.patch would make the situation worse. What is
the link
Charles-François Natali added the comment:
AFAICT, there's no link (FWIW I wrote the patch for #10517, then the fix
for threads created outside of Python calling into a subinterpreter -
issue #13156).
Actually, this fix would have avoided the regression in issue #13156.
But since it's tricky,
Kristján Valur Jónsson added the comment:
Only that issue #10517 mentions reasons to keep the old behavior, specifically
http://bugs.python.org/issue10517#msg134573
I don't know if any of the old arguments are still valid, but I suggested
changing this years ago and there was always some
yinkaisheng added the comment:
After debugging, I found the reason.
when ctypes loads the dll, CoCreateInstance blocks the flow.
If I don't call CoCreateInstance in function DllMain. ctypes can load the dll.
I should call function CoCreateInstance after DllMain was called.
The problem was
Martin Pitt added the comment:
More precisely, it broke unittest's discovery (not specific to autopilot). For
any installed test, you now get:
$ python -m unittest discover lazr
Traceback (most recent call last):
File /usr/lib/python2.7/runpy.py, line 162, in _run_module_as_main
68 matches
Mail list logo