I just installed cadabra2by compiling from source on a machine running Linux Mint 18. I tested the command line version of cadabra, and it seems to work well (albeit with simple addition/multiplication of numerical and algebraic expresions; not with tensor quantities). The GUI version fails. After firing the gui with cadabra2-gtk I do get the GUI but evaluating a cell always fails, no matter what expression is in the cell. The message "cadabra-client: connection failed" prints on the terminal from which I fired Cadabra. I traced it to a function/method in ComputeThread.cc under the client_server subdirectory in the source code.
Any suggestions to get around this problem? Any help will be appreciated.
Hi, I am having the exact same issue from WSL (Windows Subsystem for Linux). Did you manage to solve the issue in the end?
What happens if you try to start cadabra-server from a terminal window?
Does the GUI say 'connected' at the bottom?
No, it doesn't. It only says 'idle'.
Can you please run
in the terminal and send me the output?
Here is the output:
$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 220.127.116.11 0.0.0.0 UG 100 0 0 enp0s25
18.104.22.168 0.0.0.0 255.255.255.128 U 100 0 0 enp0s25
22.214.171.124 126.96.36.199 255.255.255.255 UGH 100 0 0 enp0s25
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 enp0s25
Hi, I am encountering the very same issue as the OP of this thread, I believe. I am using WSL, but the symptoms are really the same: Cadabra2 works just fine from command line, but if I give any command in the GUI it will just freeze. (bottom right displays "idle")
For anyone running into this problem: this is a network issue, by which the cadabra2-gtk process is unable to reach the cadabra-server. Try the following:
Start cadabra-server by hand from a separate terminal window. This spits out two lines; a number and a uuid identifier. That first number is the port to which the server has bound.
Try to connect to that port by hand using
telnet localhost [port]
Then report here whether the connection is achieved or not.
If the connection failed, check whether /etc/hosts contains a line
On WSL it is conceivable that the windows firewall prevents these connections from being created.
Hi Kasper, thanks for the support. I'm the guy trying to use WSL. Unfortunately
telnet localhost [####]
where #### is the port number given by cadabra-server returns
"could not resolve localhost/[####]: Servname not supported for ai_socktype"
In the meantime I am looking into possible firewall issues.
As an aside, browsers and co. seem to work just fine even from the WSL.
Type that without the square brackets.
OK, now it returns:
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
Also, the hosts file does contain the line
Disabling the firewall I get the same results
Hi Kasper, a small update.
I tried accessing cadabra from jupyter, instead of using directly cadabra2-gtk.
In this case, the jupyter notebook cannot connect to the cadabra kernel apparently.
Jupyter can instead connect to the Python kernel.