libxml2 python bindings

39 views
Skip to first unread message

Daniel Sahlberg

unread,
Jun 14, 2022, 2:31:26 PM6/14/22
to TortoiseSVN-dev
Hi,

The download site for libxml2 python bindings (http://users.skynet.be, see build.txt and doc/readme.txt) seems to be discontinued, reference [1]. 

I have tried to find another distribution but only found another site that is due to be discontinued [2].

Any ideas on how to proceed from here? I guess moving to Python3 would be a good step and there has been some commits (r29299) however xml2po still seems to require Python2 (the original script is "obsolete" according to [3] but there seems to be a Py3 version, however our script is heavily modified). Any other scripts that are not Py3 compatible?

/Daniel


Stefan

unread,
Jun 14, 2022, 2:48:00 PM6/14/22
to TortoiseSVN-dev
I know the problem :(
That's why I thought of discontinuing the translated docs and only use docs in English.

As you've noticed I've already tried switching to python3, but I don't know python so I couldn't get the py3 version of xml2po to work.
If you know python well enough, you could give it a try though.

Or: the [3] link mentions itstool ( https://itstool.org/ ). I haven't tried this yet. Not sure if that tool would work with our docs - the output should not be different that what the xml2po script does now, or we would lose a lot of translations - and then we can just drop them and only use English docs...

there are one or two other python scripts in the TSVN source tree, but they're not really in use anymore (TranslationStatus.py was used to generate a report that was sent to the mailing list, and chkidd.py was used to check whether a TSVN dialog has a corresponding doc entry)

Stefan

Daniel Sahlberg

unread,
Jun 14, 2022, 5:14:13 PM6/14/22
to TortoiseSVN-dev
tisdag 14 juni 2022 kl. 20:48:00 UTC+2 skrev Stefan:
I know the problem :(
That's why I thought of discontinuing the translated docs and only use docs in English.

Now that you mention. Did you get any feedback on this question out-of-band (I was the only one to respond on the group)? Did you come to a decision on this?

As you've noticed I've already tried switching to python3, but I don't know python so I couldn't get the py3 version of xml2po to work.
If you know python well enough, you could give it a try though.

I can see what I can do, but it won't go to the top of the list.

Or: the [3] link mentions itstool ( https://itstool.org/ ). I haven't tried this yet. Not sure if that tool would work with our docs - the output should not be different that what the xml2po script does now, or we would lose a lot of translations - and then we can just drop them and only use English docs...

I will also investigate this route.

there are one or two other python scripts in the TSVN source tree, but they're not really in use anymore (TranslationStatus.py was used to generate a report that was sent to the mailing list, and chkidd.py was used to check whether a TSVN dialog has a corresponding doc entry)

Just for the fun of it, I tried to convert TranslationStatus.py, see r29419. chkidd.py you did yourself in 29299 (I didn't test it, just saw the log entry).

/Daniel

Stefan

unread,
Jun 15, 2022, 12:01:14 PM6/15/22
to TortoiseSVN-dev
On Tuesday, June 14, 2022 at 11:14:13 PM UTC+2 daniel.l...@gmail.com wrote:
tisdag 14 juni 2022 kl. 20:48:00 UTC+2 skrev Stefan:
I know the problem :(
That's why I thought of discontinuing the translated docs and only use docs in English.

Now that you mention. Did you get any feedback on this question out-of-band (I was the only one to respond on the group)? Did you come to a decision on this?

not really. You were as you've noticed the only one to respond.
I've decided to keep them for now, but if we can't get it to work with python3 then I'll drop the doc translations for the next svn/tsvn release.
 
there are one or two other python scripts in the TSVN source tree, but they're not really in use anymore (TranslationStatus.py was used to generate a report that was sent to the mailing list, and chkidd.py was used to check whether a TSVN dialog has a corresponding doc entry)

Just for the fun of it, I tried to convert TranslationStatus.py, see r29419. chkidd.py you did yourself in 29299 (I didn't test it, just saw the log entry).

so you know a lot more python than I do ;)

Stefan

Bruce C

unread,
Jun 16, 2022, 5:28:16 AM6/16/22
to TortoiseSVN-dev
I too recently tried to create the build environment for TortoiseSVN. I had some teething problems that I've not yet reported but I've been interested to see that you've apparently not had those issues.

With respect to the libxml2 library, it seems to me that there are two issues. The first is trying to get a copy of the library that's currently being used. The second, as you've been discussing, is a replacement for the library that is now difficult to obtain. I have nothing to contribute to the latter.

However, if others are also struggling to obtain a copy of the library, the trick I used was to use the Internet Archive Wayback Machine. Using that, I found a copy of the library that's currently used for the build, even though the referenced web site is longer available. If anyone else is having difficulty getting the original library then this might help.

Daniel Sahlberg

unread,
Jun 16, 2022, 5:50:06 AM6/16/22
to TortoiseSVN-dev
torsdag 16 juni 2022 kl. 11:28:16 UTC+2 skrev Bruce C:
I too recently tried to create the build environment for TortoiseSVN. I had some teething problems that I've not yet reported but I've been interested to see that you've apparently not had those issues.

With respect to the libxml2 library, it seems to me that there are two issues. The first is trying to get a copy of the library that's currently being used. The second, as you've been discussing, is a replacement for the library that is now difficult to obtain. I have nothing to contribute to the latter.

I think we should start by dropping Python2 support, hoping that the library is more readily available for Python3.

For comparison, the policy of the Subversion project is to support Python2 for the remainder of 1.14 "unless an unreasonable burden". That policy mainly applies to using Subversion but I think there was some work also on the build system to support old platforms where Python3 might not be available.

In our case, we have good support for Python3 on our build platform (we already require Visual Studio 2022 and Windows 10, so no-one should be building on old Windows versions where Python 3 isn't available) so it should not cause trouble for anyone.

/Daniel

Bruce C

unread,
Jun 16, 2022, 6:33:12 AM6/16/22
to TortoiseSVN-dev
I was simply adding a note to assist with the recreation of the current build system. This might help others in the same position. Obviously this workaround will only be short-term if you are successful in determining a suitable replacement.

As I said, I have nothing to contribute to the discussion about replacing the library - not an area where I have expertise. I'll have to leave that to others. I agree that replacement sounds like the right option but I'm in no position to comment on your specific suggestions, except to wish you well in your endeavours.

Daniel Sahlberg

unread,
Jun 18, 2022, 5:14:30 PM6/18/22
to TortoiseSVN-dev
onsdag 15 juni 2022 kl. 18:01:14 UTC+2 skrev Stefan:
On Tuesday, June 14, 2022 at 11:14:13 PM UTC+2 daniel.l...@gmail.com wrote:
tisdag 14 juni 2022 kl. 20:48:00 UTC+2 skrev Stefan:
I know the problem :(
That's why I thought of discontinuing the translated docs and only use docs in English.

Now that you mention. Did you get any feedback on this question out-of-band (I was the only one to respond on the group)? Did you come to a decision on this?

not really. You were as you've noticed the only one to respond.
I've decided to keep them for now, but if we can't get it to work with python3 then I'll drop the doc translations for the next svn/tsvn release.

Sounds good.

I /think/ I have manage to do a naive conversion of the scripts to the point where they at least run under Linux. I've also tried it under Python2 on Windows to make sure it is backwards compatible. Please check!

My next problem is to find a libxml2 distribution. Even on Python3, it seems hard to get working. I think it should be possible using the Anaconda Python distribution (at least I get all the DLL files) but I can't get it to run, and I have to call it a night now.

The story will continue.

/Daniel
Reply all
Reply to author
Forward
0 new messages