<d_bot_>
<NULL> You can read that string of 0s and 1s, prepend "0b" and pass it to int_of_string
rgrinberg has quit [Ping timeout: 252 seconds]
azimut has quit [Remote host closed the connection]
azimut has joined #ocaml
dhil has quit [Ping timeout: 240 seconds]
<d_bot_>
<kurtz> i'll try that out
humasect has joined #ocaml
epony has quit [Ping timeout: 240 seconds]
gravicappa has joined #ocaml
<d_bot_>
<kurtz> i have a "challenge" in #beginners if anyone is interested in taking it up. it's related to solving a hackerrank problem i've probably overthought at this point lol.
<d_bot_>
<kurtz> i have a small block of text outlining the problem in #beginners but i'll spare spamming IRC with that and just post the problem link here:
<d_bot_>
<kurtz> TL;DR i've probably overthought the solution and wonder if simply finding all valid combinations of the input and then searching for the greatest(s) pairs is the best approach. interested in suggestions. only caveat (if you want to test your solution on hackerrank yourself, at least) is that they have a slightly older version of ocaml and thus don't have zarith. you'll need Num for big integer stuff.
<c209e6dc-4d76-47>
I am trying to run some ocaml benchmarks and don't have familarity with the language, for the setup step `opam install --yes dune.2.7.1 domainslib.0.3.0 sexplib.v0.14.0 containers.2.8.1` is failing for me
<c209e6dc-4d76-47>
I tried domainslib.0.4.0 but that also didn't work
<c209e6dc-4d76-47>
I got `Error: Unbound module Mutex`, so I searched and found I have to add `+threads`, how can I do that for opam?
<c209e6dc-4d76-47>
I initialized using `opam switch create 4.10.0+multicore+no-effect-syntax --packages=ocaml-variants.4.10.0+multicore+no-effect-syntax --repositories=multicore=git+https://github.com/ocaml-multicore/multicore-opam.git,default`
<ns12>
I have written some kind of long-running server program. When I run it using "dune exec --watch -- ./myserver.ml", dune doesn't seem to reload the server whenever I edit the source code. Is that normal?
<ns12>
What is "--watch" supposed to do?
c209e6dc-4d76-47 has quit [Quit: Konversation terminated!]
vicfred has joined #ocaml
vicfred_ has joined #ocaml
vicfred_ has quit [Remote host closed the connection]
vicfred has quit [Ping timeout: 256 seconds]
Serpent7776 has joined #ocaml
humasect has joined #ocaml
humasect has quit [Remote host closed the connection]
adanwan has quit [Remote host closed the connection]
adanwan has joined #ocaml
wonko has joined #ocaml
<d_bot_>
<mseri> c209e6dc-4d76-47 I think the compiler is 4.12.0+domains, but now that is merged in ocaml you should probably use https://github.com/ocaml/ocaml-beta-repository and install the 5.0.0-trunk variant
<d_bot_>
<mseri> Or maybe replace the version with 5.00.0+trunk for the latest domainslib
humasect has quit [Ping timeout: 240 seconds]
humasect has joined #ocaml
olle has joined #ocaml
humasect has quit [Quit: Leaving...]
Anarchos has joined #ocaml
<Anarchos>
I have a strange bug : an in_channel (backed by a socket) is blocked in read in the server, and the socket is blocked in write in the client (a netcat sending to this socket). Did someone ever experienced such race condition ?
wonko has quit [Ping timeout: 252 seconds]
<d_bot_>
<mseri> C209e6dc-4d76-47, I just tried `opam switch create 5.00.0+trunk` and `opam install domainslib eio_main` and it worked fine
<d_bot_>
<mseri> Sexplib does not work for me, uses some Obj stuff that is not compatible with multicore
hackinghorn has joined #ocaml
gopiandcode has quit [Quit: WeeChat 3.0]
wonko has joined #ocaml
adanwan has quit [Ping timeout: 240 seconds]
adanwan has joined #ocaml
Haudegen has quit [Quit: No Ping reply in 180 seconds.]
Haudegen has joined #ocaml
gopiandcode has joined #ocaml
bartholin has joined #ocaml
szkl has quit [Quit: Connection closed for inactivity]
wonko- has joined #ocaml
wingsorc has quit [Quit: Leaving]
mclovin has quit [Quit: Bridge terminating on SIGTERM]
saltrocklamp[m] has quit [Quit: Bridge terminating on SIGTERM]
OCamlPro[m] has quit [Quit: Bridge terminating on SIGTERM]
smondet[m] has quit [Quit: Bridge terminating on SIGTERM]
CodeBitCookie[m] has quit [Quit: Bridge terminating on SIGTERM]
JosEduardo[m] has quit [Quit: Bridge terminating on SIGTERM]
jlrnick has joined #ocaml
olle has quit [Remote host closed the connection]
mclovin has joined #ocaml
smondet[m] has joined #ocaml
JosEduardo[m] has joined #ocaml
saltrocklamp[m] has joined #ocaml
CodeBitCookie[m] has joined #ocaml
OCamlPro[m] has joined #ocaml
olle has joined #ocaml
Anarchos has quit [Quit: Client closed]
mro has quit [Read error: Connection reset by peer]
mro_ has joined #ocaml
szkl has joined #ocaml
mro_ has quit [Remote host closed the connection]
mro has joined #ocaml
mro has quit [Remote host closed the connection]
bobo has joined #ocaml
spip has quit [Ping timeout: 240 seconds]
epony has joined #ocaml
Haudegen has quit [Quit: Bin weg.]
mbuf has quit [Quit: Leaving]
mro has joined #ocaml
sheb has joined #ocaml
sheb has quit [Remote host closed the connection]
dwt_ has joined #ocaml
dhil has joined #ocaml
mro has quit [Remote host closed the connection]
mro has joined #ocaml
Haudegen has joined #ocaml
bartholin has quit [Ping timeout: 256 seconds]
bartholin has joined #ocaml
jlrnick has quit [Ping timeout: 240 seconds]
mro has quit [Remote host closed the connection]
jacobjacobjacob has joined #ocaml
rgrinberg has joined #ocaml
jacobjacobjacob has quit [Quit: Client closed]
jacobjacobjacob has joined #ocaml
jacobjacobjacob has quit [Quit: Client closed]
jcob has joined #ocaml
olle has quit [Quit: Lost terminal]
rgrinberg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mro has joined #ocaml
Haudegen has quit [Quit: Bin weg.]
mro has quit [Remote host closed the connection]
mro has joined #ocaml
rgrinberg has joined #ocaml
mro has quit [Remote host closed the connection]
mro has joined #ocaml
jlrnick has joined #ocaml
mro has quit [Remote host closed the connection]
jcob has quit [Quit: Client closed]
zebrag has joined #ocaml
olle has joined #ocaml
Tuplanolla has joined #ocaml
rgrinberg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rgrinberg has joined #ocaml
kakadu_ has quit [Remote host closed the connection]
rgrinberg has quit [Remote host closed the connection]
rgrinberg has joined #ocaml
ns12 has quit [Quit: bye]
ns12 has joined #ocaml
bartholin has quit [Quit: Leaving]
Haudegen has joined #ocaml
dalek_caan has joined #ocaml
wonko_ has joined #ocaml
szkl has quit [Quit: Connection closed for inactivity]
rgrinberg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
olle has quit [Ping timeout: 272 seconds]
gareppa has joined #ocaml
dalek_caan has quit [Quit: dalek_caan]
gareppa has quit [Quit: Leaving]
gravicappa has quit [Ping timeout: 272 seconds]
waleee has joined #ocaml
mro has joined #ocaml
rgrinberg has joined #ocaml
mro has quit [Quit: Leaving...]
Anarchos has joined #ocaml
<sleepydog>
Anarchos: I don't understand; why would the client be blocked in write unless it has something it wants to write?
olle has joined #ocaml
<companion_cube>
@mseri Sexplib uses Obj? lol
<sleepydog>
Anarchos: how did you create the in_channel on the server ? Unix.establish_server or something else?
oriba has joined #ocaml
<Anarchos>
sleepydog yes, establis_server.
oriba has quit [Client Quit]
oriba has joined #ocaml
rgrinberg has quit [Ping timeout: 240 seconds]
<sleepydog>
i see. are the server and netcat on the same machine?
<Anarchos>
yes
<d_bot_>
<monk> i was thinking that too lol
<sleepydog>
if you're on linux, did you check to see exactly where the server was blocked? strace -k -p $pid or looking at /proc/$pid/stack would do it
<Anarchos>
well, i am not on linux...
<Anarchos>
though i have strace
<sleepydog>
oh, ok
<sleepydog>
it's just very strange if server is blocked on a read() sys call and client blocked on a write() sys call, unless there was a network issue, which doesn't seem possible in your setup
<Anarchos>
it seems to always block after the same amount of bytes transferred, but this amount depends of the sleep() argument i add to slow down the server processing of data. Very strange, i thought there is maybe a buffer full somewhere
<sleepydog>
maybe it's trying to copy or resize a buffer and waiting to take a lock or something. is the code shareable? sounds interesting
<Anarchos>
sure,just wait a minute
<Anarchos>
https://github.com/Sylvain78/Preuves the serv and client are two shell scripts reproducing the problem, once you find your way through my awful dune files....
<sleepydog>
where do you suspect the server is blocked?