Www.swi-prolog.org goes https (Discussion)

Perhaps this broke pack installation:

2 ?- pack_install(julian_lang_en).
% Contacting server at http://www.swi-prolog.org/pack/query ...
ERROR: url `'https://www.swi-prolog.org/pack/query'' does not exist (status(500,Internal
Server Error))
ERROR: In:
ERROR:   [19] throw(error(existence_error(url,'https://www.swi-prolog.org/pack/query'),co
ntext(_24476,...)))
ERROR:   [17] http_open:try_http_proxy(direct,[uri('http://www.swi-prolog.org/pack/query'
),...|...],_24512,[post(...),...]) at /home/u/tmp/swipl-devel/build.release/home/library/
http/http_open.pl:425
1 Like

Yip. I’ll have a look. This is one of the things for which you want HTTPS :slight_smile:

1 Like

The redirect does not work for a POST request. I pushed a fix. For existing installations, you need to edit the server location in library(prolog_pack) to

:- setting(server, atom, 'https://www.swi-prolog.org/pack/',
           'Server to exchange pack information').

Typically, start Prolog sufficient rights to write the library files and run

?- edit(library(prolog_pack)).

Find the above line (93), add the s and save. For one-time usage you can do

?- [library(prolog_pack)].
?- set_setting(prolog_pack:server, 'https://www.swi-prolog.org/pack/').
?- pack_install(...).
1 Like

Thanks, it is working now.

Might be a good idea to apply the fix to the stable version,
since people seem to be having problems:

1 Like

You have a point. As is though, the 8.0.x version is far behind in many aspects. This happened a lot quicker than usual and various critical patches are probably not trivial to backport due to quite big changes that affect a lot of the code. Is there someone willing to examine the changes in 8.1 since the last merge and get the important part into 8.0?

This happens every stable cycle, but this time rather quickly. If anyone wants to take responsibility for keeping the stable version stable but patched with vital patches, please stand up.

I can have a look at least…“stable” is HEAD of the swipl repo & development is HEAD of swipl-devel?

Thanks. However, however Keri Harris also promised to have a look. If you want to play a role in the long term maintenance for stable, let discuss so offline on how to organize that.

As is, swipl and swipl-devel are related repositories. I probably won’t do that again, but git supports this quite well. I have added swipl-devel as an additional remote to swipl and simply cherry pick commits to create a new stable patch level. For a new stable minor or major release I merge swipl-devel.

2 Likes

I used this tip/sequence … it works for the major of the packs install… great …
thanks

claudio