| Store | Cart

[Python-Dev] PEP 385: the eol-type issue

From: Mark Hammond <mham...@skippinet.com.au>
Wed, 05 Aug 2009 09:43:15 +1000
On 4/08/2009 7:20 PM, Nick Coghlan wrote:
> Dirkjan Ochtman wrote:>>>> * commit hooks be implemented to enforce this - but this should not be>>>> necessary if the above was implemented and socially enforced.>>>> You seem to advocate a two-step approach: enforce line endings through>> win32text, catch any errors that slipped through in a hook (commit>> hook is an optional first line of defense, changegroup hooks on the>> server to protect the rest of the world).>>>> I think inverting that approach would be better: have strict hooks on>> the server to prevent people from pushing inappropriate EOLs, and>> provide help on configuring win32text as an extra help for developers>> on Windows who use editors that work better with \r\n. That leaves>> people to pick their own weapon of choice against propagation of \r\n>> (e.g. better editor, commit hooks, whatever) while still making sure>> no inappropriate line endings land in the python.org repositories. It>> also seems to fit well with the whole consenting adults thing (but>> that might just be me).>> It's about not treating Windows developers as second class citizens.> Their platform uses \r\n as its native line ending format, so they

Thanks Nick; I didn't want to be the only one saying that.  There is a 
fine line between asserting reasonable requirements for Windows users 
and being obstructionist and unhelpful, and I'm trying to stay on the 
former side :)

> should be able to work in that format without any hassles by following> some simple instructions (such as "ensure you have version X of the> Windows hg client, enable the win32text extension and configure it in> such-and-such a way"). Not "oh, yeah, that's an issue but if you search> the Intarwebs there are a few different things you can do that kinda> sorta work but are a bit fragile and klunky".>> The precise order the two issues (server side enforcement and client> side assistance) are dealt with doesn't really matter because *both*> issues need to be addressed before we migrate.

I'm not that happy with the server being the primary line of defense. 
Let's say I make a branch of the hg repo, myself and a few others work 
on it committing as we go, then attempt to merge back upstream.  Let's 
say some of the early commits on that clone introduced "bad" line 
endings.  I'm guessing I would be forced to make a number of 
whitespace-only checkins to normalize the line-endings before it could 
merge - and these checkins would then be in the history forever.  Or I 
could attempt to recreate the clone by somehow "replaying" the commits 
with line endings corrected.  Either way, the situation doesn't seem good.

> win32text needs to be usable on non-Windows clients so that tarballs> generated on a *nix machine get the line endings right in the> Windows-only files.

I agree.  It isn't fair to make this windows users problem.  It would be 
like me proposing the repo get imported with \r\n line endings, enforce 
that with server side hooks, and let non-Windows users worry about the 
ramifications of that - somehow I doubt that would fly - so neither 
should it fly for Windows users...

I'm more than willing to help on this; I haven't resurrected my stale 
patch because I find win32text only 1/2 a solution that doesn't work in 
practice.  Therefore that patch is as stale for me as it is anyone. 
However, if a plan is put in place which offers a full solution and the 
hg developers are committed to it, I promise I'll put my hand up to help 
with implementation in a fairly timely manner...

Cheers,

Mark

