[Python-Dev] Re: Have virtual environments led to neglect of the actual environment?

2021-02-24 Thread Christian Heimes
On 24/02/2021 15.16, Random832 wrote: > On Wed, Feb 24, 2021, at 06:27, Christian Heimes wrote: >> Separate directories don't prevent clashes and system breakage. But they >> provide an easy way to *recover* from a broken system. > > I think it could be turned into

[Python-Dev] Re: Have virtual environments led to neglect of the actual environment?

2021-02-24 Thread Christian Heimes
On 24/02/2021 19.17, Steve Dower wrote: > On 2/24/2021 4:26 PM, Christian Heimes wrote: >> On 24/02/2021 15.16, Random832 wrote: >>> On Wed, Feb 24, 2021, at 06:27, Christian Heimes wrote: >>>> Separate directories don't prevent clashes and system breakage. But

[Python-Dev] Re: Have virtual environments led to neglect of the actual environment?

2021-02-24 Thread Christian Heimes
On 24/02/2021 20.03, Christian Heimes wrote: > On 24/02/2021 19.17, Steve Dower wrote: >> On 2/24/2021 4:26 PM, Christian Heimes wrote: >>> On 24/02/2021 15.16, Random832 wrote: >>>> On Wed, Feb 24, 2021, at 06:27, Christian Heimes wrote: >>>>> Separate

[Python-Dev] Re: Need help to fix known Python security vulnerabilities

2021-03-09 Thread Christian Heimes
on the matter. My days of XML processing are long gone. Fixing it for "fame and glory" doesn't motivate me either. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@py

[Python-Dev] Re: Steering Council update for February

2021-03-09 Thread Christian Heimes
inology, https://github.com/bitkeeper-scm/bitkeeper/blob/master/doc/HOWTO.ask#L232 > We are then going to modify the file on both > the master and slave repository and then merge the work. For the sake > of simplicity, we are doing work in the master repository. Christian

[Python-Dev] Re: Steering Council update for February

2021-03-10 Thread Christian Heimes
On 10/03/2021 10.30, Antoine Pitrou wrote: > On Wed, 10 Mar 2021 10:30:43 +0900 > Inada Naoki wrote: >> On Wed, Mar 10, 2021 at 10:10 AM Ivan Pozdeev via Python-Dev >> wrote: >>> >>> On 10.03.2021 3:53, Chris Angelico wrote: On Wed, Mar 10, 2021 at 11:47 AM Damian Shaw wrote: >

[Python-Dev] Re: Steering Council update for February

2021-03-10 Thread Christian Heimes
On 11/03/2021 00.38, Mike Miller wrote: > > On 2021-03-10 13:45, David Mertz wrote: >> In contrast, the "master" used in version control directly borrows >> from so-called "master/slave network architecture." > > > It was shown upthread that this isn't the case.  Do you have more > accurate docu

[Python-Dev] Re: How about using modern C++ in development of CPython ?

