[Python-Dev] test_struct failure on 64 bit platforms

Neal Norwitz nnorwitz at gmail.com
Thu Jun 1 07:11:58 CEST 2006


On 5/31/06, Tim Peters <tim.peters at gmail.com> wrote:
>
> "standard" is a technical word with precise meaning here, and is
> defined by the struct module docs, in contrast to "native".  It means
> whatever they say it means :-)  "Portable" may have been a more
> intuitive word than "standard" here -- read "standard" in the struct
> context in the sense of "standardized, regardless of native platform
> size or alignment or endian quirks".

:-)

> > Would someone augment the warnings module to make testing
> > more reasonable?
>
> What's required?  I know of two things:
>
> 1. There's no advertised way to save+restore the internal
>    filter list, or to remove a filter entry, so tests that want
>    to make a temporary change have to break into the internals.
>
> 2. There's no advertised way to disable "only gripe once per source
>    line" behavior.  This gets in the way of testing that warnings get
>    raised when running tests more than once, or using a common
>    function to raise warnings from multiple call sites.
>
> These get in the way of Zope and ZODB testing too, BTW.
> Unfortunately, looks like the new test_struct code bumped into both of
> them at once.

Right.  The 2 you list above are the only one's I know of.

You fixed one of them.  I find the __warningregistry__ fix extremely
obscure.  I remember working on wrt test_warnings (and -R maybe?).  I
don't think I fixed, someone else eventually figured it out, probably
you. :-)

n


More information about the Python-Dev mailing list