No subject


Tue Dec 15 01:52:02 PST 2020


=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=
=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=
=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80=
=E2=94=80=E2=94=80=E2=94=80=E2=94=80=E2=94=80

  Here are links from many OCaml blogs aggregated at [OCaml Planet].

  =E2=80=A2 [Memthol: exploring program profiling]
  =E2=80=A2 [Growing the Hardcaml toolset]
  =E2=80=A2 [ Editor Plugin for VSCode and Vim Officially Released!]
  =E2=80=A2 [Announcing Our Market Prediction Kaggle Competition]
  =E2=80=A2 [Every proof assistant: introducing homotopy.io =E2=80=93 a pro=
of assistant
    for geometrical higher category theory]


[OCaml Planet] <http://ocaml.org/community/planet/>

[Memthol: exploring program profiling]
<https://www.ocamlpro.com/2020/12/01/memthol-exploring-program-profiling/>

[Growing the Hardcaml toolset]
<https://blog.janestreet.com/growing-the-hardcaml-toolset-index/>

[ Editor Plugin for VSCode and Vim Officially Released!]
<https://rescript-lang.org/blog/editor-support-release-1-0>

[Announcing Our Market Prediction Kaggle Competition]
<https://blog.janestreet.com/announcing-our-market-prediction-kaggle-compet=
ition-index/>

[Every proof assistant: introducing homotopy.io =E2=80=93 a proof assistant=
 for
geometrical higher category theory]
<http://math.andrej.com/2020/11/24/homotopy-io/>


Old CWN
=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90=E2=95=90

  If you happen to miss a CWN, you can [send me a message] and I'll mail
  it to you, or go take a look at [the archive] or the [RSS feed of the
  archives].

  If you also wish to receive it every week by mail, you may subscribe
  [online].

  [Alan Schmitt]


[send me a message] <mailto:alan.schmitt at polytechnique.org>

[the archive] <http://alan.petitepomme.net/cwn/>

[RSS feed of the archives] <http://alan.petitepomme.net/cwn/cwn.rss>

[online] <http://lists.idyll.org/listinfo/caml-news-weekly/>

[Alan Schmitt] <http://alan.petitepomme.net/>


--=-=-=
Content-Type: text/html; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

<?xml version=3D"1.0" encoding=3D"utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns=3D"http://www.w3.org/1999/xhtml" lang=3D"en" xml:lang=3D"en">
<head>
<!-- 2020-12-15 Tue 10:43 -->
<meta http-equiv=3D"Content-Type" content=3D"text/html;charset=3Dutf-8" />
<meta name=3D"viewport" content=3D"width=3Ddevice-width, initial-scale=3D1"=
 />