2021-03-25 Thread Christian Heimes
e this: void Py_auto_decref(PyObject **o) { if (!o || !*o) return; Py_DECREF(*o); *o = NULL; } PyObject * func(PyObject self) { PyObject *spam __attribute__((cleanup(Py_auto_decref))); ... Py_RETURN_NONE; // spam gets automatically decrefed } It's too bad that the featu

[Python-Dev] OpenSSL 1.1.1k CVE fixes

2021-03-25 Thread Christian Heimes
lder clients and servers. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/

[Python-Dev] Re: SC feedback: PEP 648 -- Extensible customizations of the interpreter at startup

2021-03-30 Thread Christian Heimes
hon. In particular I don't think that -S (no site module) is the right way to disable __sitecustomize__. It disables too much useful features. It might be a good idea to disable __sitecustomize__ with -I (isolated mode). There should be a new au

[Python-Dev] Re: How about using modern C++ in development of CPython ?

2021-04-16 Thread Christian Heimes
$ time make -j10 ... real0m2,072s user0m4,715s sys 0m2,333s ./configure -C and ccache are fantastic. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mai

[Python-Dev] Re: How about using modern C++ in development of CPython ?

2021-04-16 Thread Christian Heimes
tdlib than C, too. In my personal opinion C++ won't give us any net benefits. I'd much rather go for Rust than C++ to gain memory safety. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to

[Python-Dev] Re: PEP 644 Accepted -- Require OpenSSL 1.1.1 or newer

2021-04-17 Thread Christian Heimes
On 30/03/2021 13.46, Pablo Galindo Salgado wrote: > Hi Christian, > > Thank you for submitting PEP 644 (Require OpenSSL 1.1.1). After evaluating > the situation and discussing the PEP, the Steering Council is happy with > the PEP, > and hereby accepts it. The SC is of the opinio

[Python-Dev] Re: March Steering Council update.

2021-05-18 Thread Christian Heimes
ed users of Python. I have contacted the SC in the beginning of this year and asked them to work with Debian maintainers. Some issues have been addressed and will be available in future releases. Matthias' talk at the language summit is related to the effort of improving Debian packa

[Python-Dev] Re: [python-committers] IMPORTANT: Python 3.10b2 release blockers

2021-05-25 Thread Christian Heimes
f Bus Error in hashlib test: test_gil The problem is already fixed. I forgot to close the release blocker bug after Greg and I took care of https://bugs.python.org/issue36515. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe sen

[Python-Dev] Re: Why list.sort() uses mergesort and not timsort?

2021-06-06 Thread Christian Heimes
or Python about twenty years ago. Tim a first generation Python core dev. Other languages like Java adopted timsort from Python later. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.

[Python-Dev] Re: Worried about Python release schedule and lack of stable C-API

2021-09-26 Thread Christian Heimes
ython. Stable releases of Cython do not support stable ABI yet. It's an experimental feature in Cython 3.0.0 alpha. Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python

[Python-Dev] Re: Worried about Python release schedule and lack of stable C-API

2021-09-29 Thread Christian Heimes
On 27/09/2021 16.32, Ronald Oussoren via Python-Dev wrote: On 26 Sep 2021, at 19:03, Christian Heimes <mailto:christ...@python.org>> wrote: On 26/09/2021 13.07, jack.jan...@cwi.nl <mailto:jack.jan...@cwi.nl> wrote: The problem with the stable ABI is that very few developers ar

[Python-Dev] Re: python3.10 compilation on OpenBSD: running into ssl issues

2021-10-05 Thread Christian Heimes
atest OpenSSL 1.1.1 version. Regards, Christian ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at

[Python-Dev] Re: python3.10 compilation on OpenBSD: running into ssl issues

2021-10-06 Thread Christian Heimes
out the right environment variables to add correct rpath yourself. I'm sorry for the inconvenience. We don't have any CI for OpenBSD. Apparently this feature was never tested on OpenBSD during the release candidate phase either. Christian ___ Pyth

[Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-19 Thread Christian Heimes
gards, Christian Extract from the documentation: Synopsis The results of an attack on a vulnerable XML library can be fairly dramatic. With just a few hundred Bytes of XML data an attacker can occupy several Gigabytes of memory within seconds. An attacker can also keep CPUs busy for a

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
Am 20.02.2013 17:25, schrieb Benjamin Peterson: > Are these going to become patches for Python, too? I'm working on it. The patches need to be discussed as they break backward compatibility and AFAIK XML standards, too. ___ Python-Dev mailing list Pyth

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
Am 20.02.2013 21:17, schrieb Maciej Fijalkowski: > On Wed, Feb 20, 2013 at 8:24 PM, Christian Heimes > wrote: >> Am 20.02.2013 17:25, schrieb Benjamin Peterson: >>> Are these going to become patches for Python, too? >> >> I'm working on it. The patc

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
essly lumped the potential XML > vulnerabilities together under the "DoS" label, and were quickly corrected. Right, I tried to address both kinds of issues in the title: XML DoS vulnerabilities and (other XML) exploits Christian __

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
uired for XPath() and IIRC for features like XSL, too. Nowadays most XML parsers and libraries have options to disable certain features. Python's standard library doesn't have options for some features or ignores other settings silently. Everything is documented at https://pypi.pyt

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
subinterpreters). try: import xml.security except ImportError: # old Python pass else: xml.security.harden_xml_parser() I guess most programs either process untrusted XML input or large XML documents that require expansion and DTD validation. Christian

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-20 Thread Christian Heimes
Am 21.02.2013 00:08, schrieb Antoine Pitrou: > Not everyone is a security nuts. But, but, but ... it's fun to be paranoid! You get so many new potential enemies. :) Jerry Fletcher ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-21 Thread Christian Heimes
Am 21.02.2013 10:23, schrieb Antoine Pitrou: > If you like being paranoid, there are other things than security to > be paranoid about: reference cycles, performance on micro-benchmarks, > memory consumption of docstrings, etc. :-) snappy(__doc__)? http://code.google.com/p/snappy/

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-21 Thread Christian Heimes
Am 21.02.2013 08:42, schrieb Antoine Pitrou: > Sure, but in many instances, rebooting a machine is not > business-threatening. You will have a couple of minutes' downtime and > that's all. Which is why the attack must be repeated many times to be a > major annoyance. Is this business-threatening e

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-21 Thread Christian Heimes
cols" (http://www.skip-vpn.org/spec/numbers.html). See there for how they were generated. Note that g is not a generator, but this is not a problem since p is a safe prime. Q.E.D. Christian ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-21 Thread Christian Heimes
for 'Antoine Pitrou' but for 'antipole'. I'm a bit paranoid and overcautious. Antoine acts as my antipole and counter balance. Together we make a fairly good team. :) Christian ___ Python-Dev mailing list Python-Dev@python.org

