Cannot verify package (Example clpBNR)

Wanted to replay this here:

?- pack_install(clpBNR,[url('https://github.com/ridgeworks/clpBNR.git')]).
% Cloning into '/Users/rworkman/.local/share/swi-prolog/pack/clpBNR'...
Verify package status (anonymously)
	at "https://www.swi-prolog.org/pack/query" Y/n? 
% Contacting server at https://www.swi-prolog.org/pack/query ... ok

https://github.com/ridgeworks/clpBNR#getting-started

But then I get on my Windows 10 machine with SWI-Prolog 8.5.4:

?- pack_install(clpBNR,[url('https://github.com/ridgeworks/clpBNR.git')]).

Create directory for packages
   (1) * c:/users/foobar/appdata/local/swi-prolog/pack
   (2)   c:/programdata/swi-prolog/pack
   (3)   Cancel

Your choice? 
% Cloning into 'c:/users/foobar/appdata/local/swi-prolog/pack/clpBNR'...
Verify package status (anonymously)
        at "https://www.swi-prolog.org/pack/query" Y/n? 
% Contacting server at https://www.swi-prolog.org/pack/query ...
ERROR: http_reply `'https://www.swi-prolog.org/pack/query'' does not exist

Whats the cure? Skip verify?

Seems it works nevertheless:

?- use_module(library(clpBNR)).
% *** clpBNR v0.9.10alpha ***.
true.

But the interval is worse than in ECLiPSe Prolog:

?- {X==cos(2.3)}, write(X).
_35398{real(-0.6662760212798245,-0.6662760212798237)}
X:: -0.66627602127982... .

Maybe because 2.3 itself is fuzzied?

Yes all floating point literals in clpBNR are assumed to be accurate to only ±0.5 ulp, so

?- {X==2.3}, write(X).
_26730{real(2.299999999999999,2.3000000000000007)}
X:: 2.30000000000000... .

but this answer looks biased, since it should be the same as:

?- {X=<2.3,2.3=<X}, write(X).
_32384{real(2.2999999999999994,2.3000000000000003)}
X:: 2.30000000000000... .

so I need to fix that.

I have no idea why the package verification failed; almost looks like SWIP server had a momentary outage.

I don’t know much about clpBNR internals. Java delivers a
function ulp(), which can be turned into a Prolog evaluable
function ulp/1 and then gives me:

?- X is 2.3.
X = 2.3.
?- X is 2.3+ulp(2.3).
X = 2.3000000000000003.
?- X is 2.3-ulp(2.3).
X = 2.2999999999999994.

Didn’t check yet cos/1 evaluable function, either in ECLiPSe Prolog nor
clpBNR, whether ulp/1 can be used to simulate their interval calculation, by
simply adding a boundary via the ulp/1 evaluable function,

which then would give me an easy explanation. The static method ulp() is
from the Java class Math. I don’t find this function in SWI-Prolog.

Edit 22.03.2022:
The evaluable function ulp/1 seems to be also able to simulate your
fuzzing for integral floats. I get in SWI-Prolog:

?- {X==1000.0}, write(X).
_14038{real(999.9999999999998,1000.0000000000002)}
X:: 1000.000000000000... .

And then with ulp/1:

?- X is 1000.0.
X = 1000.0.
?- X is 1000.0+ulp(1000.0).
X = 1000.0000000000001.
?- X is 1000.0-ulp(1000.0).
X = 999.9999999999999.

But the above is tighter, since, using SWI-Prolog:

?- 999.9999999999999 == 999.9999999999998.
false.
?- 1000.0000000000001 == 1000.0000000000002.
false.

Yes, clpBNR just uses the Prolog arithmetic function nexttoward/2 for this purpose, so

?- Y is nexttoward(2.3,inf).
Y = 2.3000000000000003.

?- Z is nexttoward(2.3,-inf).
Z = 2.2999999999999994.

is the right answer (fix required for {X==2.3}).

There is no ulp function in SWIP but you could build one with nexttoward.

There’s also bounded_number/3; one of its modes will generate the lower and upper bound guaranteed to contain a floating point value:

?- bounded_number(L,H,2.3).
L = 2.2999999999999994,
H = 2.3000000000000003.

?- bounded_number(L,H,1000.0).
L = 999.9999999999999,
H = 1000.0000000000001.
?- set_prolog_flag(float_overflow, infinity).
true.

?- X is inf, Y is nexttoward(1000,X).
X = 1.0Inf,
Y = 1000.0000000000001.

In this case it might be better if this flag is not required. Using the default flag, any Inf being the result of evaluating a (sub)expression causes a float overflow. Only the inf/0 function is hacked to avoid that.