<title>OCaml Weekly News</title>
<meta name=3D"generator" content=3D"Org mode" />
<style type=3D"text/css">
 <!--/*--><![CDATA[/*><!--*/
  .title  { text-align: center;
             margin-bottom: .2em; }
  .subtitle { text-align: center;
              font-size: medium;
              font-weight: bold;
              margin-top:0; }
  .todo   { font-family: monospace; color: red; }
  .done   { font-family: monospace; color: green; }
  .priority { font-family: monospace; color: orange; }
  .tag    { background-color: #eee; font-family: monospace;
            padding: 2px; font-size: 80%; font-weight: normal; }
  .timestamp { color: #bebebe; }
  .timestamp-kwd { color: #5f9ea0; }
  .org-right  { margin-left: auto; margin-right: 0px;  text-align: right; }
  .org-left   { margin-left: 0px;  margin-right: auto; text-align: left; }
  .org-center { margin-left: auto; margin-right: auto; text-align: center; }
  .underline { text-decoration: underline; }
  #postamble p, #preamble p { font-size: 90%; margin: .2em; }
  p.verse { margin-left: 3%; }
  pre {
    border: 1px solid #ccc;
    box-shadow: 3px 3px 3px #eee;
    padding: 8pt;
    font-family: monospace;
    overflow: auto;
    margin: 1.2em;
  }
  pre.src {
    position: relative;
    overflow: visible;
    padding-top: 1.2em;
  }
  pre.src:before {
    display: none;
    position: absolute;
    background-color: white;
    top: -10px;
    right: 10px;
    padding: 3px;
    border: 1px solid black;
  }
  pre.src:hover:before { display: inline;}
  /* Languages per Org manual */
  pre.src-asymptote:before { content: 'Asymptote'; }
  pre.src-awk:before { content: 'Awk'; }
  pre.src-C:before { content: 'C'; }
  /* pre.src-C++ doesn't work in CSS */
  pre.src-clojure:before { content: 'Clojure'; }
  pre.src-css:before { content: 'CSS'; }
  pre.src-D:before { content: 'D'; }
  pre.src-ditaa:before { content: 'ditaa'; }
  pre.src-dot:before { content: 'Graphviz'; }
  pre.src-calc:before { content: 'Emacs Calc'; }
  pre.src-emacs-lisp:before { content: 'Emacs Lisp'; }
  pre.src-fortran:before { content: 'Fortran'; }
  pre.src-gnuplot:before { content: 'gnuplot'; }
  pre.src-haskell:before { content: 'Haskell'; }
  pre.src-hledger:before { content: 'hledger'; }
  pre.src-java:before { content: 'Java'; }
  pre.src-js:before { content: 'Javascript'; }
  pre.src-latex:before { content: 'LaTeX'; }
  pre.src-ledger:before { content: 'Ledger'; }
  pre.src-lisp:before { content: 'Lisp'; }
  pre.src-lilypond:before { content: 'Lilypond'; }
  pre.src-lua:before { content: 'Lua'; }
  pre.src-matlab:before { content: 'MATLAB'; }
  pre.src-mscgen:before { content: 'Mscgen'; }
  pre.src-ocaml:before { content: 'Objective Caml'; }
  pre.src-octave:before { content: 'Octave'; }
  pre.src-org:before { content: 'Org mode'; }
  pre.src-oz:before { content: 'OZ'; }
  pre.src-plantuml:before { content: 'Plantuml'; }
  pre.src-processing:before { content: 'Processing.js'; }
  pre.src-python:before { content: 'Python'; }
  pre.src-R:before { content: 'R'; }
  pre.src-ruby:before { content: 'Ruby'; }
  pre.src-sass:before { content: 'Sass'; }
  pre.src-scheme:before { content: 'Scheme'; }
  pre.src-screen:before { content: 'Gnu Screen'; }
  pre.src-sed:before { content: 'Sed'; }
  pre.src-sh:before { content: 'shell'; }
  pre.src-sql:before { content: 'SQL'; }
  pre.src-sqlite:before { content: 'SQLite'; }
  /* additional languages in org.el's org-babel-load-languages alist */
  pre.src-forth:before { content: 'Forth'; }
  pre.src-io:before { content: 'IO'; }
  pre.src-J:before { content: 'J'; }
  pre.src-makefile:before { content: 'Makefile'; }
  pre.src-maxima:before { content: 'Maxima'; }
  pre.src-perl:before { content: 'Perl'; }
  pre.src-picolisp:before { content: 'Pico Lisp'; }
  pre.src-scala:before { content: 'Scala'; }
  pre.src-shell:before { content: 'Shell Script'; }
  pre.src-ebnf2ps:before { content: 'ebfn2ps'; }
  /* additional language identifiers per "defun org-babel-execute"
       in ob-*.el */
  pre.src-cpp:before  { content: 'C++'; }
  pre.src-abc:before  { content: 'ABC'; }
  pre.src-coq:before  { content: 'Coq'; }
  pre.src-groovy:before  { content: 'Groovy'; }
  /* additional language identifiers from org-babel-shell-names in
     ob-shell.el: ob-shell is the only babel language using a lambda to put
     the execution function name together. */
  pre.src-bash:before  { content: 'bash'; }
  pre.src-csh:before  { content: 'csh'; }
  pre.src-ash:before  { content: 'ash'; }
  pre.src-dash:before  { content: 'dash'; }
  pre.src-ksh:before  { content: 'ksh'; }
  pre.src-mksh:before  { content: 'mksh'; }
  pre.src-posh:before  { content: 'posh'; }
  /* Additional Emacs modes also supported by the LaTeX listings package */
  pre.src-ada:before { content: 'Ada'; }
  pre.src-asm:before { content: 'Assembler'; }
  pre.src-caml:before { content: 'Caml'; }
  pre.src-delphi:before { content: 'Delphi'; }
  pre.src-html:before { content: 'HTML'; }
  pre.src-idl:before { content: 'IDL'; }
  pre.src-mercury:before { content: 'Mercury'; }
  pre.src-metapost:before { content: 'MetaPost'; }
  pre.src-modula-2:before { content: 'Modula-2'; }
  pre.src-pascal:before { content: 'Pascal'; }
  pre.src-ps:before { content: 'PostScript'; }
  pre.src-prolog:before { content: 'Prolog'; }
  pre.src-simula:before { content: 'Simula'; }
  pre.src-tcl:before { content: 'tcl'; }
  pre.src-tex:before { content: 'TeX'; }
  pre.src-plain-tex:before { content: 'Plain TeX'; }
  pre.src-verilog:before { content: 'Verilog'; }
  pre.src-vhdl:before { content: 'VHDL'; }
  pre.src-xml:before { content: 'XML'; }
  pre.src-nxml:before { content: 'XML'; }
  /* add a generic configuration mode; LaTeX export needs an additional
     (add-to-list 'org-latex-listings-langs '(conf " ")) in .emacs */
  pre.src-conf:before { content: 'Configuration File'; }

  table { border-collapse:collapse; }
  caption.t-above { caption-side: top; }
  caption.t-bottom { caption-side: bottom; }
  td, th { vertical-align:top;  }
  th.org-right  { text-align: center;  }
  th.org-left   { text-align: center;   }
  th.org-center { text-align: center; }
  td.org-right  { text-align: right;  }
  td.org-left   { text-align: left;   }
  td.org-center { text-align: center; }
  dt { font-weight: bold; }
  .footpara { display: inline; }
  .footdef  { margin-bottom: 1em; }
  .figure { padding: 1em; }
  .figure p { text-align: center; }
  .equation-container {
    display: table;
    text-align: center;
    width: 100%;
  }
  .equation {
    vertical-align: middle;
  }
  .equation-label {
    display: table-cell;
    text-align: right;
    vertical-align: middle;
  }
  .inlinetask {
    padding: 10px;
    border: 2px solid gray;
    margin: 10px;
    background: #ffffcc;
  }
  #org-div-home-and-up
   { text-align: right; font-size: 70%; white-space: nowrap; }
  textarea { overflow-x: auto; }
  .linenr { font-size: smaller }
  .code-highlighted { background-color: #ffff00; }
  .org-info-js_info-navigation { border-style: none; }
  #org-info-js_console-label
    { font-size: 10px; font-weight: bold; white-space: nowrap; }
  .org-info-js_search-highlight
    { background-color: #ffff00; color: #000000; font-weight: bold; }
  .org-svg { width: 90%; }
  /*]]>*/-->
</style>
<style type=3D"text/css">#table-of-contents h2 { display: none } .title { d=
isplay: none } .authorname { text-align: right }</style>
<style type=3D"text/css">.outline-2 {border-top: 1px solid black;}</style>
<script type=3D"text/javascript">
/*
@licstart  The following is the entire license notice for the
JavaScript code in this tag.

Copyright (C) 2012-2020 Free Software Foundation, Inc.

The JavaScript code in this tag is free software: you can
redistribute it and/or modify it under the terms of the GNU
General Public License (GNU GPL) as published by the Free Software
Foundation, either version 3 of the License, or (at your option)
any later version.  The code is distributed WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE.  See the GNU GPL for more details.

As additional permission under GNU GPL version 3 section 7, you
may distribute non-source (e.g., minimized or compacted) forms of
that code without the copy of the GNU GPL normally required by
section 4, provided you include this license notice and a URL
through which recipients can access the Corresponding Source.


@licend  The above is the entire license notice
for the JavaScript code in this tag.
*/
<!--/*--><![CDATA[/*><!--*/
 function CodeHighlightOn(elem, id)
 {
   var target =3D document.getElementById(id);
   if(null !=3D target) {
     elem.cacheClassElem =3D elem.className;
     elem.cacheClassTarget =3D target.className;
     target.className =3D "code-highlighted";
     elem.className   =3D "code-highlighted";
   }
 }
 function CodeHighlightOff(elem, id)
 {
   var target =3D document.getElementById(id);
   if(elem.cacheClassElem)
     elem.className =3D elem.cacheClassElem;
   if(elem.cacheClassTarget)
     target.className =3D elem.cacheClassTarget;
 }
/*]]>*///-->
</script>
</head>
<body>
<div id=3D"content">
<h1 class=3D"title">OCaml Weekly News</h1>
<p>
<a href=3D"http://alan.petitepomme.net/cwn/2020.12.08.html">Previous Week</=
a> <a href=3D"http://alan.petitepomme.net/cwn/index.html">Up</a> <a href=3D=
"http://alan.petitepomme.net/cwn/2020.12.22.html">Next Week</a>
</p>

<p>
Hello
</p>

<p>
Here is the latest OCaml Weekly News, for the week of December 08 to 15, 20=
20.
</p>

<div id=3D"table-of-contents">
<h2>Table of Contents</h2>
<div id=3D"text-table-of-contents">
<ul>
<li><a href=3D"#1">MirageOS 3.10 released</a></li>
<li><a href=3D"#2">Exception vs Result</a></li>
<li><a href=3D"#3">Release: scikit-learn, Numpy, Scipy for OCaml, 0.3.1</a>=
</li>
<li><a href=3D"#4">OCaml 4.10.2</a></li>
<li><a href=3D"#5">BAP 2.2.0 Release</a></li>
<li><a href=3D"#6">Liquidshop 1.0, Jan. 17th and 18th, 2021</a></li>
<li><a href=3D"#7">Opium 0.20.0</a></li>
<li><a href=3D"#8">Set up OCaml 1.1.5</a></li>
<li><a href=3D"#9">Other OCaml News</a></li>
<li><a href=3D"#org7ffc721">Old CWN</a></li>
</ul>
</div>
</div>


<div id=3D"outline-container-org9352136" class=3D"outline-2">
<h2 id=3D"1">MirageOS 3.10 released</h2>
<div class=3D"outline-text-2" id=3D"text-1">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-mirageos-3-10-released/=
6941/1">https://discuss.ocaml.org/t/ann-mirageos-3-10-released/6941/1</a>
</p>
</div>

<div id=3D"outline-container-org56af145" class=3D"outline-3">
<h3 id=3D"org56af145">Hannes Mehnert announced</h3>
<div class=3D"outline-text-3" id=3D"text-org56af145">
<p>
we're pleased to announce MirageOS 3.10:
</p>

<p>
IPv6 and dual (IPv4 and IPv6) stack support <a href=3D"https://github.com/m=
irage/mirage/pull/1187">https://github.com/mirage/mirage/pull/1187</a>
<a href=3D"https://github.com/mirage/mirage/issues/1190">https://github.com=
/mirage/mirage/issues/1190</a>
</p>

<p>
Since a long time, IPv6 code was around in our TCP/IP stack (thanks to @noj=
b who developed it in 2014).
Some months ago, @hannesm and @MagnusS got excited to use it. After we mana=
ged to fix some bugs and add
some test cases, and writing more code to setup IPv6-only and dual stacks, =
we are eager to share this
support for MirageOS in a released version. We expect there to be bugs ling=
ering around, but duplicate
address detection (neighbour solicitation and advertisements) has been impl=
emented, and (unless
"&#x2013;accept-router-advertisement=3Dfalse") router advertisements are de=
coded and used to configure the IPv6
part of the stack. Configuring a static IPv6 address is also possible (with
"&#x2013;ipv6=3D2001::42/64").
</p>

<p>
While at it, we unified the boot arguments between the different targets: n=
amely, on Unix (when using
the socket stack), you can now pass "&#x2013;ipv4=3D127.0.0.1/24" to the sa=
me effect as the direct stack: only
listen on 127.0.0.1 (the subnet mask is ignored for the Unix socket stack).
</p>

<p>
A dual stack unikernel has "&#x2013;ipv4-only=3DBOOL" and "&#x2013;ipv6-onl=
y=3DBOOL" parameters, so a unikernel binary
could support both Internet Protocol versions, while the operator can decid=
e which protocol version to
use. I.e. now there are both development-time (stackv4 vs stackv6 vs stackv=
4v6) choices, as well as the
run-time choice (via boot parameter).
</p>

<p>
I'm keen to remove the stackv4 &amp; stackv6 in future versions, and always=
 develop with dual stack
(leaving it to configuration &amp; startup time to decide whether to enable=
 ipv4 and ipv6).
</p>

<p>
Please also note that the default IPv4 network configuration no longer uses=
 10.0.0.1 as default gateway
(since there was no way to unset the default gateway <a href=3D"https://git=
hub.com/mirage/mirage/issues/1147">https://github.com/mirage/mirage/issues/=
1147</a>).
</p>

<p>
For unikernel developers, there are some API changes in the Mirage module
</p>
<ul class=3D"org-ul">
<li>New "v4v6" types for IP protocols and stacks</li>
<li>The ipv6_config record was adjusted in the same fashion as the ipv4_con=
fig type: it is now a record of a network (V6.Prefix.t) and gateway (V6.t o=
ption)</li>
</ul>

<p>
Some parts of the Mirage_key module were unified as well:
</p>
<ul class=3D"org-ul">
<li>Arp.ip_address is available (for a dual Ipaddr.t)</li>
<li>Arg.ipv6_address replaces Arg.ipv6 (for an Ipaddr.V6.t)</li>
<li>Arg.ipv6 replaces Arg.ipv6_prefix (for a Ipaddr.V6.Prefix.t)</li>
<li>V6.network and V6.gateway are available, mirroring the V4 submodule</li>
</ul>

<p>
If you're ready to experiment with the dual stack: below is a diff for our =
basic network example (from
mirage-skeleton/device-usage/network) replacing IPv4 with a dual stack, and=
 the tlstunnel unikernel
commit
<a href=3D"https://github.com/roburio/tlstunnel/commit/2cb3e5aa11fca4b48bb5=
24f3c0dbb754a6c8739b">https://github.com/roburio/tlstunnel/commit/2cb3e5aa1=
1fca4b48bb524f3c0dbb754a6c8739b</a>
changed tlstunnel from IPv4 stack to dual stack.
</p>

<div class=3D"org-src-container">
<pre class=3D"src src-diff"><span style=3D"background-color: #d9d9d9;">diff=
 --git a/device-usage/network/config.ml b/device-usage/network/config.ml</s=
pan>
<span style=3D"background-color: #d9d9d9;">index c425edb..eabc9d6 100644</s=
pan>
<span style=3D"background-color: #d9d9d9;">--- </span><span style=3D"backgr=
ound-color: #bfbfbf; font-weight: bold;">a/device-usage/network/config.ml</=
span>
<span style=3D"background-color: #d9d9d9;">+++ </span><span style=3D"backgr=
ound-color: #bfbfbf; font-weight: bold;">b/device-usage/network/config.ml</=
span>
<span style=3D"background-color: #d9d9d9;">@@ -4,9 +4,9 @@</span><span styl=
e=3D"background-color: #d9d9d9;"> let port =3D</span>
   let doc =3D Key.Arg.info ~doc:"The TCP port on which to listen for
incoming connections." ["port"] in
   Key.(create "port" Arg.(opt int 8080 doc))

<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">let main =3D foreign ~keys:[Key.abstract=
 port] "Unikernel.Main" (stackv4</span>
@-&gt; job)
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">let main =3D foreign ~keys:[Key.abstract=
 port] "Unikernel.Main"</span>
(stackv4v6 @-&gt; job)

<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">let stack =3D generic_stackv4 default_ne=
twork</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">let stack =3D generic_stackv4</span><spa=
n style=3D"background-color: #bbffbb;">v6</span><span style=3D"background-c=
olor: #eeffee;"> default_network</span>

 let () =3D
   register "network" [
<span style=3D"background-color: #d9d9d9;">diff --git a/device-usage/networ=
k/unikernel.ml</span>
b/device-usage/network/unikernel.ml
<span style=3D"background-color: #d9d9d9;">index 5d29111..1bf1228 100644</s=
pan>
<span style=3D"background-color: #d9d9d9;">--- </span><span style=3D"backgr=
ound-color: #bfbfbf; font-weight: bold;">a/device-usage/network/unikernel.m=
l</span>
<span style=3D"background-color: #d9d9d9;">+++ </span><span style=3D"backgr=
ound-color: #bfbfbf; font-weight: bold;">b/device-usage/network/unikernel.m=
l</span>
<span style=3D"background-color: #d9d9d9;">@@ -1,19 +1,19 @@</span>
 open Lwt.Infix

<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">module Main (S: Mirage_stack.V4) =3D str=
uct</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">module Main (S: Mirage_stack.V4V6) =3D s=
truct</span>

   let start s =3D
     let port =3D Key_gen.port () in
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">    S.listen_tcpv4 s ~port (fun flow -&g=
t;</span>
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">        let dst, dst_port =3D S.TCPV4.ds=
t flow in</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">    S.listen_tcp s ~port (fun flow -&gt;=
</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">        let dst, dst_port =3D S.TCP.dst =
flow in</span>
         Logs.info (fun f -&gt; f "new tcp connection from IP %s on port %d"
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">                  (Ipaddr.V4.to_string d=
st) dst_port);</span>
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">        S.TCPV4.read flow &gt;&gt;=3D fu=
nction</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">                  (Ipaddr.to_string dst)=
 dst_port);</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">        S.TCP.read flow &gt;&gt;=3D func=