Re: [Python-Dev] XML DoS vulnerabilities and exploits in Python

2013-02-21 Thread Christian Heimes
Am 21.02.2013 19:39, schrieb Eli Bendersky: > Just to clarify for my own curiosity. These attacks (e.g. > http://en.wikipedia.org/wiki/Billion_laughs) have been known and public > since 2003? Correct, see https://pypi.python.org/pypi/defusedxml#synopsis third paragraph. All XML attacks in my analy

Re: [Python-Dev] xml.sax and xml.dom fetch DTDs by default

2013-02-21 Thread Christian Heimes
o. https://pypi.python.org/pypi/defusedxml#python-xml-libraries Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Slides from today's parallel/async Python talk

2013-03-14 Thread Christian Heimes
oing to be more important than x86 in the future. We are going to see more ARM based servers. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/o

[Python-Dev] Status of XML fixes

2013-03-17 Thread Christian Heimes
any C extension. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Status of XML fixes

2013-03-18 Thread Christian Heimes
y API. https://bitbucket.org/tiran/xmlbomb/commits/c033abd0f7747c5b215e1b32f90372dd96e397ba I have to port tests from my other branch and add tests for the new API, too. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listin

Re: [Python-Dev] Status of XML fixes

2013-03-18 Thread Christian Heimes
Am 17.03.2013 19:59, schrieb Antoine Pitrou: >> Why keep the libraries vulnerable for another year (3.4 final is expected >> for early 2014), if there is something we can do about them now? > > Well, Christian said that his stdlib patch wasn't ready yet. The patch is >

Re: [Python-Dev] Slides from today's parallel/async Python talk

2013-03-18 Thread Christian Tismer
will pique the interest of commercial entities out there that have problems perfectly suited to where this pattern excels (shared-nothing, highly concurrent), much like the relationship that developed between Stackless and Eve Online. What do you think: does it make sense to think of

Re: [Python-Dev] cpython (2.7): Issue 17538: Document XML vulnerabilties

2013-03-26 Thread Christian Heimes
there for how they were generated. Note that g is not a generator, but this is not a problem since p is a safe prime. Q.E.D. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Safely importing zip files with C extensions

2013-03-28 Thread Christian Heimes
Am 28.03.2013 17:09, schrieb Brett Cannon: > Which must be done carefully to prevent a security issue. It shouldn't > be unzipped anywhere but into a directory only writable by the process. Cleanup is going to be tricky or even impossible. Windows locks loaded DLLs and therefore prevents their re

Re: [Python-Dev] The end of 2.7

2013-04-06 Thread Christian Heimes
y > to maintain the 2.7 branch with fixes ported from 3.x. At that point, > we will have to decide how to treat releases from this "backports" branch. Five years official releases sounds fine to me, too. Martin, how long are you going to build official Windows binaries for Pytho

Re: [Python-Dev] The end of 2.7

2013-04-07 Thread Christian Tismer
ming that loudly enough, it will eventually happen! cheers - chris -- Christian Tismer :^) <mailto:tis...@stackless.com> Software Consulting : Have a break! Take a ride on Python's Karl-Liebknecht-Str. 121 :*Starship* http://starship.python.net/ 14482

