Python 3.8.2 on MacOSX Sierra?

2020-03-21 Thread Greg Ewing
I'm trying to compile a framework build of Python 3.8.2 on MacOSX 10.12.6 (Sierra). I'm getting: ./Modules/posixmodule.c:4696:12: warning: 'utimensat' is only available on macOS 10.13 or newer [-Wunguarded-availability-new] return utimensat(dir_fd, path, time, flags); ./Modules/posix

Re: inheriting from long on Python2 or int on Python3

2020-03-21 Thread Terry Reedy
On 3/21/2020 1:19 PM, duncan smith wrote: Hello, I have a class I wrote for Python2 that needs to be made to work on Python3. On Python2 it inherited from long, so it needs to inherit from int on Python3. In general, if you want code to work on both 2 and 3, look into the bi-version pac

Re: inheriting from long on Python2 or int on Python3

2020-03-21 Thread Chris Angelico
On Sun, Mar 22, 2020 at 11:31 AM duncan smith wrote: > but (tentatively) opted for something that avoided creating new names at > the module level. If it doesn't look too terrible I might stick with it > for now (although I am quite tempted to go back to the above). Thanks > Skip and Chris. Nah,

Re: inheriting from long on Python2 or int on Python3

2020-03-21 Thread duncan smith
On 21/03/2020 21:55, Skip Montanaro wrote: >> import sys >> >> class C_hash(int if sys.version_info.major >= 3 else long): > ... > > There's nothing incorrect with your solution. Chris offered another. I > was going to suggest you consider running your code through 2to3 to > see what it does. I cr

Re: inheriting from long on Python2 or int on Python3

2020-03-21 Thread Skip Montanaro
> import sys > > class C_hash(int if sys.version_info.major >= 3 else long): ... There's nothing incorrect with your solution. Chris offered another. I was going to suggest you consider running your code through 2to3 to see what it does. I created a C_hash class similar to yours: class C_hash(lon

Re: inheriting from long on Python2 or int on Python3

2020-03-21 Thread Chris Angelico
On Sun, Mar 22, 2020 at 4:21 AM duncan smith wrote: > > Hello, > I have a class I wrote for Python2 that needs to be made to work > on Python3. On Python2 it inherited from long, so it needs to inherit > from int on Python3. The following works, but I'm not sure it's the > cleanest solution.

Re: Intermittent bug with asyncio and MS Edge

2020-03-21 Thread Barry Scott
> On 21 Mar 2020, at 13:43, Frank Millman wrote: > > Hi all > > I have a strange intermittent bug. > > The role-players - >asyncio on Python 3.8 running on Windows 10 >Microsoft Edge running as a browser on the same machine > > The bug does not occur with Python 3.7. > It does not o

inheriting from long on Python2 or int on Python3

2020-03-21 Thread duncan smith
Hello, I have a class I wrote for Python2 that needs to be made to work on Python3. On Python2 it inherited from long, so it needs to inherit from int on Python3. The following works, but I'm not sure it's the cleanest solution. It's the first time I've wanted / needed to make a parent class

Intermittent bug with asyncio and MS Edge

2020-03-21 Thread Frank Millman
Hi all I have a strange intermittent bug. The role-players - asyncio on Python 3.8 running on Windows 10 Microsoft Edge running as a browser on the same machine The bug does not occur with Python 3.7. It does not occur with Chrome or Firefox. It does not occur when MS Edge connects to a