tion</span>
         | Ok `Eof -&gt; Logs.info (fun f -&gt; f "Closing connection!");
Lwt.return_unit
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">        | Error e -&gt; Logs.warn (fun f=
 -&gt; f "Error reading data from</span>
established connection: %a" S.TCPV4.pp_error e); Lwt.return_unit
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">        | Error e -&gt; Logs.warn (fun f=
 -&gt; f "Error reading data from</span>
established connection: %a" S.TCP.pp_error e); Lwt.return_unit
         | Ok (`Data b) -&gt;
           Logs.debug (fun f -&gt; f "read: %d bytes:\n%s" (Cstruct.len b)
(Cstruct.to_string b));
<span style=3D"color: #aa2222; background-color: #ffeeee;">-</span><span st=
yle=3D"background-color: #ffeeee;">          S.TCPV4.close flow</span>
<span style=3D"color: #22aa22; background-color: #eeffee;">+</span><span st=
yle=3D"background-color: #eeffee;">          S.TCP.close flow</span>
       );

     S.listen s
</pre>
</div>

<p>
Other bug fixes include <a href=3D"https://github.com/mirage/mirage/issues/=
1188">https://github.com/mirage/mirage/issues/1188</a> (in
<a href=3D"https://github.com/mirage/mirage/pull/1201">https://github.com/m=
irage/mirage/pull/1201</a>) and adapt to charrua 1.3.0 and arp 2.3.0 changes
(<a href=3D"https://github.com/mirage/mirage/pull/1199">https://github.com/=
mirage/mirage/pull/1199</a>).
</p>
</div>
</div>
</div>