Re: [Python-Dev] The end of 2.7

2013-04-07 Thread Christian Tismer
your projects, the movement becomes a reality. Just say that we all need to move on and cannot care about companies that ignore this necessity. I agree it is hard to push things forward, when certain tools are just supporting 2.x. My way to get over this is ranting, and porting some things, and

Re: [Python-Dev] casefolding in pathlib (PEP 428)

2013-04-12 Thread Christian Heimes
> > Isn't unicode fun :-) Seriously, the OSX kernel normalizes unicode forms? It's a cool feature and makes sense for the user's POV but ... WTF? Perhaps we should use the platform's API for the job. Does OSX offer an API function to create a case folded and canonical form of a pat

[Python-Dev] Multiline Strings confusion it tutorial

2013-04-12 Thread Christian Tismer
don't think the given example is very helpful, but adds confusion. Where would I add such a complaint, usually? Or should I simply fix it? cheers - chris -- Christian Tismer :^) <mailto:tis...@stackless.com> Software Consulting : Have a break! Take a ride on Py

Re: [Python-Dev] PEP 428: stat caching undesirable?

2013-05-01 Thread Christian Heimes
atic caching of stat() results. We can get a greater speed up for walkdir() without resorting to caching, too. Some operating systems and file system report the file type in the dirent struct that is returned by readdir(). This reduces the number of stat calls to zero. Christian [1] https://www.s

Re: [Python-Dev] Issue 11406: adding os.scandir(), a directory iterator returning stat-like info

2013-05-10 Thread Christian Heimes
operating systems provides a full stat result as returned by os.stat(). Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Issue 11406: adding os.scandir(), a directory iterator returning stat-like info

2013-05-10 Thread Christian Heimes
device. I don't really see how to map strut dirent to struct stat on POSIX. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Issue 11406: adding os.scandir(), a directory iterator returning stat-like info

2013-05-11 Thread Christian Heimes
platforms, > cached_stat would initially be None, and you would have to call stat() > to populate it. +1 > If we find other details that we can reliably provide cross-platform > from the dir information, then we can add more query methods orst > attribute

Re: [Python-Dev] Issue 11406: adding os.scandir(), a directory iterator returning stat-like info

2013-05-12 Thread Christian Heimes
else: > return stat.S_ISLNK(self.lstat().st_mode) A bit faster: d_type = getattr(self.dirent, "d_type", DT_UNKNOWN) if d_type != DT_UNKNOWN: return d_type == DT_LNK The code doesn't handle a failing lstat() call. Christian _

Re: [Python-Dev] Issue 11406: adding os.scandir(), a directory iterator returning stat-like info

2013-05-13 Thread Christian Heimes
kes sense. I'm glad to be of assistance! The feature is new (added in 3.3) and is available on most POSIX platforms. http://docs.python.org/3/library/os.html#dir-fd If you need any help or testing please feel free to ask me. I really like to get this feature into 3.4. Christian _

Re: [Python-Dev] More compact dictionaries with faster iteration

2013-05-15 Thread Christian Tismer
n ratios stay true provided you don't overallocate entry list. If you do overallocate you don't really gain that much (it all depends vastly on details), or even loose in some cases. What do you think should the strategy be? What is the current status of this discussion? I'd like t

Re: [Python-Dev] More compact dictionaries with faster iteration

