[PATCH 0 of 5] using ctypes on Windows

Adrian Buehlmann adrian at cadifra.com
Sat Feb 12 17:29:01 CST 2011

On 2011-02-12 23:47, Steve Borho wrote:
> On Sat, Feb 12, 2011 at 4:44 PM, Patrick Mézard <pmezard at gmail.com> wrote:
>> Le 12/02/11 20:23, Patrick Mézard a écrit :
>>> Le 12/02/11 18:45, Adrian Buehlmann a écrit :
>>>> On 2011-02-08 17:52, Adrian Buehlmann wrote:
>>>>> The first patch ports win32.py to using Python's ctypes library
>>>>> on Windows (replacing pywin32).
>>>>> The remaining patches are some followup refactorings.
>>>>> The patches can also be pulled with
>>>>>   hg pull -r ad3db71cb3d3 https://bitbucket.org/abuehl/mercurial-crew
>>>>> I've built Windows msi installers
>>>>>   mercurial-unstable-ad3db71cb3d3-abuehl-ctypes-1-x86.msi
>>>>>   mercurial-unstable-ad3db71cb3d3-abuehl-ctypes-1-x64.msi
>>>>> and uploaded these at
>>>>>   https://bitbucket.org/abuehl/mercurial-crew/downloads
>>>>> I've manually tested these on pristine installs of Windows 7 x64
>>>>> and Windows XP SP3 x86.
>>>>> Mercurial testsuite ran ok on Ubuntu Linux (as always when I send
>>>>> a patch).
>>>>> I recommend to include these patches in Mercurial 1.8.
>>>> Any chance this could go in for 1.8 before the feature freeze?
>>>> I still recommend to take this series. It was quite some work to do
>>>> (e.g. lots of manual testing).
>>>> The (IMHO suboptimal) alternative is making pywin32 mandatory. Which
>>>> would be strange if we later switch to ctypes anyway, which I think will
>>>> happen anyway sooner or later.
>>>> Is there something left needed from my side to get this in? What can I
>>>> do to convince you?
>>>> I haven't seen any convincing arguments against this series so far.
>>> In theory, I am all for this series.
>>> In practice, it seems to need more testers but we can probably fix things before the code freeze. I will start using it on Windows XP right now. I have also added it to my Windows test bot patch queue, which does not mean a lot but who knows it may pick some issues (even if it is a Windows 2003 Server). And I will try to read it more thoroughly even if I am not a ctypes nor Windows 64 bits specialist.
>> Test suite result is:
>>   # Ran 328 tests, 103 skipped, 0 failed.
>> Which is on par with running it without the series. The skipped tests are those known to be failing for a long time, some of which can probably be fixed. It helps keeping a reference of what's really supposed to pass.

Thanks a lot, Patrick.

> If there were more testing volunteers (and the need for more testers),
> I'd be happy to make some installers with these patches applied.

Thanks Steve.

The real stress test will be if this stuff is exercised by all the
TortoiseHg users. Which will not happen until we release this with a
major release (best 1.8).

So the best thing we probably can do is push the patches to mercurial
crew and main (including the fix by Patrick) and use them for the
official TortoiseHg nightlies ASAP.

Would be nice if there were unstable (=using mercurial default branch)
nightlies for the legacy hgtk TortoiseHg as well (not just for the new
Qt TortoiseHg).

FWIW, I'm confident that going the ctypes route for 1.8 is the right thing.

More information about the Mercurial-devel mailing list