<div id=3D"outline-container-orgd7f781b" class=3D"outline-2">
<h2 id=3D"2">Exception vs Result</h2>
<div class=3D"outline-text-2" id=3D"text-2">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/exception-vs-result/6931/18=
">https://discuss.ocaml.org/t/exception-vs-result/6931/18</a>
</p>
</div>

<div id=3D"outline-container-orgdf22267" class=3D"outline-3">
<h3 id=3D"orgdf22267">Continuing this thread, Vladimir Keleshev announced</=
h3>
<div class=3D"outline-text-3" id=3D"text-orgdf22267">
<p>
A bit late to the party, but here's an overview of error handling methods t=
hat I did a while ago:
</p>

<p>
<a href=3D"https://keleshev.com/composable-error-handling-in-ocaml">Composa=
ble Error Handling in OCaml
(keleshev.com)</a>
</p>

<p>
It compares the following approaches:
</p>
<ul class=3D"org-ul">
<li>Exceptions</li>
<li>Result type with strings for errors</li>
<li>Result type with custom variants for errors</li>
<li>Result type with polymorphic variants for errors</li>
</ul>
</div>
</div>
</div>




<div id=3D"outline-container-orgb615015" class=3D"outline-2">
<h2 id=3D"3">Release: scikit-learn, Numpy, Scipy for OCaml, 0.3.1</h2>
<div class=3D"outline-text-2" id=3D"text-3">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-release-scikit-learn-nu=
mpy-scipy-for-ocaml-0-3-1/6942/1">https://discuss.ocaml.org/t/ann-release-s=
cikit-learn-numpy-scipy-for-ocaml-0-3-1/6942/1</a>
</p>
</div>