2013-05-15 Thread Christian Tismer
On 15.05.13 14:01, Stefan Drees wrote: Hi Chris, On 15.05.13 13:32 Christian Tismer wrote: Hi Raymond, On 08.01.13 15:49, Maciej Fijalkowski wrote: On Mon, Dec 10, 2012 at 3:44 AM, Raymond Hettinger wrote: The current memory layout for dictionaries is unnecessarily inefficient. It has a

Re: [Python-Dev] Mysterious Python pyc file corruption problems

2013-05-16 Thread Christian Heimes
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Am 16.05.2013 17:40, schrieb Barry Warsaw: > We've since found a few cases where Python 3.3 pyc files are > probably corrupted, so that shoots down my theory about a race > condition on reading/writing pyc files, since 3.3 implements > atomic-rename

Re: [Python-Dev] Validating SSL By Default (aka Including a Cert Bundle in CPython)

2013-06-03 Thread Christian Heimes
is far from trivial. I had a look at it once. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Validating SSL By Default (aka Including a Cert Bundle in CPython)

2013-06-03 Thread Christian Heimes
Under which conditions do we need to ship a CA cert file? Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

[Python-Dev] ssl improvements and testing question

2013-06-06 Thread Christian Heimes
sion of OpenSSL Python 3.4 is going to support? Do we have an easy way to compile and link Python against a custom installation of OpenSSL or do I have to fiddle around with CPPFLAGS and CFLAGS? Christian [1] https://pypi.python.org/pypi/wincertstore ___

Re: [Python-Dev] cpython: fixd refleak

2013-06-13 Thread Christian Heimes
Am 13.06.2013 20:59, schrieb Antoine Pitrou: > How about > > return Py_BuildValue("", ofile_env, ofile, odir_env, odir); > > ? Oh right, I forgot about 'N'. The PyArg_Parse*() methods don't have it. Do you want me to modify the

Re: [Python-Dev] cpython: Issue #3329: Add new APIs to customize memory allocators

2013-06-15 Thread Christian Heimes
platforms the raw memory allocators should be thin wrappers around malloc(), realloc() and free() -- or perhaps just macros. Eventually I would like to ban direct usage of malloc() from Python's core and patch all memory management through our API. Christian _

Re: [Python-Dev] cpython: Issue #3329: Add new APIs to customize memory allocators

2013-06-15 Thread Christian Heimes
//hg.python.org/cpython/file/cc27d50bd91a/Modules/expat/xmlparse.c#l717 libtiff has three global hooks _TIFFmalloc(), _TIFFrealloc() and _TIFFfree() that are used instead of malloc() in its core. http://trac.imagemagick.org/browser/tiff/trunk/libtiff/tif_unix.c#L258 libxml2 has http://

Re: [Python-Dev] cpython (3.3): ctypes: AIX needs an explicit #include to get alloca()

2013-06-18 Thread Christian Heimes
>> >> #include >> #include "ctypes.h" >> +#include > > This header is not present on Windows, thus breaking all the Windows > buildbots. Perhaps it should be wrapped in an AIX-specific #ifdef? I have added HAVE_ALLOCA_

Re: [Python-Dev] cpython (3.3): ctypes: AIX needs an explicit #include to get alloca()

2013-06-18 Thread Christian Heimes
Am 18.06.2013 13:32, schrieb Victor Stinner: > 2013/6/18 Christian Heimes : >> Am 18.06.2013 12:56, schrieb Jeremy Kloth: >>> On Mon, Jun 17, 2013 at 2:02 PM, victor.stinner >>>> +#include >>> >>> This header is not present on Windows, thus bre

[Python-Dev] stat module in C -- what to do with stat.py?

2013-06-20 Thread Christian Heimes
might still be useful to alternative implementations of Python such as Jython or PyPy. 1) keep the file stat.py but let it be shadowed by the builtin stat module. Antoine loathes my hack... 2) rename stat.py to _stat.py 3) remove stat.py Opinions? Christian [1] http://b

Re: [Python-Dev] stat module in C -- what to do with stat.py?

2013-06-20 Thread Christian Heimes
Am 20.06.2013 15:21, schrieb Florent: > we already have "_pyio.py", we could have "_pystat.py". Works for me. ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailm

