[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-03-03 Thread Andrew Bartlett


Andrew Bartlett  added the comment:

...Python 2.9 or at best 2.10. 

Of course I mean Python 3.9 or at best 3.10. 

Sorry for the confusion.

--

___
Python tracker 
<https://bugs.python.org/issue37330>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-03-03 Thread Andrew Bartlett


Andrew Bartlett  added the comment:

I think we are speaking past each other. 

Yes, Python 2 is no longer being changed, which is awesome as we need for fear 
breakage of the older builds that use that for the build system.

The issue isn't the particular language feature, or that there is no way to 
further adapt code, but that a valid build script that operates correctly on 
Python 3.8 will no longer, without warning to us, operate on Python 2.9 or at 
best 2.10. 

Thankfully the only Samba versions with support for Python3 are still in 
maintenance, so course I've back-ported patches to the tip of each release 
branch to work around this change.  But again, that doesn't help when I need to 
build an arbitrary git revision in the future. 

(That warnings were available, if we knew were to look, is an entirely moot 
point at this stage).

--

___
Python tracker 
<https://bugs.python.org/issue37330>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-03-02 Thread Andrew Bartlett


Andrew Bartlett  added the comment:

Thanks for the reply.

To clarify, it is best to understand where Samba thinks of itself in terms of 
Python.  We use python, but we don't really think of ourselves as a python 
project, and while we have some developers with a depth of experience in the 
language, most of us just use it as a tool to get things done, in particular to 
build Samba.

Samba has a build system built in Python, called Waf.  Samba uses waf to build 
the project (particularly the C parts), and our build of the C binaries is 
portable back to Python 2.6.  

Often in Samba we find bugs.  This might come as a shock! ;-).  Many of those 
bugs are regressions, and so it is useful to build old versions, sometimes 7 
year old versions, to confirm if/when the behaviour regressed.  We are able to 
do this, with only one patch to address a perl behaviour change, even on a 
modern Ubuntu 18.04 system, all the way back to 2013.  

I terms of 'but this has been deprecated for years', Samba has only had 
releases been able to even use Python3 in the build system for a year (first 
committed to master in July 2018).

Nobody in Samba was aware of any DeprecationWarning and for better or worse we 
only knew about the issue once our builds failed in Fedora.  We are incredibly 
grateful that Fedora tried a rebuild with the alpha version of Python 3.9 as 
otherwise we would find out only after this was well baked into a release.

Thankfully we don't need universal newlines, but no matter if we need them, old 
versions of Samba will fail to build without a fix-up patch.

More importantly, I think it is unlikely that Samba is the only software to 
have used this feature, intentionally or otherwise, or to be in this position.  

While not as critical here, for context as to why we support Python 2.6 to 
build, it should be noted that retaining this compatibility was a critical part 
of being able to get consensus to otherwise move to Python 3.4.

--

___
Python tracker 
<https://bugs.python.org/issue37330>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37330] open(): remove 'U' mode, deprecated since Python 3.3

2020-02-20 Thread Andrew Bartlett


Andrew Bartlett  added the comment:

This breaks Samba's build:

https://bugzilla.samba.org/show_bug.cgi?id=14266

While we are of course able to patch new versions of Samba, this will make it 
harder to bisect back though Samba history.  It would be really great if this 
kind of change could be reverted or at least deferred so Samba can rely on a 
stable language platform for it's build system.

--
nosy: +abartlet

___
Python tracker 
<https://bugs.python.org/issue37330>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com