<div id=3D"outline-container-org51b0263" class=3D"outline-3">
<h3 id=3D"org51b0263">Ronan Le Hy announced</h3>
<div class=3D"outline-text-3" id=3D"text-org51b0263">
<p>
I've just released an update of OCaml wrappers for scikit-learn:
</p>
<ul class=3D"org-ul">
<li>documentation: <a href=3D"https://lehy.github.io/ocaml-sklearn/">https:=
//lehy.github.io/ocaml-sklearn/</a></li>
<li>code: <a href=3D"https://github.com/lehy/ocaml-sklearn">https://github.=
com/lehy/ocaml-sklearn</a></li>
<li><code>opam install sklearn</code></li>
</ul>

<p>
These bindings also come with bindings for Numpy (<code>opam install np</co=
de>) and Scipy (<code>opam install scipy</code>).
</p>

<p>
Scikit-learn is all of these things:
</p>
<ul class=3D"org-ul">
<li>Simple and efficient tools for predictive data analysis</li>
<li>Accessible to everybody, and reusable in various contexts</li>
<li>Built on NumPy, SciPy, and matplotlib</li>
<li>Open source, commercially usable - BSD license</li>
</ul>

<p>
Scikit-learn is robust, well-engineered and covers most basic machine learn=
ing use cases. As a
professional data scientist I use it extensively from Python. I built these=
 wrappers because I felt
challenged by my friend @UnixJunkie's funny R wrappers.
</p>

<p>
I don't depend personally on these packages and maintain/improve them witho=
ut any guarantees. They have
many unpolished corners. However, they have tests and I don't expect them t=
o add too many bugs to
scikit-learn. Contributions and bug reports are welcome (but be aware that =
the bindings are generated
from a big hairy Python script).
</p>

<p>
Many thanks to everybody involved in opam!
</p>
</div>
</div>
</div>