Recent Messages in this Thread
Dirkjan Ochtman Aug 03, 2009 10:41 am
Nick Coghlan Aug 04, 2009 09:20 am
Mark Hammond Aug 04, 2009 11:43 pm
Neil Hodgson Aug 05, 2009 12:44 am
"Martin v. Löwis" Aug 05, 2009 07:35 am
Mark Hammond Aug 05, 2009 07:44 am
"Martin v. Löwis" Aug 05, 2009 08:09 am
Paul Moore Aug 05, 2009 10:04 am
Dirkjan Ochtman Aug 05, 2009 10:14 am
Mark Hammond Aug 05, 2009 11:22 am
John Arbash Meinel Aug 05, 2009 02:58 pm
"Martin v. Löwis" Aug 05, 2009 06:22 pm
Mark Hammond Aug 05, 2009 11:19 am
Dirkjan Ochtman Aug 05, 2009 11:28 am
Mark Hammond Aug 05, 2009 11:46 am
Glenn Linderman Aug 05, 2009 05:43 pm
Paul Moore Aug 05, 2009 04:24 pm
Neil Hodgson Aug 05, 2009 08:25 am
"Martin v. Löwis" Aug 05, 2009 08:41 am
Neil Hodgson Aug 05, 2009 09:09 am
Georg Brandl Aug 05, 2009 07:43 pm
"Martin v. Löwis" Aug 05, 2009 08:13 pm
Georg Brandl Aug 05, 2009 08:18 pm
Ben Finney Aug 05, 2009 05:56 am
Mark Hammond Aug 05, 2009 06:08 am
Ben Finney Aug 05, 2009 06:50 am
Mark Hammond Aug 05, 2009 07:31 am
Ben Finney Aug 05, 2009 08:00 am
Mark Hammond Aug 05, 2009 08:09 am
Ben Finney Aug 05, 2009 09:42 am
"Martin v. Löwis" Aug 05, 2009 08:12 am
Stephen J. Turnbull Aug 05, 2009 02:28 pm
Georg Brandl Aug 05, 2009 07:56 pm
Mark Hammond Aug 06, 2009 12:34 am
Stephen J. Turnbull Aug 06, 2009 06:00 am
"Martin v. Löwis" Aug 06, 2009 06:40 am
Stephen J. Turnbull Aug 06, 2009 07:12 am
"Martin v. Löwis" Aug 05, 2009 07:45 am
Dj Gilcrease Aug 05, 2009 06:02 am
Dirkjan Ochtman Aug 05, 2009 08:25 am
"Martin v. Löwis" Aug 05, 2009 08:51 am
Dirkjan Ochtman Aug 05, 2009 09:04 am
"Martin v. Löwis" Aug 05, 2009 09:12 am
Mark Hammond Aug 05, 2009 09:02 am
Dirkjan Ochtman Aug 05, 2009 09:09 am
"Martin v. Löwis" Aug 05, 2009 09:16 am
Mark Hammond Aug 05, 2009 09:17 am
Nick Coghlan Aug 05, 2009 12:50 pm
MRAB Aug 05, 2009 01:35 pm
Dirkjan Ochtman Aug 05, 2009 01:37 pm
Nick Coghlan Aug 05, 2009 02:12 pm
Oleg Broytmann Aug 05, 2009 01:50 pm
Oleg Broytmann Aug 05, 2009 01:57 pm
Stephen J. Turnbull Aug 05, 2009 03:34 pm
"Martin v. Löwis" Aug 05, 2009 06:37 pm
Stephen J. Turnbull Aug 06, 2009 05:00 am
"Martin v. Löwis" Aug 06, 2009 05:48 am
Neil Hodgson Aug 06, 2009 10:10 pm
M.-A. Lemburg Aug 07, 2009 08:31 am
Antoine Pitrou Aug 07, 2009 12:12 pm
M.-A. Lemburg Aug 07, 2009 12:48 pm
Neil Hodgson Aug 05, 2009 10:22 pm
M.-A. Lemburg Aug 06, 2009 08:31 am
Antoine Pitrou Aug 06, 2009 08:51 am
Nick Coghlan Aug 06, 2009 10:19 am
M.-A. Lemburg Aug 06, 2009 10:40 am
M.-A. Lemburg Aug 06, 2009 10:46 am
Antoine Pitrou Aug 06, 2009 11:01 am
M.-A. Lemburg Aug 06, 2009 11:34 am
Antoine Pitrou Aug 06, 2009 11:42 am
Dirkjan Ochtman Aug 05, 2009 02:04 pm
Messages in this thread