Re: [Python-Dev] stat module in C -- what to do with stat.py?

2013-06-20 Thread Christian Heimes
o *something* special to use it anyway. >> >> That's exactly my rationale for pushing for removal. > > +1 to nixing it. I'm +0 for removal. The stat module contains merely constants, wrappers for macros and one simple functions. Somebody just say the word. Christia

Re: [Python-Dev] stat module in C -- what to do with stat.py?

2013-06-21 Thread Christian Heimes
F*, too. (But I don't know any platform that implements them as files, though). http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_stat.h.html#tag_13_61_06 Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.o

Re: [Python-Dev] stat module in C -- what to do with stat.py?

2013-06-21 Thread Christian Heimes
tch adds extensive tests for all features of the stat module. The test check the existence of attributes and the return value of all functions. A missing or ill-defined attribute is going to raise an error. But see for yourself: http://hg.python.org/cpython/rev/f8ff6

Re: [Python-Dev] cpython: Fix memory leak in pyexpat PyUnknownEncodingHandler

2013-06-29 Thread Christian Heimes
Am 29.06.2013 21:29, schrieb R. David Murray: > I don't know if this is the commit at fault or not, but we are seeing > segfaults in test_xml_etree on the buildbots now. Yeah, it's my fault. Thanks! >> u = PyUnicode_Decode((char*) template_buffer, 256, name, "replace"); >> -if (u == NULL

Re: [Python-Dev] lament for the demise of unbound methods

2013-07-04 Thread Christian Heimes
Am 04.07.2013 13:21, schrieb Chris Withers: > There doesn't appear to be any way in Python 3 to do this, which is a > little surprising and frustrating... > > What am I missing here? I removed unbound methods almost six years ago: http://hg.python.org/cpython/rev/48af63

[Python-Dev] Python 3.4 and Windows XP: just 45 days until EOL

2013-07-11 Thread Christian Heimes
to restrict ourselves to an API that is going to become deprecated 45 days after the estimated release of 3.4.0? Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http

Re: [Python-Dev] Python 3.4 and Windows XP: just 45 days until EOL

2013-07-12 Thread Christian Heimes
go. Do people really expect that they can run the latest version of a program on a decommissioned operating system? Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.pyt

Re: [Python-Dev] cpython: Issue #18408: Fix fileio_read() on _PyBytes_Resize() failure

2013-07-16 Thread Christian Heimes
Am 17.07.2013 00:03, schrieb Victor Stinner: > 2013/7/16 Serhiy Storchaka : >>> http://hg.python.org/cpython/rev/533eb9ab895a >>> summary: >>>Issue #18408: Fix fileio_read() on _PyBytes_Resize() failure >>> >>> bytes is NULL on _PyBytes_Resize() failure >> >> Why not Py_DECREF? > > Because Py_

Re: [Python-Dev] cpython: Use strncat() instead of strcat() to silence some warnings.

2013-07-20 Thread Christian Heimes
> This will wrong when strlen(fname) is 30. strncat() will copy only 30 > bytes, without terminal NUL. That's not how strncat() works. strncat(dest, src, n) writes n+1 chars to the end of dest: n chars from src and +1 for the final NUL char. For this reason dest must be large enough to hold strlen

Re: [Python-Dev] cpython: Use strncat() instead of strcat() to silence some warnings.

2013-07-20 Thread Christian Heimes
Am 20.07.2013 14:23, schrieb Serhiy Storchaka: > This will wrong when strlen(fname) is 30. strncat() will copy only 30 > bytes, without terminal NUL. http://linux.die.net/man/3/strncat The strncat() function is similar, except that * it will use at most n bytes from src; and * src does not need

Re: [Python-Dev] cpython: Use strncat() instead of strcat() to silence some warnings.

2013-07-20 Thread Christian Heimes
Am 20.07.2013 15:56, schrieb Serhiy Storchaka: > Oh, true. strncat() always results NUL-terminated string. It's strncpy() > can produce not NUL-terminated string. Sorry for noise. You're welcome! Better safe than sorry. :) ___ Python-Dev mailing list P

Re: [Python-Dev] cpython (3.3): return NULL here

2013-07-23 Thread Christian Heimes
o() already and always returns NULL. Or do you prefer to return NULL explicitly? Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] cpython (3.3): return NULL here