<div id=3D"outline-container-org8129f0b" class=3D"outline-2">
<h2 id=3D"4">OCaml 4.10.2</h2>
<div class=3D"outline-text-2" id=3D"text-4">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-ocaml-4-10-2/6945/1">ht=
tps://discuss.ocaml.org/t/ann-ocaml-4-10-2/6945/1</a>
</p>
</div>

<div id=3D"outline-container-org48e971d" class=3D"outline-3">
<h3 id=3D"org48e971d">octachron announced</h3>
<div class=3D"outline-text-3" id=3D"text-org48e971d">
<p>
The OCaml team has the pleasure of celebrating the birthday of Grace Hopper=
 by announcing
the release of OCaml version 4.10.2.
</p>

<p>
This exceptional release makes OCaml 4.10 available on the new macOS/arm64 =
platform,
and fixes some compatibility issues for the mingw64 and FreeBSD/amd64 platf=
orm.
</p>

<p>
If OCaml 4.10.1 already works on your platform of choice, this release shou=
ld be
completely transparent to you (and can be safely ignored).
</p>

<p>
Note that those fixes were backported from OCaml 4.12: further improvement =
to the support
of the macOS/arm64 platform will happen on the 4.12 branch.
</p>

<p>
The release is available as a set of OPAM switches,
and as a source download here:
</p>

<p>
<a href=3D"https://github.com/ocaml/ocaml/archive/4.10.2.tar.gz">https://gi=
thub.com/ocaml/ocaml/archive/4.10.2.tar.gz</a> <br />
<a href=3D"https://caml.inria.fr/pub/distrib/ocaml-4.10/">https://caml.inri=
a.fr/pub/distrib/ocaml-4.10/</a>
</p>
</div>

<div id=3D"outline-container-org79c5aa1" class=3D"outline-4">
<h4 id=3D"org79c5aa1">OCaml 4.10.2</h4>
<div class=3D"outline-text-4" id=3D"text-org79c5aa1">
<ul class=3D"org-ul">
<li><a href=3D"https://github.com/ocaml/ocaml/issues/9938">9938</a>, <a hre=
f=3D"https://github.com/ocaml/ocaml/issues/9939">9939</a>: Define __USE_MIN=
GW_ANSI_STDIO=3D0 for the mingw-w64 ports to prevent their C99-compliant sn=
printf conflicting with ours. (David Allsopp, report by Michael Soegtrop, r=
eview by Xavier Leroy)</li>
</ul>
</div>

<ul class=3D"org-ul">
<li><a id=3D"org0629733"></a>Supported platforms:<br />
<div class=3D"outline-text-5" id=3D"text-org0629733">
<ul class=3D"org-ul">
<li><a href=3D"https://github.com/ocaml/ocaml/issues/9699">9699</a>, <a hre=
f=3D"https://github.com/ocaml/ocaml/issues/10026">10026</a>: add support fo=
r iOS and macOS on ARM 64 bits Backported from OCaml 4.12.0 (GitHub user @E=
duardoRFS, review by Xavier Leroy, Nicol=C3=A1s Ojeda B=C3=A4r and Anil Mad=
havapeddy, additional testing by Michael Schmidt)</li>
</ul>
</div>
</li>

<li><a id=3D"org05f1bb4"></a>Code generation and optimization<br />
<div class=3D"outline-text-5" id=3D"text-org05f1bb4">
<ul class=3D"org-ul">
<li><a href=3D"https://github.com/ocaml/ocaml/issues/9752">9752</a>, <a hre=
f=3D"https://github.com/ocaml/ocaml/issues/10026">10026</a>: Revised handli=
ng of calling conventions for external C functions. Provide a more precise =
description of the types of unboxed arguments, so that the ARM64 iOS/macOS =
calling conventions can be honored. Backported from OCaml 4.12.0 (Xavier Le=
roy, review by Mark Shinwell and Github user @EduardoRFS)</li>

<li><a href=3D"https://github.com/ocaml/ocaml/issues/9969">9969</a>, <a hre=
f=3D"https://github.com/ocaml/ocaml/issues/9981">9981</a>: Added mergeable =
flag tqo ELF sections containing mergeable constants.  Fixes compatibility =
with the integrated assembler in clang 11.0.0. Backported from OCaml 4.12.0=
 (Jacob Young, review by Nicol=C3=A1s Ojeda B=C3=A4r)</li>
</ul>
</div>
</li>
</ul>
</div>
</div>


<div id=3D"outline-container-org94f16c9" class=3D"outline-3">
<h3 id=3D"org94f16c9">Anil Madhavapeddy</h3>
<div class=3D"outline-text-3" id=3D"text-org94f16c9">
<p>
There is also a <a href=3D"https://github.com/ocaml/opam/releases/tag/2.0.7=
">macos/arm64 binary of opam</a>
available from the releases page for your convenience, and opam repository =
has been updated to
understand the new tier-1 constraints imposed by macos/arm (i.e. the only w=
orking compilers there are
4.10.2 and 4.12.0~dev, and <code>opam init</code> will now do the right thi=
ng).
</p>

<p>
There will be a number of packages that are broken due to the shift to <cod=
e>/opt/homebrew</code> from
<code>/usr/local</code> for Homebrew/ARM (due to the need to keep them simu=
ltaneously installed on the same Mac),
so please feel free to submit PRs to opam-repository to fix this stuff.
</p>

<p>
We'll shortly have Mac (both Intel and ARM) testing up and running on opam-=
repository, so CI will catch
up with reality once more, thanks to furious hacking by @patricoferris to e=
xtend our ocurrent-based CI
infrastructure to support the unique vagaries of the Mac environment (notab=
ly, a total lack of native
containers).  We have it working locally, and are just upstreaming it now.
</p>
</div>
</div>
</div>




