What should I write instead of `isBound`?
The package krpc is not building. One of the issues is that the function isActive:
https://github.com/pxqr/krpc/blob/5c54f6570a27e1509ddf048a91bd69c05052f2f1/src/Network/KRPC/Manager.hs#L195-L201
— Wants to call isBound but I see from the change log that it was deprecated in 2.7 and removed in 3.0, along with other stuff related to SocketStatus.
I did not find any migration guide or the reasoning behind it being removed.
Is there a standard way to fix the function isBound?
Otherwise, could you release an updated version 2 that can be built with GHC 9.4 or thereabout? The latest as of now is 2.8.0.1 and it needs base < 4.17 which is kinda close. Some versions of network-2 build with GHC 9.4 and the Cabal flag --allow-newer=base already so maybe it is only a matter of metadata revision.
Socket does not have the status anymore.
Probably you can check if a socket is bound using getSocketName.
The initial port is 0.
After binding, the port should be the server port.
When the socket is closed, the internal FD value becomes -1.
You can check it with withFdSocket.
Thank you, I shall try this.
Closing. Please re-open if necessary.