2013-07-23 Thread Christian Heimes
re right. I must have missed the compiler warning. How about we turn type return and type assignment warnings into fatal errors? Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: h

Re: [Python-Dev] cpython: Add modeling file for Coverity Scan.

2013-07-23 Thread Christian Heimes
Am 23.07.2013 08:27, schrieb Antoine Pitrou: > On Tue, 23 Jul 2013 01:31:24 +0200 (CEST) > christian.heimes wrote: >> + >> +typedef int sdigit; >> +typedef long Py_ssize_t; > > Can't you write "typedef ssize_t Py_ssize_t" instead? No, but it really doesn't matter. Coverity just needs a similar t

Re: [Python-Dev] Official github mirror for CPython?

2013-07-25 Thread Christian Heimes
https://github.com/python-mirror/python doesn't appear to be very > popular but is updated daily > > Are some of you the owners of these repositories? Should we consolidate > to a single "semi-official" mirror? +1 Does the PSF have an official acco

Re: [Python-Dev] Official github mirror for CPython?

2013-07-25 Thread Christian Heimes
Am 25.07.2013 16:48, schrieb Brian Curtin: > On Thu, Jul 25, 2013 at 9:37 AM, Christian Heimes > wrote: >> Am 25.07.2013 16:29, schrieb Eli Bendersky: >>> Hi all, >>> >>> I've been looking for a Github mirror for Python, and found two: >>> &g

[Python-Dev] Coverity Scan

2013-07-25 Thread Christian Heimes
.org/issue18556 http://bugs.python.org/issue18555 http://bugs.python.org/issue18552 http://bugs.python.org/issue18551 http://bugs.python.org/issue18550 http://bugs.python.org/issue18528 Christian ___ Python-Dev mailing list Python-Dev@python.org http://mai

Re: [Python-Dev] Coverity Scan

2013-07-25 Thread Christian Heimes
the time. :) Did I mention that we have almost reached Level 3? All major defects have been dealt with (one of them locally on the test machine until Larry pushes his patch soonish), 4 of 7 minor issues must be closed and our dismissed rate is just little over 20% (222 out of 1054 = 21%). Chr

Re: [Python-Dev] Coverity Scan

2013-07-25 Thread Christian Heimes
Am 26.07.2013 00:50, schrieb Antoine Pitrou: > "Excellence"? The term is too weak, I would say "perfection" at least, > but perhaps we should go as far as "divinity". Don't forget that Python can offer lots of places to keep your bike clean and dry ... *scnr* __

Re: [Python-Dev] Coverity Scan

2013-07-25 Thread Christian Heimes
in the process of looking through all dismissed defects. Some of them are relics of deleted files and removed code. Some other may go away with proper modeling. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] Coverity Scan

2013-07-26 Thread Christian Heimes
For example: PyObject *n = PyLong_FromLong(0); PyObject *u = PyUnicode_FromString("example"); if (u == NULL) { return NULL; /* Coverity detects that 'n' leaks memory */ } Christian ___ Python-Dev mailing list Python-Dev@python.org http:

Re: [Python-Dev] Coverity Scan

2013-07-26 Thread Christian Heimes
out one model for a false positive on my own. Dakshesh is helping me with another. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/pyth

[Python-Dev] C code coverage report with lcov

2013-07-29 Thread Christian Heimes
bugs.python.org/issue18481 Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] C code coverage report with lcov

2013-07-29 Thread Christian Heimes
branch and line misses. I'm not sure what we can do about that. I don't want to plaster the code with LCOV_EXCL_LINE comments. As first action we should look into function coverage. We may not be able to execute every branch but at least we should be able to call and

Re: [Python-Dev] C code coverage report with lcov

2013-07-29 Thread Christian Heimes
a little bit more readable. Christian ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Re: [Python-Dev] C code coverage report with lcov

