The actual error will be much higher; you are just seeing diagnostics at the end. Could you paste the full output? (I doubt you can paste that much in discuss.ocaml.org but https://github.com/diskuv/dkml-installer-ocaml/issues/new will work).
Alternatively, if you have the time, could you consider trying out the newer Windows installation “opam 2.2” instead? That would be:
-
Open Add or remove programs from Windows Search (type Windows key and then start typing “Add or remove programs”), and then uninstall
DkML Native
; you can ignore any failures. You can now close “Add or remove programs”. -
Open PowerShell and run the following:
if (Test-Path "$env:LOCALAPPDATA\opam") { del -force - recurse "$env:LOCALAPPDATA\opam" }
-
Follow the steps in [ANN] opam 2.2.0 is out!. After that Introduction to opam Switches · OCaml Documentation and Your First OCaml Program · OCaml Documentation should be the right tutorials to continue learning.