From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | Oskari Saarenmaa <os(at)ohmu(dot)fi>, Christian Ullrich <chris(at)chrullrich(dot)net>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: hstore_plpython regression test does not work on Python 3 |
Date: | 2015-05-29 03:27:56 |
Message-ID: | 14136.1432870076@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> On 5/26/15 5:19 PM, Oskari Saarenmaa wrote:
>> Looks like that animal uses Python 3.4. Python 3.3 and newer versions
>> default to using a random seed for hashing objects into dicts which
>> makes the order of dict elements random; see
>> https://docs.python.org/3/using/cmdline.html#cmdoption-R
> Ah, good catch. That explains the, well, randomness. I can reproduce
> the test failures with PYTHONHASHSEED=2.
> But I haven't been successful getting that environment variable set so
> that it works in the installcheck case.
Yeah, there's pretty much no chance of controlling the postmaster's
environment in installcheck cases.
> Instead, I have rewritten the tests to use asserts instead of textual
> comparisons. See attached patch. Comments?
If that works back to Python 2.3 or whatever is the oldest we support,
sounds good to me.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Joshua D. Drake | 2015-05-29 03:32:10 | Re: RFC: Remove contrib entirely |
Previous Message | Robert Haas | 2015-05-29 03:24:45 | Re: [HACKERS] Re: 9.4.1 -> 9.4.2 problem: could not access status of transaction 1 |