2013-07-30 Thread Christian Heimes
Am 29.07.2013 19:15, schrieb Christian Heimes: > Hi, > > I have done some experiments with GCC's gcov and lcov to get the C code > coverage of our unit test suite. You may find today's report at > > http://tiran.bitbucket.org/python-lcov/ > > I'm working

Re: [Python-Dev] C code coverage report with lcov

2013-07-30 Thread Christian Heimes
C and its gcov extension -- so much for Windows. I also don't know if gcov supports cross-profiling on varying platforms and operating systems. By the way gcov understands preprocessor output. It doesn't report lines as uncovered when the lines or functions are #

Re: [Python-Dev] [Python-checkins] cpython (merge 3.3 -> default): Silence warning about set but unused variable inside compile_atom() in

2013-08-01 Thread Christian Heimes
Am 01.08.2013 09:03, schrieb Ronald Oussoren: > > On 31 Jul, 2013, at 23:50, christian.heimes > wrote: > >> http://hg.python.org/cpython/rev/0e09588a3bc2 >> changeset: 84939:0e09588a3bc2 >> parent: 84937:809a64ecd5f1 >> parent: 84938:83a55ca93

[Python-Dev] SSL issues in Python stdlib and 3rd party code

2013-08-12 Thread Christian Heimes
p11-glue.freedesktop.org/doc/storing-trust-policy/storing-trust-existing.html I like to thank Ryan Sleevi (Google), Chris Palmer (Google), Marc-Andre Lemburg (eGenix.com, Python core dev), Jean-Paul Calderone (PyOpenSSL), Antoine Pitrou (Python core dev), Daniel Stenberg (curl), Günter Knauf (curl

Re: [Python-Dev] SSL issues in Python stdlib and 3rd party code

2013-08-13 Thread Christian Heimes
have copied our code (bzr, tornado, pip, setuptools): http://bugs.python.org/issue17997 https://bugs.mageia.org/show_bug.cgi?id=10391 https://bugzilla.redhat.com/show_bug.cgi?id=963260#c11 Christian -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with

[Python-Dev] PEP 452 API for Cryptographic Hash Functions v2.0

2013-08-15 Thread Christian Heimes
tract base class for cryptographic hashing algorithm [1]. Should I add it to the PEP and make it mandatory for Python 3.4+? Regards, Christian [1] http://bugs.python.org/issue18742 PEP: 452 Title: API for Cryptographic Hash Functions v2.0 Version: $Revision$ Last-Modified: $Date$ Author: A.M. Kuc

[Python-Dev] Coverity Scan Spotlight Python

2013-08-29 Thread Christian Heimes
Thank you very much to Kristin Brennan and Dakshesh Vyas from Coverity as well as everybody who has helped to fix the remaining issues! Christian -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with undefined - http://w

Re: [Python-Dev] Coverity Scan Spotlight Python

2013-08-29 Thread Christian Heimes
-BEGIN PGP SIGNED MESSAGE- Hash: SHA512 Am 30.08.2013 00:46, schrieb Antoine Pitrou: > On Fri, 30 Aug 2013 00:10:27 +0200 Christian Heimes > wrote: >> -BEGIN PGP SIGNED MESSAGE- Hash: SHA512 >> >> Hello, >> >> Coverity has published it

Re: [Python-Dev] Add function to signal module for getting main thread id

2013-08-30 Thread Christian Heimes
another thread than the main thread? AFAIR the other threads are suspended and the forking thread is the new main thread. Or something similar... (Yes, I'm aware that threading + fork is an abomination.) Christian ___ Python-Dev mailing lis

Re: [Python-Dev] Coverity Scan Spotlight Python

2013-08-30 Thread Christian Heimes
way, which looks suspicious to Coverity Scan. I have documented the most common limitations in the devguide [1]. By the way Coverity Scan doesn't understand Python code. It can only analyzes C, C++ and Java code. [1] Christian -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.12 (GNU/Linu

Re: [Python-Dev] peps: document requirements

2013-09-30 Thread Christian Heimes
since this slightly obfuscates the hash secret It's not a hard requirement, hence 'should' instead of 'must' like in all other cases. Christian ___ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/l

<    1   2   3   4   5   6   7   8   9   10   >