<div id=3D"outline-container-orgb648fd0" class=3D"outline-2">
<h2 id=3D"5">BAP 2.2.0 Release</h2>
<div class=3D"outline-text-2" id=3D"text-5">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-bap-2-2-0-release/6950/=
1">https://discuss.ocaml.org/t/ann-bap-2-2-0-release/6950/1</a>
</p>
</div>

<div id=3D"outline-container-org94e8e50" class=3D"outline-3">
<h3 id=3D"org94e8e50">Ivan Gotovchits announced</h3>
<div class=3D"outline-text-3" id=3D"text-org94e8e50">
<p>
We are proud to announce the 2.2.0 release of the Carnegie Mellon Universit=
y <a href=3D"https://github.com/BinaryAnalysisPlatform/bap">Binary Analysis
Platform</a>. BAP is the framework and toolkit for analyzing programs in th=
eir machine code
representation. This update has a lot of <a href=3D"https://github.com/Bina=
ryAnalysisPlatform/bap/releases/tag/v2.2.0">new features</a> despite that o=
riginally it was more as a
maintenance version. Special thanks to @XVilka and <a href=3D"https://githu=
b.com/Phosphorus15">@Phosphorus15</a>  for contributing Thumb/ThumbV2
lifter and radare2 integration. We would also like to thank <a href=3D"http=
s://forallsecure.com/">ForAllSecure</a> for open-sourcing and
contributing to us their x86 floating-point lifter. The new version of BAP =
is also much more efficient
and we now have a much better symbolization facility (so we're no longer re=
ally dependent on the
presence of external tools). Another nice addition is a new REPL powered by=
 <a href=3D"https://github.com/ocaml-community/ocaml-linenoise">ocaml-linen=
oise</a>, see the
demo below.
</p>

<p>
<a href=3D"https://asciinema.org/a/358996">https://asciinema.org/a/358996</=
a>
</p>
</div>
</div>
</div>




<div id=3D"outline-container-org5e3d4af" class=3D"outline-2">
<h2 id=3D"6">Liquidshop 1.0, Jan. 17th and 18th, 2021</h2>
<div class=3D"outline-text-2" id=3D"text-6">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-liquidshop-1-0-jan-17th=
-18th-2021/6951/1">https://discuss.ocaml.org/t/ann-liquidshop-1-0-jan-17th-=
18th-2021/6951/1</a>
</p>
</div>

<div id=3D"outline-container-org012ae6f" class=3D"outline-3">
<h3 id=3D"org012ae6f">Romain Beauxis announced</h3>
<div class=3D"outline-text-3" id=3D"text-org012ae6f">
<p>
We are happy to announce that we'll be holding Liquidshop 1.0 these coming =
Jan. 17th &amp; 18th, our first
ever (online) conference and workshops on liquidsoap and other related tech=
nologies and projects!
</p>

<p>
Liquidsoap is a statically typed scripting language with specialized primit=
ives and operators for
creating media streams used for media processing, online streaming and a lo=
t more. It is written in
OCaml and has been maintained for over a decade now.
</p>

<p>
We will have 3 different tracks for the event, namely:
</p>
<ul class=3D"org-ul">
<li>Showcases: short presentations about a website / radio / art installati=
on that you built using Liquidsoap or other related tools</li>
<li>Tech talks: in-depth presentation of a technology related to Liquidsoap=
 and streaming in general</li>
<li>Workshops: user-centered freeform discussions about your project or iss=
ues around Liquidsoap and streaming</li>
</ul>

<p>
If you're interested to participate, wether as an attendee or a presenter, =
make sure to register via
our website at: <a href=3D"http://www.liquidsoap.info/liquidshop/">http://w=
ww.liquidsoap.info/liquidshop/</a> or directly via the form available at:
<a href=3D"https://forms.gle/HdGNLz5qM3HVU1ub7">https://forms.gle/HdGNLz5qM=
3HVU1ub7</a>
</p>

<p>
We are super excited for this event. We have already secured a couple of in=
teresting speakers and we
would love to get to know the community better, see what y'all are doing wi=
th liquidsoap and other
releated projects, community radios, live video, weird installations, etc. =
and meet with everyone.
</p>

<p>
Also, if you have any suggestion about the best technical solutions to orga=
nize such an event, we'd be
happy to hear about them.
</p>

<p>
Finally, if any of y'all have some specific topics to discuss and would lik=
e to learn more about
liquidsoap, this will be a great place to connect!
</p>
</div>
</div>
</div>




<div id=3D"outline-container-orge09840a" class=3D"outline-2">
<h2 id=3D"7">Opium 0.20.0</h2>
<div class=3D"outline-text-2" id=3D"text-7">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-opium-0-20-0/6955/1">ht=
tps://discuss.ocaml.org/t/ann-opium-0-20-0/6955/1</a>
</p>
</div>

<div id=3D"outline-container-orgf736e70" class=3D"outline-3">
<h3 id=3D"orgf736e70">Thibaut Mattio announced</h3>
<div class=3D"outline-text-3" id=3D"text-orgf736e70">
<p>
I'm pleased to announce a new version of <a href=3D"https://github.com/rgri=
nberg/opium">Opium</a> web framework
(0.20.0) is available on Opam.
</p>

<p>
Here's the changelog:
</p>
</div>

<div id=3D"outline-container-orge97cb4c" class=3D"outline-4">
<h4 id=3D"orge97cb4c">Added</h4>
<div class=3D"outline-text-4" id=3D"text-orge97cb4c">
<ul class=3D"org-ul">
<li>New <code>Auth</code> module to work with <code>Authorization</code> he=
ader (<a href=3D"https://github.com/rgrinberg/opium/pull/238">#238</a>)</li>

<li>New <code>basic_auth</code> middleware to protect handlers with a <code=
>Basic</code> authentication method (<a href=3D"https://github.com/rgrinber=
g/opium/pull/238">#238</a>)</li>

<li>New <code>Response.of_file</code> API for conveniently creating a respo=
nse of a file (<a href=3D"https://github.com/rgrinberg/opium/pull/244">#244=
</a>)</li>

<li>Add a package <code>opium-graphql</code> to easily create GraphQL serve=
r with Opium (<a href=3D"https://github.com/rgrinberg/opium/pull/235">#235<=
/a>)</li>

<li>Add a function <code>App.run_multicore</code> that uses pre-forking and=
 spawns multiple processes that will handle incoming requests (<a href=3D"h=
ttps://github.com/rgrinberg/opium/pull/239">#239</a>)</li>
</ul>
</div>
</div>

<div id=3D"outline-container-org1841433" class=3D"outline-4">
<h4 id=3D"org1841433">Fixed</h4>
<div class=3D"outline-text-4" id=3D"text-org1841433">
<ul class=3D"org-ul">
<li>Fix reading cookie values when multiple cookies are present in <code>Co=
okie</code> header (<a href=3D"https://github.com/rgrinberg/opium/pull/246"=
>#246</a>)</li>
</ul>

<p>
Happy hacking :slight_smile:
</p>
</div>
</div>
</div>
</div>




<div id=3D"outline-container-orgf095ce4" class=3D"outline-2">
<h2 id=3D"8">Set up OCaml 1.1.5</h2>
<div class=3D"outline-text-2" id=3D"text-8">
<p>
Archive: <a href=3D"https://discuss.ocaml.org/t/ann-set-up-ocaml-1-1-5/6971=
/1">https://discuss.ocaml.org/t/ann-set-up-ocaml-1-1-5/6971/1</a>
</p>
</div>

<div id=3D"outline-container-org34fadbf" class=3D"outline-3">
<h3 id=3D"org34fadbf">Sora Morimoto announced</h3>
<div class=3D"outline-text-3" id=3D"text-org34fadbf">
<p>
This release reduces build time by up to 2 minutes by exporting modified <c=
ode>OPAMJOBS</code> environment
variable.
</p>

<p>
<a href=3D"https://github.com/avsm/setup-ocaml/releases/tag/v1.1.5">https:/=
/github.com/avsm/setup-ocaml/releases/tag/v1.1.5</a>
</p>
</div>
</div>
</div>




<div id=3D"outline-container-org5b1c1a5" class=3D"outline-2">
<h2 id=3D"9">Other OCaml News</h2>
<div class=3D"outline-text-2" id=3D"text-9">
</div>
<div id=3D"outline-container-org4186cf5" class=3D"outline-3">
<h3 id=3D"org4186cf5">From the ocamlcore planet blog</h3>
<div class=3D"outline-text-3" id=3D"text-org4186cf5">
<p>
Here are links from many OCaml blogs aggregated at <a href=3D"http://ocaml.=
org/community/planet/">OCaml Planet</a>.
</p>

<ul class=3D"org-ul">
<li><a href=3D"https://www.ocamlpro.com/2020/12/01/memthol-exploring-progra=
m-profiling/">Memthol: exploring program profiling</a></li>
<li><a href=3D"https://blog.janestreet.com/growing-the-hardcaml-toolset-ind=
ex/">Growing the Hardcaml toolset</a></li>
<li><a href=3D"https://rescript-lang.org/blog/editor-support-release-1-0"> =
Editor Plugin for VSCode and Vim Officially Released!</a></li>
<li><a href=3D"https://blog.janestreet.com/announcing-our-market-prediction=
-kaggle-competition-index/">Announcing Our Market Prediction Kaggle Competi=
tion</a></li>
<li><a href=3D"http://math.andrej.com/2020/11/24/homotopy-io/">Every proof =
assistant: introducing homotopy.io =E2=80=93 a proof assistant for geometri=
cal higher category theory</a></li>
</ul>
</div>
</div>
</div>




<div id=3D"outline-container-org7ffc721" class=3D"outline-2">
<h2 id=3D"org7ffc721">Old CWN</h2>
<div class=3D"outline-text-2" id=3D"text-org7ffc721">
<p>
If you happen to miss a CWN, you can <a href=3D"mailto:alan.schmitt at polytec=
hnique.org">send me a message</a> and I'll mail it to you, or go take a loo=
k at <a href=3D"http://alan.petitepomme.net/cwn/">the archive</a> or the <a=
 href=3D"http://alan.petitepomme.net/cwn/cwn.rss">RSS feed of the archives<=
/a>.
</p>

<p>
If you also wish to receive it every week by mail, you may subscribe <a hre=
f=3D"http://lists.idyll.org/listinfo/caml-news-weekly/">online</a>.
</p>

<div class=3D"authorname">
<p>
<a href=3D"http://alan.petitepomme.net/">Alan Schmitt</a>
</p>

</div>
</div>
</div>
</div>
</body>
</html>


--=-=-=--



More information about the caml-news-weekly mailing list