From d5a40572518768d0026f1a9e622a452ab45a7d0f Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 15:43:07 +0800 Subject: [PATCH 01/56] opam.export: bump to use ocaml 5.2.1 & core 0.17 packages --- opam.export | 424 +++++++++++++++++++++++++++++----------------------- 1 file changed, 237 insertions(+), 187 deletions(-) diff --git a/opam.export b/opam.export index 4374e7b82e96..ed4718efa5bb 100644 --- a/opam.export +++ b/opam.export @@ -1,90 +1,105 @@ opam-version: "2.0" -compiler: ["ocaml-base-compiler.4.14.2"] +compiler: [ + "base-bigarray.base" + "base-domains.base" + "base-nnp.base" + "base-threads.base" + "base-unix.base" + "ocaml.5.2.1" + "ocaml-base-compiler.5.2.1" + "ocaml-config.3" + "ocaml-options-vanilla.1" +] roots: [ - "alcotest.1.1.0" - "alcotest-async.1.1.0" + "alcotest.1.9.1" + "alcotest-async.1.9.1" "angstrom.0.15.0" - "bisect_ppx.2.8.1" + "bisect_ppx.2.8.3" "bitstring.4.1.0" "camlp-streams.5.0.1" - "camlp4.4.14+1" + "camlp4.5.2" "capnp.3.4.0" "check_opam_switch.~dev" - "core_extended.v0.14.0" - "extlib.1.7.8" - "graphql-async.0.13.0" - "graphql-cohttp.0.13.0" - "graphql-lwt.0.13.0" + "core_extended.v0.17.0" + "extlib.1.8.0" + "graphql-async.0.17.0" + "graphql-cohttp.0.17.0" "graphql_ppx.1.2.2" - "js_of_ocaml.4.0.0" - "js_of_ocaml-ppx.4.0.0" - "js_of_ocaml-toplevel.4.0.0" + "js_of_ocaml.5.8.1" + "js_of_ocaml-ppx.5.8.1" + "js_of_ocaml-toplevel.5.8.1" "lmdb.1.0" "menhir.20210419" - "merlin.4.5-414" - "ocaml-base-compiler.4.14.2" - "ocamlformat.0.20.1" - "ocamlgraph.1.8.8" - "ocp-browser.1.3.3" - "ocp-indent.1.7.0" - "odoc.2.1.1" + "merlin.5.3-502" + "ocaml-base-compiler.5.2.1" + "ocaml-lsp-server.1.21.0" + "ocamlformat.0.28.1" + "ocamlgraph.2.2.0" + "ocp-browser.1.4.0" + "ocp-indent.1.8.0" + "odoc.3.1.0" "ppx_bitstring.4.1.0" - "ppx_deriving.5.2.1" - "ppx_deriving_yojson.3.6.1" - "ppx_optcomp.v0.14.3" + "ppx_deriving.6.0.3" + "ppx_deriving_yojson.3.9.1" + "ppx_optcomp.v0.17.0" "prometheus.1.1" - "qcheck.0.20" - "qcheck-alcotest.0.20" - "re2.v0.14.0" - "rocks.0.2.0" + "qcheck.0.27" + "qcheck-alcotest.0.27" + "re2.v0.17.0" + "rocks.0.3.0" "rocksdb_stubs.10.5.1" - "rpc_parallel.v0.14.0" - "sexp_diff_kernel.v0.14.0" - "sodium.dev" - "utop.2.9.1" - "yojson.1.7.0" + "rpc_parallel.v0.17.0" + "sexp_diff.v0.17.0" + "sodium.5.2.1" + "utop.2.16.0" + "yojson.2.0.0" ] installed: [ - "alcotest.1.1.0" - "alcotest-async.1.1.0" + "alcotest.1.9.1" + "alcotest-async.1.9.1" "angstrom.0.15.0" "asetmap.0.8.1" "astring.0.8.5" - "async.v0.14.0" - "async_kernel.v0.14.0" - "async_rpc_kernel.v0.14.0" - "async_ssl.v0.14.0-o1labs" - "async_unix.v0.14.0" - "base.v0.14.3" + "async.v0.17.0" + "async_kernel.v0.17.0+jobtrace" + "async_log.v0.17.0" + "async_rpc_kernel.v0.17.0" + "async_ssl.v0.17.0-1" + "async_unix.v0.17.0" + "base.v0.17.3" "base-bigarray.base" "base-bytes.base" + "base-domains.base" + "base-nnp.base" "base-threads.base" "base-unix.base" "base58.0.1.0" "base64.3.4.0" - "base_bigstring.v0.14.0" - "base_quickcheck.v0.14.1" - "bigarray-compat.1.0.0" - "bignum.v0.14.0" + "base_bigstring.v0.17.0" + "base_quickcheck.v0.17.0" + "bigarray-compat.1.1.0" + "bignum.v0.17.0" "bigstringaf.0.5.0" - "bin_prot.v0.14.0" - "biniou.1.2.1" - "bisect_ppx.2.8.1" + "bin_prot.v0.17.0" + "biniou.1.2.2" + "bisect_ppx.2.8.3" "bitstring.4.1.0" "camlp-streams.5.0.1" - "camlp4.4.14+1" - "camomile.1.0.2" + "camlp4.5.2" + "camomile.2.0.0" + "capitalization.v0.17.0" "capnp.3.4.0" "caqti.2.0.1" "caqti-async.2.0.1" "caqti-driver-postgresql.2.0.1" - "charInfo_width.1.1.0" + "charInfo_width.2.0.0" "check_opam_switch.~dev" - "cmdliner.1.0.3" - "cohttp.5.0.0" - "cohttp-async.5.0.0" - "conduit.4.0.0" - "conduit-async.4.0.0" + "chrome-trace.3.20.2" + "cmdliner.1.3.0" + "cohttp.6.1.1" + "cohttp-async.6.1.1" + "conduit.8.0.0" + "conduit-async.8.0.0" "conf-g++.1.0" "conf-gmp.5" "conf-libbz2.1" @@ -97,181 +112,216 @@ installed: [ "conf-postgresql.2" "conf-which.1" "conf-zlib.1" - "core.v0.14.1" - "core_bench.v0.14.0" - "core_extended.v0.14.0" - "core_kernel.v0.14.1" - "core_unix.v0.14.0" + "core.v0.17.1" + "core_bench.v0.17.0" + "core_extended.v0.17.0" + "core_kernel.v0.17.0" + "core_unix.v0.17.1" "cppo.1.6.7" "cppo_ocamlbuild.1.6.7" "crunch.3.2.0" "csexp.1.5.1" "cstruct.6.0.1" - "ctypes.0.17.1" - "ctypes-foreign.0.4.0" - "digestif.0.9.0" + "ctypes.0.24.0" + "ctypes-foreign.0.24.0" + "delimited_parsing.v0.17.0" + "digestif.1.3.0" "domain-name.0.3.0" - "dot-merlin-reader.4.2" - "dune.3.3.1" - "dune-build-info.3.1.1" - "dune-configurator.2.8.2" - "dune-private-libs.2.6.2" + "dot-merlin-reader.5.3-502" + "dune.3.20.2" + "dune-build-info.3.20.2" + "dune-configurator.3.20.2" + "dune-private-libs.3.20.2" + "dune-rpc.3.20.2" + "dune-site.3.20.2" "duration.0.2.1" - "easy-format.1.3.2" + "dyn.3.20.2" + "easy-format.1.3.4" "either.1.0.0" "eqaf.0.9" - "extlib.1.7.8" - "fieldslib.v0.14.0" - "fix.20201120" - "fmt.0.8.6" + "expect_test_helpers_core.v0.17.0" + "extlib.1.8.0" + "fiber.3.7.0" + "fieldslib.v0.17.0" + "fix.20250919" + "fmt.0.11.0" "fpath.0.7.3" - "graphql.0.13.0" - "graphql-async.0.13.0" - "graphql-cohttp.0.13.0" - "graphql-lwt.0.13.0" - "graphql_parser.0.12.2" + "gel.v0.17.0" + "gen.1.1" + "graphql.0.17.0" + "graphql-async.0.17.0" + "graphql-cohttp.0.17.0" + "graphql_parser.0.14.0" "graphql_ppx.1.2.2" - "incremental.v0.14.0" - "integers.0.4.0" - "ipaddr.5.0.1" - "ipaddr-sexp.5.0.1" - "jane-street-headers.v0.14.0" - "js_of_ocaml.4.0.0" - "js_of_ocaml-compiler.4.0.0" - "js_of_ocaml-ppx.4.0.0" - "js_of_ocaml-toplevel.4.0.0" - "jsonm.1.0.1" - "jst-config.v0.14.1" - "lambda-term.3.1.0" + "http.6.1.1" + "incremental.v0.17.0" + "int_repr.v0.17.0" + "integers.0.7.0" + "ipaddr.5.6.1" + "ipaddr-sexp.5.6.1" + "jane-street-headers.v0.17.0" + "jane_rope.v0.17.0" + "janestreet_lru_cache.v0.17.0" + "js_of_ocaml.5.8.1" + "js_of_ocaml-compiler.5.8.1" + "js_of_ocaml-ppx.5.8.1" + "js_of_ocaml-toplevel.5.8.1" + "jsonm.1.0.2" + "jsonrpc.1.21.0" + "jst-config.v0.17.0" + "lambda-term.3.3.2" "lens.1.2.5" "lmdb.1.0" - "logs.0.7.0" - "lwt.5.4.0" - "lwt-dllist.1.0.1" - "lwt_log.1.1.1" - "lwt_react.1.1.2" - "macaddr.5.0.1" + "logs.0.10.0" + "lsp.1.21.0" + "lwt.5.9.2" + "lwt-dllist.1.1.0" + "lwt_react.1.2.0" + "macaddr.5.6.1" "magic-mime.1.1.2" "menhir.20210419" "menhirLib.20210419" "menhirSdk.20210419" - "merlin.4.5-414" + "merlin.5.3-502" "merlin-extend.0.6.1" + "merlin-lib.5.3-502" "mew.0.1.0" "mew_vi.0.5.0" "minicli.5.0.2" - "mirage-crypto.0.11.0" - "mirage-crypto-ec.0.11.0" - "mirage-crypto-rng.0.11.0" - "mirage-crypto-rng-async.0.11.0" + "mirage-crypto.2.0.2" + "mirage-crypto-ec.2.0.2" + "mirage-crypto-rng.2.0.2" "mmap.1.1.0" - "mtime.2.0.0" - "num.1.1" - "ocaml.4.14.2" - "ocaml-base-compiler.4.14.2" - "ocaml-compiler-libs.v0.12.4" - "ocaml-config.2" - "ocaml-migrate-parsetree.2.3.0" + "mtime.2.1.0" + "num.1.6" + "ocaml.5.2.1" + "ocaml-base-compiler.5.2.1" + "ocaml-compiler-libs.v0.17.0" + "ocaml-config.3" + "ocaml-index.1.1" + "ocaml-lsp-server.1.21.0" "ocaml-options-vanilla.1" "ocaml-syntax-shims.1.0.0" - "ocaml-version.3.4.0" - "ocamlbuild.0.14.0" - "ocamlfind.1.9.3" - "ocamlformat.0.20.1" - "ocamlgraph.1.8.8" - "ocp-browser.1.3.3" - "ocp-indent.1.7.0" - "ocp-index.1.3.3" - "ocplib-endian.1.0" + "ocaml-version.3.5.0" + "ocaml_intrinsics_kernel.v0.17.1" + "ocamlbuild.0.16.1" + "ocamlc-loc.3.20.2" + "ocamlfind.1.9.8" + "ocamlformat.0.28.1" + "ocamlformat-lib.0.28.1" + "ocamlformat-rpc-lib.0.28.1" + "ocamlgraph.2.2.0" + "ocp-browser.1.4.0" + "ocp-indent.1.8.0" + "ocp-index.1.4.0" + "ocplib-endian.1.2" "octavius.1.2.2" - "odoc.2.1.1" - "odoc-parser.1.0.0" + "odoc.3.1.0" + "odoc-parser.3.1.0" "opam-core.2.1.2" "opam-file-format.2.1.4" "opam-format.2.1.2" + "ordering.3.20.2" "ounit2.2.2.6" - "parsexp.v0.14.2" + "parsexp.v0.17.0" "postgresql.5.0.0" - "ppx_assert.v0.14.0" - "ppx_base.v0.14.0" - "ppx_bench.v0.14.1" - "ppx_bin_prot.v0.14.0" + "pp.2.0.0" + "ppx_assert.v0.17.0" + "ppx_base.v0.17.0" + "ppx_bench.v0.17.0" + "ppx_bin_prot.v0.17.0" "ppx_bitstring.4.1.0" - "ppx_cold.v0.14.0" - "ppx_compare.v0.14.0" - "ppx_custom_printf.v0.14.1" + "ppx_cold.v0.17.0" + "ppx_compare.v0.17.0" + "ppx_custom_printf.v0.17.0" "ppx_derivers.1.2.1" - "ppx_deriving.5.2.1" - "ppx_deriving_yojson.3.6.1" - "ppx_enumerate.v0.14.0" - "ppx_expect.v0.14.2" - "ppx_fields_conv.v0.14.2" - "ppx_fixed_literal.v0.14.0" - "ppx_hash.v0.14.0" - "ppx_here.v0.14.0" - "ppx_inline_test.v0.14.1" - "ppx_jane.v0.14.0" - "ppx_js_style.v0.14.1" - "ppx_let.v0.14.0" - "ppx_module_timer.v0.14.0" - "ppx_optcomp.v0.14.3" - "ppx_optional.v0.14.0" - "ppx_pipebang.v0.14.0" - "ppx_sexp_conv.v0.14.3" - "ppx_sexp_message.v0.14.1" - "ppx_sexp_value.v0.14.0" - "ppx_stable.v0.14.1" - "ppx_string.v0.14.1" - "ppx_tools.6.5" - "ppx_typerep_conv.v0.14.2" - "ppx_variants_conv.v0.14.2" - "ppxlib.0.25.0" + "ppx_deriving.6.0.3" + "ppx_deriving_yojson.3.9.1" + "ppx_diff.v0.17.0" + "ppx_disable_unused_warnings.v0.17.0" + "ppx_enumerate.v0.17.0" + "ppx_expect.v0.17.0" + "ppx_fields_conv.v0.17.0" + "ppx_fixed_literal.v0.17.0" + "ppx_globalize.v0.17.0" + "ppx_hash.v0.17.0" + "ppx_here.v0.17.0" + "ppx_ignore_instrumentation.v0.17.0" + "ppx_inline_test.v0.17.0" + "ppx_jane.v0.17.0" + "ppx_js_style.v0.17.0" + "ppx_let.v0.17.0" + "ppx_log.v0.17.0" + "ppx_module_timer.v0.17.0" + "ppx_optcomp.v0.17.0" + "ppx_optional.v0.17.0" + "ppx_pipebang.v0.17.0" + "ppx_sexp_conv.v0.17.0" + "ppx_sexp_message.v0.17.0" + "ppx_sexp_value.v0.17.0" + "ppx_stable.v0.17.0" + "ppx_stable_witness.v0.17.0" + "ppx_string.v0.17.0" + "ppx_string_conv.v0.17.0" + "ppx_tydi.v0.17.0" + "ppx_typerep_conv.v0.17.0" + "ppx_variants_conv.v0.17.0" + "ppx_yojson_conv_lib.v0.17.0" + "ppxlib.0.35.0" + "ppxlib_jane.v0.17.0" "prometheus.1.1" - "protocol_version_header.v0.14.0" - "ptime.0.8.5" - "qcheck.0.20" - "qcheck-alcotest.0.20" - "qcheck-core.0.20" - "qcheck-ounit.0.20" - "re.1.9.0" - "re2.v0.14.0" - "react.1.2.1" + "protocol_version_header.v0.17.0" + "ptime.1.2.0" + "qcheck.0.27" + "qcheck-alcotest.0.27" + "qcheck-core.0.27" + "qcheck-ounit.0.27" + "re.1.10.3" + "re2.v0.17.0" + "react.1.2.2" + "record_builder.v0.17.0" + "regex_parser_intf.v0.17.0" "res.5.0.1" "result.1.5" - "rocks.0.2.0" + "rocks.0.3.0" "rocksdb_stubs.10.5.1" - "rpc_parallel.v0.14.0" + "rpc_parallel.v0.17.0" "rresult.0.6.0" + "sedlex.3.7" "seq.base" - "sexp_diff_kernel.v0.14.0" - "sexplib.v0.14.0" - "sexplib0.v0.14.0" - "sodium.dev" - "spawn.v0.13.0" - "splittable_random.v0.14.0" - "stdint.0.7.0" - "stdio.v0.14.0" - "stdlib-shims.0.1.0" + "sexp_diff.v0.17.0" + "sexp_pretty.v0.17.0" + "sexplib.v0.17.0" + "sexplib0.v0.17.0" + "sodium.5.2.1" + "spawn.v0.15.0" + "splittable_random.v0.17.0" + "stdint.0.7.2" + "stdio.v0.17.0" + "stdlib-shims.0.3.0" + "stdune.3.20.2" "stringext.1.6.0" - "textutils.v0.14.0" - "textutils_kernel.v0.14.0" - "time_now.v0.14.0" - "timezone.v0.14.0" - "topkg.1.0.3" + "textutils.v0.17.0" + "textutils_kernel.v0.17.0" + "time_now.v0.17.0" + "timezone.v0.17.0" + "topkg.1.1.1" "trie.1.0.0" - "typerep.v0.14.0" + "typerep.v0.17.0" "tyxml.4.5.0" "uchar.0.0.2" + "uopt.v0.17.0" "uri.4.2.0" "uri-sexp.4.2.0" - "utop.2.9.1" - "uucp.13.0.0" - "uuidm.0.9.7" - "uuseg.13.0.0" - "uutf.1.0.2" - "variantslib.v0.14.0" - "yojson.1.7.0" + "utop.2.16.0" + "uucp.17.0.0" + "uuidm.0.9.10" + "uuseg.17.0.0" + "uutf.1.0.4" + "variantslib.v0.17.0" + "xdg.3.20.2" + "yojson.2.0.0" "zarith.1.11" - "zarith_stubs_js.v0.14.1" - "zed.3.1.0" + "zarith_stubs_js.v0.17.0" + "zed.3.2.3" ] From ec01e1e9b4faaa99f2a68c81538af515406ff012 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 15:46:02 +0800 Subject: [PATCH 02/56] bump toolchain source to use ocaml 5.2.1 --- dockerfiles/stages/1-build-deps | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dockerfiles/stages/1-build-deps b/dockerfiles/stages/1-build-deps index fe09ce38cbee..c8e40afb7cef 100644 --- a/dockerfiles/stages/1-build-deps +++ b/dockerfiles/stages/1-build-deps @@ -34,8 +34,8 @@ ARG TARGETARCH # - dockerfiles/1-build-deps # - opam.export # - scripts/update_opam_switch.sh -ARG OCAML_VERSION=4.14 -ARG OCAML_REVISION=.2 +ARG OCAML_VERSION=5.2 +ARG OCAML_REVISION=.1 ARG OCAML_VARIANT= ARG OCAML_PACKAGE= ARG OPAM_VERSION=2.3.0 From 1cf2b4e2ee45af5a96c633e2576967da171fd223 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 15:46:39 +0800 Subject: [PATCH 03/56] bump makefile & update opam switch script to use ocaml 5.2.1 --- Makefile | 2 +- scripts/update-opam-switch.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 4609b5648337..5880c179719f 100755 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ ## Configuration # Current OCaml version -OCAML_VERSION = "4.14.2" +OCAML_VERSION = "5.2.1" # machine word size WORD_SIZE = "64" diff --git a/scripts/update-opam-switch.sh b/scripts/update-opam-switch.sh index 24af72561cde..f66c506ccab7 100755 --- a/scripts/update-opam-switch.sh +++ b/scripts/update-opam-switch.sh @@ -22,7 +22,7 @@ switch_dir=opam_switches/"$sum" # - dockerfiles/1-build-deps # - opam.export # - scripts/update_opam_switch.sh -ocaml_version=4.14.2 +ocaml_version=5.2.1 # The version must be the same as the version used in: # - dockerfiles/1-build-deps From b7304f7c4aefa2fb3293a4f8540f9b1e89ac5adf Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 17:48:29 +0800 Subject: [PATCH 04/56] Bump opam repo pins --- dockerfiles/stages/1-build-deps | 4 ++-- flake.lock | 16 ++++++++-------- flake.nix | 4 ++-- scripts/update-opam-switch.sh | 4 ++-- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/dockerfiles/stages/1-build-deps b/dockerfiles/stages/1-build-deps index c8e40afb7cef..ed4944290f2e 100644 --- a/dockerfiles/stages/1-build-deps +++ b/dockerfiles/stages/1-build-deps @@ -44,8 +44,8 @@ ARG OPAM_VERSION=2.3.0 # - flake.nix (and flake.lock after running # `nix flake update opam-repository`). # - scripts/update_opam_switch.sh -ARG OPAM_REPOSITORY_COMMIT=08d8c16c16dc6b23a5278b06dff0ac6c7a217356 -ARG O1LABS_OPAM_REPOSITORY_COMMIT=dd90c5c72b7b7caeca3db3224b2503924deea08a +ARG OPAM_REPOSITORY_COMMIT=2e72379851a4769911b11b7f85be197919fe4b82 +ARG O1LABS_OPAM_REPOSITORY_COMMIT=5a86178017864741537d7b1cac96a957b4ddcb88 # Golang version number used to detemine tarball name ARG GO_VERSION=1.19.11 diff --git a/flake.lock b/flake.lock index 7536b98649e0..e3db59471b01 100644 --- a/flake.lock +++ b/flake.lock @@ -361,17 +361,17 @@ "o1-opam-repository": { "flake": false, "locked": { - "lastModified": 1760589013, - "narHash": "sha256-pugmvJB2/Ajr9sRujabatKJKwjheZMYgDpg17djfX3Y=", + "lastModified": 1764408537, + "narHash": "sha256-Xe/RxmzookjMFgxGpwppjEWTRDgpwc8YJeQZi5dFDTI=", "owner": "o1-labs", "repo": "opam-repository", - "rev": "dd90c5c72b7b7caeca3db3224b2503924deea08a", + "rev": "5a86178017864741537d7b1cac96a957b4ddcb88", "type": "github" }, "original": { "owner": "o1-labs", "repo": "opam-repository", - "rev": "dd90c5c72b7b7caeca3db3224b2503924deea08a", + "rev": "5a86178017864741537d7b1cac96a957b4ddcb88", "type": "github" } }, @@ -422,17 +422,17 @@ "opam-repository": { "flake": false, "locked": { - "lastModified": 1750360330, - "narHash": "sha256-sizv8xZ/E/OgsE/ak9Oo+iEuBpzvUs08T0S+yXXzaDs=", + "lastModified": 1764366206, + "narHash": "sha256-RQDL69vULCXJ6Sqr97Q63x6EbasjYt+swuQv5AohN2k=", "owner": "ocaml", "repo": "opam-repository", - "rev": "08d8c16c16dc6b23a5278b06dff0ac6c7a217356", + "rev": "2e72379851a4769911b11b7f85be197919fe4b82", "type": "github" }, "original": { "owner": "ocaml", "repo": "opam-repository", - "rev": "08d8c16c16dc6b23a5278b06dff0ac6c7a217356", + "rev": "2e72379851a4769911b11b7f85be197919fe4b82", "type": "github" } }, diff --git a/flake.nix b/flake.nix index 9885bd0d3332..71bc154e3949 100644 --- a/flake.nix +++ b/flake.nix @@ -31,7 +31,7 @@ inputs.describe-dune.inputs.nixpkgs.follows = "nixpkgs"; inputs.describe-dune.inputs.flake-utils.follows = "utils"; - inputs.o1-opam-repository.url = "github:o1-labs/opam-repository/dd90c5c72b7b7caeca3db3224b2503924deea08a"; + inputs.o1-opam-repository.url = "github:o1-labs/opam-repository/5a86178017864741537d7b1cac96a957b4ddcb88"; inputs.o1-opam-repository.flake = false; # The version must be the same as the version used in: @@ -40,7 +40,7 @@ # `nix flake update opam-repository`). # - scripts/update-opam-switch.sh inputs.opam-repository.url = - "github:ocaml/opam-repository/08d8c16c16dc6b23a5278b06dff0ac6c7a217356"; + "github:ocaml/opam-repository/2e72379851a4769911b11b7f85be197919fe4b82"; inputs.opam-repository.flake = false; inputs.nixpkgs-mozilla.url = "github:mozilla/nixpkgs-mozilla"; diff --git a/scripts/update-opam-switch.sh b/scripts/update-opam-switch.sh index f66c506ccab7..89730e05630e 100755 --- a/scripts/update-opam-switch.sh +++ b/scripts/update-opam-switch.sh @@ -29,8 +29,8 @@ ocaml_version=5.2.1 # - flake.nix (and flake.lock after running # `nix flake update opam-repository`). # - scripts/update_opam_switch.sh -OPAM_REPOSITORY_COMMIT=08d8c16c16dc6b23a5278b06dff0ac6c7a217356 -O1LABS_OPAM_REPOSITORY_COMMIT=dd90c5c72b7b7caeca3db3224b2503924deea08a +OPAM_REPOSITORY_COMMIT=2e72379851a4769911b11b7f85be197919fe4b82 +O1LABS_OPAM_REPOSITORY_COMMIT=5a86178017864741537d7b1cac96a957b4ddcb88 if [[ -d _opam ]]; then read -rp "Directory '_opam' exists and will be removed. You can also bypass the check by setting the variable BYPASS_OPAM_SWITCH_UPDATE to any value. Continue? [y/N] " \ From 5743801d016aae76e4c47ea72372f7b26980d74b Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 18:08:09 +0800 Subject: [PATCH 05/56] Remove dep base.caml as it's no longer present --- src/app/archive/lib/dune | 1 - src/app/archive_blocks/dune | 1 - src/app/archive_hardfork_toolbox/dune | 2 - src/app/archive_hardfork_toolbox/tests/dune | 1 - src/app/best_tip_merger/dune | 1 - src/app/cli/src/cli_entrypoint/dune | 1 - src/app/cli/src/init/dune | 1 - src/app/delegation_verify/dune | 1 - src/app/disk_caching_stats/dune | 1 - src/app/heap_usage/dune | 1 - src/app/replayer/dune | 1 - src/app/rosetta/lib/dune | 1 - src/app/test_executive/dune | 1 - src/app/zkapp_limits/dune | 1 - .../test/optional_custom_gates/dune | 1 - src/lib/blake2/dune | 1 - src/lib/block_time/dune | 1 - src/lib/blockchain_snark/dune | 1 - src/lib/cache_dir/native/dune | 1 - src/lib/child_processes/dune | 1 - src/lib/cli_lib/dune | 1 - src/lib/consensus/dune | 1 - src/lib/consensus/vrf/dune | 1 - src/lib/crypto/kimchi_backend/common/dune | 1 - .../crypto/kimchi_backend/gadgets/runner/dune | 1 - .../gadgets/runner/example/dune | 1 - .../crypto/kimchi_backend/pasta/basic/dune | 1 - .../pasta/constraint_system/caml/dune | 1 - .../pasta/constraint_system/dune | 1 - src/lib/crypto/kimchi_backend/pasta/dune | 1 - src/lib/crypto/plonkish_prelude/dune | 1 - src/lib/crypto_params/gen/dune | 1 - src/lib/currency/dune | 1 - src/lib/daemon_rpcs/dune | 1 - src/lib/dummy_values/gen_values/dune | 1 - src/lib/fields_derivers_zkapps/dune | 1 - src/lib/filtered_external_transition/dune | 1 - src/lib/generated_graphql_queries/gen/dune | 1 - src/lib/genesis_constants/dune | 1 - src/lib/genesis_ledger_helper/dune | 1 - src/lib/gossip_net/dune | 1 - src/lib/key_cache/async/dune | 1 - src/lib/logger/fake/dune | 1 - src/lib/logger/native/dune | 1 - src/lib/merkle_address/dune | 1 - src/lib/merkle_ledger/dune | 1 - src/lib/merkle_ledger/test/dune | 1 - src/lib/merkle_mask/dune | 1 - src/lib/mina_base/dune | 1 - src/lib/mina_base/test/dune | 1 - src/lib/mina_base/test/fee_excess/dune | 1 - src/lib/mina_base/test/helpers/dune | 1 - src/lib/mina_graphql/dune | 1 - src/lib/mina_ledger/dune | 1 - src/lib/mina_ledger/test/helpers/dune | 1 - src/lib/mina_lib/dune | 1 - src/lib/mina_lib/tests/dune | 1 - src/lib/mina_lmdb_storage/dune | 1 - src/lib/mina_metrics/prometheus_metrics/dune | 1 - src/lib/mina_net2/dune | 1 - src/lib/mina_net2/tests/dune | 1 - src/lib/mina_networking/dune | 1 - src/lib/mina_numbers/dune | 1 - src/lib/mina_stdlib/dune | 1 - src/lib/network_peer/dune | 1 - src/lib/network_pool/test/dune | 1 - src/lib/node_addrs_and_ports/dune | 1 - src/lib/node_error_service/dune | 1 - src/lib/node_status_service/dune | 1 - src/lib/non_zero_curve_point/dune | 1 - src/lib/o1js_stub/dune | 1 - src/lib/o1trace/webkit_event/dune | 1 - src/lib/one_or_two/dune | 1 - src/lib/parallel_scan/dune | 1 - src/lib/perf_histograms/dune | 1 - src/lib/pickles/composition_types/dune | 1 - src/lib/pickles/dune | 1 - src/lib/pickles/limb_vector/dune | 1 - src/lib/pickles/snarky_tests/dune | 1 - src/lib/pickles/test/chunked_circuits/dune | 1 - .../pickles/test/optional_custom_gates/dune | 1 - .../optional_custom_gates/test_gadgets/dune | 1 - src/lib/pickles_base/dune | 1 - src/lib/pickles_types/dune | 1 - src/lib/ppx_mina/dune | 1 - src/lib/ppx_version/dune | 1 - src/lib/ppx_version/test/dune | 38 +++++++++---------- src/lib/proof_carrying_data/dune | 1 - src/lib/protocol_version/dune | 1 - src/lib/prover/dune | 1 - src/lib/random_oracle_input/dune | 2 +- src/lib/rocksdb/dune | 1 - src/lib/rocksdb/tests/dune | 1 - src/lib/rosetta_lib/dune | 1 - src/lib/runtime_config/dune | 1 - src/lib/secrets/dune | 1 - src/lib/sgn/dune | 1 - src/lib/sgn_type/dune | 1 - src/lib/signature_lib/dune | 1 - src/lib/snark_keys_header/dune | 2 +- src/lib/snark_profiler_lib/dune | 1 - src/lib/snark_work_lib/dune | 1 - src/lib/snark_worker/dune | 1 - src/lib/snark_worker/standalone/dune | 1 - src/lib/sparse_ledger_lib/dune | 1 - src/lib/staged_ledger/test/dune | 1 - src/lib/staged_ledger_diff/dune | 1 - src/lib/storage/dune | 1 - src/lib/sync_status/dune | 1 - src/lib/syncable_ledger/dune | 1 - src/lib/syncable_ledger/test/dune | 1 - src/lib/testing/integration_test_lib/dune | 1 - .../integration_test_local_engine/dune | 1 - src/lib/testing/test_util/dune | 1 - src/lib/transaction/dune | 1 - src/lib/transaction_inclusion_status/dune | 1 - src/lib/transaction_logic/dune | 1 - src/lib/transaction_protocol_state/dune | 1 - .../test/account_timing/dune | 1 - src/lib/transaction_snark_scan_state/dune | 1 - src/lib/transaction_snark_work/dune | 1 - src/lib/transaction_witness/dune | 1 - src/lib/transition_frontier/extensions/dune | 1 - .../transition_frontier/frontier_base/dune | 1 - .../transition_frontier/full_frontier/dune | 1 - .../persistent_frontier/dune | 1 - .../transition_frontier/persistent_root/dune | 1 - src/lib/transition_router/dune | 1 - src/lib/trust_system/dune | 1 - src/lib/unsigned_extended/dune | 1 - src/lib/uptime_service/dune | 1 - src/lib/user_command_input/dune | 1 - src/lib/verifier/dune | 1 - src/lib/vrf_evaluator/dune | 1 - src/lib/vrf_lib/dune | 1 - src/lib/with_hash/dune | 1 - src/lib/work_selector/dune | 1 - src/test/archive/patch_archive_test/dune | 1 - 138 files changed, 21 insertions(+), 157 deletions(-) diff --git a/src/app/archive/lib/dune b/src/app/archive/lib/dune index 0793c19f3aa4..ac12da4efab0 100644 --- a/src/app/archive/lib/dune +++ b/src/app/archive/lib/dune @@ -9,7 +9,6 @@ async_rpc_kernel async_unix base.base_internalhash_types - base.caml base64 bin_prot.shape caqti diff --git a/src/app/archive_blocks/dune b/src/app/archive_blocks/dune index df22ebd8fd24..d8bdeb7b9dc8 100644 --- a/src/app/archive_blocks/dune +++ b/src/app/archive_blocks/dune @@ -9,7 +9,6 @@ async_kernel async_unix base - base.caml caqti caqti-async caqti-driver-postgresql diff --git a/src/app/archive_hardfork_toolbox/dune b/src/app/archive_hardfork_toolbox/dune index a4aac271be4b..477f062df96a 100644 --- a/src/app/archive_hardfork_toolbox/dune +++ b/src/app/archive_hardfork_toolbox/dune @@ -16,7 +16,6 @@ core_kernel caqti-async base - base.caml integers ;; local libraries logger @@ -74,7 +73,6 @@ core_kernel caqti-async base - base.caml async.async_command integers ;; local libraries diff --git a/src/app/archive_hardfork_toolbox/tests/dune b/src/app/archive_hardfork_toolbox/tests/dune index afa45e3663ab..f3de2b8ae7b9 100644 --- a/src/app/archive_hardfork_toolbox/tests/dune +++ b/src/app/archive_hardfork_toolbox/tests/dune @@ -15,7 +15,6 @@ core_kernel caqti-async base - base.caml threads.posix ;; from parent dir archive_hardfork_toolbox_lib diff --git a/src/app/best_tip_merger/dune b/src/app/best_tip_merger/dune index c2555418b459..44b1e888bb00 100644 --- a/src/app/best_tip_merger/dune +++ b/src/app/best_tip_merger/dune @@ -8,7 +8,6 @@ async.async_command async_kernel stdio - base.caml yojson lib core_kernel diff --git a/src/app/cli/src/cli_entrypoint/dune b/src/app/cli/src/cli_entrypoint/dune index 4c1f17a88804..ad9cdc54cd1f 100644 --- a/src/app/cli/src/cli_entrypoint/dune +++ b/src/app/cli/src/cli_entrypoint/dune @@ -15,7 +15,6 @@ init async core.daemon - base.caml uri async.async_command result diff --git a/src/app/cli/src/init/dune b/src/app/cli/src/init/dune index dc81fec8a4bb..53b73005f3fd 100644 --- a/src/app/cli/src/init/dune +++ b/src/app/cli/src/init/dune @@ -31,7 +31,6 @@ graphql_parser async.async_command async_rpc_kernel - base.caml base.base_internalhash_types graphql-cohttp cohttp-async diff --git a/src/app/delegation_verify/dune b/src/app/delegation_verify/dune index 90b52ac1f3a2..13216be45205 100644 --- a/src/app/delegation_verify/dune +++ b/src/app/delegation_verify/dune @@ -8,7 +8,6 @@ core stdio base - base.caml ppx_deriving_yojson.runtime yojson base64 diff --git a/src/app/disk_caching_stats/dune b/src/app/disk_caching_stats/dune index 7bb46e967eb9..14f00b4729e2 100644 --- a/src/app/disk_caching_stats/dune +++ b/src/app/disk_caching_stats/dune @@ -37,7 +37,6 @@ core core_kernel base - base.caml bin_prot splittable_random sexplib0) diff --git a/src/app/heap_usage/dune b/src/app/heap_usage/dune index 762dd59ddad4..b37904234fa9 100644 --- a/src/app/heap_usage/dune +++ b/src/app/heap_usage/dune @@ -12,7 +12,6 @@ async core_kernel base - base.caml base.base_internalhash_types async.async_command yojson diff --git a/src/app/replayer/dune b/src/app/replayer/dune index 22b0b48ecce9..bba757a9ec3e 100644 --- a/src/app/replayer/dune +++ b/src/app/replayer/dune @@ -9,7 +9,6 @@ result async.async_command async - base.caml bin_prot.shape caqti-async core_kernel diff --git a/src/app/rosetta/lib/dune b/src/app/rosetta/lib/dune index 808b1bc2499b..78803d5b070a 100644 --- a/src/app/rosetta/lib/dune +++ b/src/app/rosetta/lib/dune @@ -17,7 +17,6 @@ caqti-async cohttp-async archive_lib - base.caml async_kernel uri core diff --git a/src/app/test_executive/dune b/src/app/test_executive/dune index ad1c5cb73593..e9dd80302e82 100644 --- a/src/app/test_executive/dune +++ b/src/app/test_executive/dune @@ -8,7 +8,6 @@ async_kernel async_unix base.base_internalhash_types - base.caml cmdliner core core_kernel diff --git a/src/app/zkapp_limits/dune b/src/app/zkapp_limits/dune index a38cfa996a5e..b6bf94d94831 100644 --- a/src/app/zkapp_limits/dune +++ b/src/app/zkapp_limits/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries base - base.caml core_kernel ;; local libraries mina_base diff --git a/src/app/zkapps_examples/test/optional_custom_gates/dune b/src/app/zkapps_examples/test/optional_custom_gates/dune index 68b11c23cdcf..ab9bc727d5f3 100644 --- a/src/app/zkapps_examples/test/optional_custom_gates/dune +++ b/src/app/zkapps_examples/test/optional_custom_gates/dune @@ -7,7 +7,6 @@ async_kernel async_unix base - base.caml core core_kernel integers diff --git a/src/lib/blake2/dune b/src/lib/blake2/dune index 9eb4d039eb51..07cdd56685e4 100644 --- a/src/lib/blake2/dune +++ b/src/lib/blake2/dune @@ -10,7 +10,6 @@ (libraries ;; opam libraries base.base_internalhash_types - base.caml bigarray-compat bin_prot.shape core_kernel diff --git a/src/lib/block_time/dune b/src/lib/block_time/dune index 9ddd687ab9cd..2654e12cf465 100644 --- a/src/lib/block_time/dune +++ b/src/lib/block_time/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries integers - base.caml bin_prot.shape sexplib0 async_kernel diff --git a/src/lib/blockchain_snark/dune b/src/lib/blockchain_snark/dune index 2ba907ceb769..57c45f37d0e0 100644 --- a/src/lib/blockchain_snark/dune +++ b/src/lib/blockchain_snark/dune @@ -8,7 +8,6 @@ ;; opam libraries async async_kernel - base.caml base.md5 bin_prot.shape core diff --git a/src/lib/cache_dir/native/dune b/src/lib/cache_dir/native/dune index 4920e7215a70..9724ed7f08ab 100644 --- a/src/lib/cache_dir/native/dune +++ b/src/lib/cache_dir/native/dune @@ -3,7 +3,6 @@ (name cache_dir_native) (libraries ;; opam libraries - base.caml async_unix base core diff --git a/src/lib/child_processes/dune b/src/lib/child_processes/dune index 05436177e0bc..f66d5ef71ed8 100644 --- a/src/lib/child_processes/dune +++ b/src/lib/child_processes/dune @@ -26,7 +26,6 @@ async_unix base base.base_internalhash_types - base.caml core core_kernel ctypes diff --git a/src/lib/cli_lib/dune b/src/lib/cli_lib/dune index 915317eae324..d445f5b06809 100644 --- a/src/lib/cli_lib/dune +++ b/src/lib/cli_lib/dune @@ -9,7 +9,6 @@ result sexplib0 async.async_command - base.caml async_kernel async.async_rpc camlp-streams diff --git a/src/lib/consensus/dune b/src/lib/consensus/dune index 4862efb61af1..53ec561101e7 100644 --- a/src/lib/consensus/dune +++ b/src/lib/consensus/dune @@ -13,7 +13,6 @@ core.uuid async_kernel sexplib0 - base.caml integers async core diff --git a/src/lib/consensus/vrf/dune b/src/lib/consensus/vrf/dune index 9f11d2c50009..d494cdde21a6 100644 --- a/src/lib/consensus/vrf/dune +++ b/src/lib/consensus/vrf/dune @@ -5,7 +5,6 @@ ;; opam libraries ppx_inline_test.config bignum.bigint - base.caml base base64 core_kernel diff --git a/src/lib/crypto/kimchi_backend/common/dune b/src/lib/crypto/kimchi_backend/common/dune index 558282e95fad..e4a9e505aa99 100644 --- a/src/lib/crypto/kimchi_backend/common/dune +++ b/src/lib/crypto/kimchi_backend/common/dune @@ -23,7 +23,6 @@ integers digestif core_kernel - base.caml ppx_inline_test.config bignum.bigint zarith diff --git a/src/lib/crypto/kimchi_backend/gadgets/runner/dune b/src/lib/crypto/kimchi_backend/gadgets/runner/dune index 9ea6d108770c..30f6fcc21e30 100644 --- a/src/lib/crypto/kimchi_backend/gadgets/runner/dune +++ b/src/lib/crypto/kimchi_backend/gadgets/runner/dune @@ -10,7 +10,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune b/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune index cc37baa9d128..d5ab06229288 100644 --- a/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune +++ b/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune @@ -9,7 +9,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/crypto/kimchi_backend/pasta/basic/dune b/src/lib/crypto/kimchi_backend/pasta/basic/dune index a034c7355653..670eaab5c8fb 100644 --- a/src/lib/crypto/kimchi_backend/pasta/basic/dune +++ b/src/lib/crypto/kimchi_backend/pasta/basic/dune @@ -14,7 +14,6 @@ sexplib0 core_kernel bin_prot.shape - base.caml ;; local libraries sponge kimchi_backend_common diff --git a/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune b/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune index 62a2a11add6d..6a28aa6de673 100644 --- a/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune +++ b/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune @@ -14,7 +14,6 @@ sexplib0 core_kernel bin_prot.shape - base.caml ;; local libraries sponge kimchi_backend_common diff --git a/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune b/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune index c7afe6604ecc..25eb2b45262c 100644 --- a/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune +++ b/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune @@ -14,7 +14,6 @@ sexplib0 core_kernel bin_prot.shape - base.caml ;; local libraries sponge kimchi_backend_common diff --git a/src/lib/crypto/kimchi_backend/pasta/dune b/src/lib/crypto/kimchi_backend/pasta/dune index 51ba3b1d9592..5a8ed9099b27 100644 --- a/src/lib/crypto/kimchi_backend/pasta/dune +++ b/src/lib/crypto/kimchi_backend/pasta/dune @@ -14,7 +14,6 @@ sexplib0 core_kernel bin_prot.shape - base.caml ;; local libraries sponge kimchi_backend_common diff --git a/src/lib/crypto/plonkish_prelude/dune b/src/lib/crypto/plonkish_prelude/dune index 053f1d9034cc..208ece655f0d 100644 --- a/src/lib/crypto/plonkish_prelude/dune +++ b/src/lib/crypto/plonkish_prelude/dune @@ -26,7 +26,6 @@ (backend bisect_ppx)) (libraries ;; opam libraries - base.caml bin_prot.shape core_kernel result diff --git a/src/lib/crypto_params/gen/dune b/src/lib/crypto_params/gen/dune index 131c268c7fe4..92785a4eaed9 100644 --- a/src/lib/crypto_params/gen/dune +++ b/src/lib/crypto_params/gen/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries stdio - base.caml sexplib0 core_kernel compiler-libs diff --git a/src/lib/currency/dune b/src/lib/currency/dune index 40382139edb8..ce856969b550 100644 --- a/src/lib/currency/dune +++ b/src/lib/currency/dune @@ -8,7 +8,6 @@ ;; opam libraries base base.base_internalhash_types - base.caml bin_prot.shape core_kernel integers diff --git a/src/lib/daemon_rpcs/dune b/src/lib/daemon_rpcs/dune index 7f412ecb510d..d157a1301d46 100644 --- a/src/lib/daemon_rpcs/dune +++ b/src/lib/daemon_rpcs/dune @@ -11,7 +11,6 @@ async_kernel async_rpc_kernel async_unix - base.caml bin_prot.shape core core_kernel diff --git a/src/lib/dummy_values/gen_values/dune b/src/lib/dummy_values/gen_values/dune index 1e92c74850c6..88636d0f1278 100644 --- a/src/lib/dummy_values/gen_values/dune +++ b/src/lib/dummy_values/gen_values/dune @@ -5,7 +5,6 @@ ;; opam libraries async_unix stdio - base.caml ocaml-migrate-parsetree core async diff --git a/src/lib/fields_derivers_zkapps/dune b/src/lib/fields_derivers_zkapps/dune index e23e19852c37..25fa414ee07d 100644 --- a/src/lib/fields_derivers_zkapps/dune +++ b/src/lib/fields_derivers_zkapps/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - base.caml core_kernel fieldslib graphql diff --git a/src/lib/filtered_external_transition/dune b/src/lib/filtered_external_transition/dune index 03d91886eb36..baa25afde8b2 100644 --- a/src/lib/filtered_external_transition/dune +++ b/src/lib/filtered_external_transition/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries base - base.caml bin_prot.shape core core_kernel diff --git a/src/lib/generated_graphql_queries/gen/dune b/src/lib/generated_graphql_queries/gen/dune index ec9cfddbf575..c13a6a7a26ff 100644 --- a/src/lib/generated_graphql_queries/gen/dune +++ b/src/lib/generated_graphql_queries/gen/dune @@ -8,7 +8,6 @@ ppxlib.astlib yojson mina_base - base.caml compiler-libs ocaml-migrate-parsetree stdio) diff --git a/src/lib/genesis_constants/dune b/src/lib/genesis_constants/dune index dc73063c4b1c..9164a020df88 100644 --- a/src/lib/genesis_constants/dune +++ b/src/lib/genesis_constants/dune @@ -10,7 +10,6 @@ base bin_prot.shape core_kernel - base.caml sexplib0 integers ;; local libraries diff --git a/src/lib/genesis_ledger_helper/dune b/src/lib/genesis_ledger_helper/dune index 6cf0f0d9eb91..bd1dd08690c6 100644 --- a/src/lib/genesis_ledger_helper/dune +++ b/src/lib/genesis_ledger_helper/dune @@ -13,7 +13,6 @@ core async_kernel core.uuid - base.caml sexplib0 digestif ;; local libraries diff --git a/src/lib/gossip_net/dune b/src/lib/gossip_net/dune index f6c47c1bed27..77fb1b92e81c 100644 --- a/src/lib/gossip_net/dune +++ b/src/lib/gossip_net/dune @@ -10,7 +10,6 @@ async.async_rpc async_kernel base - base.caml bin_prot.shape async_rpc_kernel async diff --git a/src/lib/key_cache/async/dune b/src/lib/key_cache/async/dune index 942c6400677c..9b8d64785c72 100644 --- a/src/lib/key_cache/async/dune +++ b/src/lib/key_cache/async/dune @@ -9,7 +9,6 @@ async_unix core_kernel base - base.caml ;; local libraries key_cache logger) diff --git a/src/lib/logger/fake/dune b/src/lib/logger/fake/dune index c5ec33c8d449..36f5f3679611 100644 --- a/src/lib/logger/fake/dune +++ b/src/lib/logger/fake/dune @@ -7,7 +7,6 @@ core_kernel sexplib0 bin_prot.shape - base.caml base.base_internalhash_types ;; local libraries interpolator_lib diff --git a/src/lib/logger/native/dune b/src/lib/logger/native/dune index e70158b3dd08..342500399fa7 100644 --- a/src/lib/logger/native/dune +++ b/src/lib/logger/native/dune @@ -11,7 +11,6 @@ core_kernel sexplib0 bin_prot.shape - base.caml base.base_internalhash_types ;; local libraries itn_logger diff --git a/src/lib/merkle_address/dune b/src/lib/merkle_address/dune index fc2712b74bc0..3639e66c07b6 100644 --- a/src/lib/merkle_address/dune +++ b/src/lib/merkle_address/dune @@ -11,7 +11,6 @@ bitstring core_kernel sexplib0 - base.caml ppx_inline_test.config ;; local libraries mina_stdlib diff --git a/src/lib/merkle_ledger/dune b/src/lib/merkle_ledger/dune index 7282afcd69da..22806f3cfaf0 100644 --- a/src/lib/merkle_ledger/dune +++ b/src/lib/merkle_ledger/dune @@ -11,7 +11,6 @@ async_kernel async_unix base.base_internalhash_types - base.caml bin_prot.shape bitstring core diff --git a/src/lib/merkle_ledger/test/dune b/src/lib/merkle_ledger/test/dune index 06ce2a797400..bd250bc25f19 100644 --- a/src/lib/merkle_ledger/test/dune +++ b/src/lib/merkle_ledger/test/dune @@ -16,7 +16,6 @@ async_kernel async_unix base.base_internalhash_types - base.caml base58_check bin_prot.shape codable diff --git a/src/lib/merkle_mask/dune b/src/lib/merkle_mask/dune index 1c572a43b20c..82b614c13749 100644 --- a/src/lib/merkle_mask/dune +++ b/src/lib/merkle_mask/dune @@ -24,7 +24,6 @@ async async_kernel base.base_internalhash_types - base.caml bitstring core core.uuid diff --git a/src/lib/mina_base/dune b/src/lib/mina_base/dune index 90483c9a08a2..0c55dc89e494 100644 --- a/src/lib/mina_base/dune +++ b/src/lib/mina_base/dune @@ -15,7 +15,6 @@ digestif sexp_diff_kernel core_kernel - base.caml base base.base_internalhash_types integers diff --git a/src/lib/mina_base/test/dune b/src/lib/mina_base/test/dune index 6e9cc365b24e..d32d72a7de33 100644 --- a/src/lib/mina_base/test/dune +++ b/src/lib/mina_base/test/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - base.caml core_kernel integers sexplib0 diff --git a/src/lib/mina_base/test/fee_excess/dune b/src/lib/mina_base/test/fee_excess/dune index 3680abf60b6f..091a906c5c45 100644 --- a/src/lib/mina_base/test/fee_excess/dune +++ b/src/lib/mina_base/test/fee_excess/dune @@ -4,7 +4,6 @@ ;; opam libraries alcotest base - base.caml core_kernel integers ppx_inline_test.config diff --git a/src/lib/mina_base/test/helpers/dune b/src/lib/mina_base/test/helpers/dune index 3b84421a225c..778aac6be205 100644 --- a/src/lib/mina_base/test/helpers/dune +++ b/src/lib/mina_base/test/helpers/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - base.caml core_kernel integers sexplib0 diff --git a/src/lib/mina_graphql/dune b/src/lib/mina_graphql/dune index 0e4d4c5a7b86..21200a450ac0 100644 --- a/src/lib/mina_graphql/dune +++ b/src/lib/mina_graphql/dune @@ -7,7 +7,6 @@ integers bignum async_kernel - base.caml base.base_internalhash_types re2 graphql-async diff --git a/src/lib/mina_ledger/dune b/src/lib/mina_ledger/dune index bac744973b00..454737511575 100644 --- a/src/lib/mina_ledger/dune +++ b/src/lib/mina_ledger/dune @@ -20,7 +20,6 @@ rocks integers async_kernel - base.caml base core core_kernel diff --git a/src/lib/mina_ledger/test/helpers/dune b/src/lib/mina_ledger/test/helpers/dune index 818ae449f54e..eea57aea1f52 100644 --- a/src/lib/mina_ledger/test/helpers/dune +++ b/src/lib/mina_ledger/test/helpers/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - base.caml core_kernel core integers diff --git a/src/lib/mina_lib/dune b/src/lib/mina_lib/dune index 0dfffe859592..26a23cbb0761 100644 --- a/src/lib/mina_lib/dune +++ b/src/lib/mina_lib/dune @@ -15,7 +15,6 @@ incremental core_kernel async_kernel - base.caml base.base_internalhash_types uri stdio diff --git a/src/lib/mina_lib/tests/dune b/src/lib/mina_lib/tests/dune index b9c5cab64092..65e7c48de96e 100644 --- a/src/lib/mina_lib/tests/dune +++ b/src/lib/mina_lib/tests/dune @@ -15,7 +15,6 @@ cohttp cohttp-async ppx_inline_test.config - base.caml ;; local libraries mina_lib logger diff --git a/src/lib/mina_lmdb_storage/dune b/src/lib/mina_lmdb_storage/dune index 254adcaa46b7..38a0046386db 100644 --- a/src/lib/mina_lmdb_storage/dune +++ b/src/lib/mina_lmdb_storage/dune @@ -18,7 +18,6 @@ ppx_inline_test.config async_unix sexplib0 - base.caml base.base_internalhash_types splittable_random lmdb diff --git a/src/lib/mina_metrics/prometheus_metrics/dune b/src/lib/mina_metrics/prometheus_metrics/dune index 3cd172f3a46b..4439d1d76d85 100644 --- a/src/lib/mina_metrics/prometheus_metrics/dune +++ b/src/lib/mina_metrics/prometheus_metrics/dune @@ -18,7 +18,6 @@ base.base_internalhash_types uri async_unix - base.caml ;; local libraries logger o1trace diff --git a/src/lib/mina_net2/dune b/src/lib/mina_net2/dune index 7eefea395858..a85d7d2cffa6 100644 --- a/src/lib/mina_net2/dune +++ b/src/lib/mina_net2/dune @@ -18,7 +18,6 @@ ppx_inline_test.config async_unix sexplib0 - base.caml base.base_internalhash_types splittable_random integers diff --git a/src/lib/mina_net2/tests/dune b/src/lib/mina_net2/tests/dune index 7bc2b3be5592..e17642b5d30e 100644 --- a/src/lib/mina_net2/tests/dune +++ b/src/lib/mina_net2/tests/dune @@ -10,7 +10,6 @@ core_kernel sexplib0 bin_prot.shape - base.caml ;; local libraries mina_net2 mina_stdlib diff --git a/src/lib/mina_networking/dune b/src/lib/mina_networking/dune index ef7cfbf65151..556363b902d5 100644 --- a/src/lib/mina_networking/dune +++ b/src/lib/mina_networking/dune @@ -4,7 +4,6 @@ (library_flags -linkall) (libraries ;; opam libraries - base.caml async_rpc_kernel result core diff --git a/src/lib/mina_numbers/dune b/src/lib/mina_numbers/dune index 5b193ff4fa19..e98ba965ce48 100644 --- a/src/lib/mina_numbers/dune +++ b/src/lib/mina_numbers/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries result - base.caml bin_prot.shape bignum.bigint core_kernel diff --git a/src/lib/mina_stdlib/dune b/src/lib/mina_stdlib/dune index 12a671421932..f24e07e79756 100644 --- a/src/lib/mina_stdlib/dune +++ b/src/lib/mina_stdlib/dune @@ -11,7 +11,6 @@ (libraries ; opam libraries async_kernel - base.caml bin_prot bin_prot.shape core_kernel diff --git a/src/lib/network_peer/dune b/src/lib/network_peer/dune index 46c8e37bb4c0..faa06eb1391e 100644 --- a/src/lib/network_peer/dune +++ b/src/lib/network_peer/dune @@ -10,7 +10,6 @@ core_kernel bin_prot.shape sexplib0 - base.caml base.base_internalhash_types result async_kernel diff --git a/src/lib/network_pool/test/dune b/src/lib/network_pool/test/dune index 72b3279c0089..363441351aad 100644 --- a/src/lib/network_pool/test/dune +++ b/src/lib/network_pool/test/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - base.caml base.base_internalhash_types core_kernel core diff --git a/src/lib/node_addrs_and_ports/dune b/src/lib/node_addrs_and_ports/dune index 804b906b1dd8..17f7e5b1f8a6 100644 --- a/src/lib/node_addrs_and_ports/dune +++ b/src/lib/node_addrs_and_ports/dune @@ -7,7 +7,6 @@ async yojson sexplib0 - base.caml core_kernel bin_prot.shape ;; local libraries diff --git a/src/lib/node_error_service/dune b/src/lib/node_error_service/dune index b7170b6defef..c8313712a09e 100644 --- a/src/lib/node_error_service/dune +++ b/src/lib/node_error_service/dune @@ -15,7 +15,6 @@ async_kernel core_kernel.uuid integers - base.caml ;; local libraries error_json transition_frontier_base diff --git a/src/lib/node_status_service/dune b/src/lib/node_status_service/dune index 23bd5c3c7244..e87e1b910eca 100644 --- a/src/lib/node_status_service/dune +++ b/src/lib/node_status_service/dune @@ -14,7 +14,6 @@ async_kernel uri integers - base.caml ;; local libraries network_peer mina_base diff --git a/src/lib/non_zero_curve_point/dune b/src/lib/non_zero_curve_point/dune index eb3b42547c20..cf046a41bbbd 100644 --- a/src/lib/non_zero_curve_point/dune +++ b/src/lib/non_zero_curve_point/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries ppx_inline_test.config - base.caml sexplib0 core_kernel bin_prot.shape diff --git a/src/lib/o1js_stub/dune b/src/lib/o1js_stub/dune index 7d6ea3f2d3bf..86b13d5947c6 100644 --- a/src/lib/o1js_stub/dune +++ b/src/lib/o1js_stub/dune @@ -11,7 +11,6 @@ ;; opam libraries ;; core_kernel base - base.caml integers sexplib0 yojson diff --git a/src/lib/o1trace/webkit_event/dune b/src/lib/o1trace/webkit_event/dune index fdeec8448042..92d0aa6ee59e 100644 --- a/src/lib/o1trace/webkit_event/dune +++ b/src/lib/o1trace/webkit_event/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - base.caml async async_kernel async_unix diff --git a/src/lib/one_or_two/dune b/src/lib/one_or_two/dune index 3eac81b510d5..52d7f9f23593 100644 --- a/src/lib/one_or_two/dune +++ b/src/lib/one_or_two/dune @@ -11,7 +11,6 @@ core_kernel ppx_hash.runtime-lib sexplib0 - base.caml ppx_version.runtime) (preprocess (pps diff --git a/src/lib/parallel_scan/dune b/src/lib/parallel_scan/dune index ec0b82186889..1b2ede0d19ef 100644 --- a/src/lib/parallel_scan/dune +++ b/src/lib/parallel_scan/dune @@ -16,7 +16,6 @@ lens async_kernel bin_prot.shape - base.caml async_unix ;; local libraries mina_metrics diff --git a/src/lib/perf_histograms/dune b/src/lib/perf_histograms/dune index 3948bfa89484..c6c4c28be76e 100644 --- a/src/lib/perf_histograms/dune +++ b/src/lib/perf_histograms/dune @@ -16,7 +16,6 @@ core_kernel ppx_deriving_yojson.runtime async.async_rpc - base.caml async_kernel ;; local libraries mina_metrics) diff --git a/src/lib/pickles/composition_types/dune b/src/lib/pickles/composition_types/dune index 9d73c055e9f3..3d05d3326fd8 100644 --- a/src/lib/pickles/composition_types/dune +++ b/src/lib/pickles/composition_types/dune @@ -33,7 +33,6 @@ sexplib0 bin_prot.shape core_kernel - base.caml ;; local libraries mina_wire_types kimchi_pasta diff --git a/src/lib/pickles/dune b/src/lib/pickles/dune index cc60d6524a43..e47badd46eeb 100644 --- a/src/lib/pickles/dune +++ b/src/lib/pickles/dune @@ -20,7 +20,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/pickles/limb_vector/dune b/src/lib/pickles/limb_vector/dune index 2010d4aaf28f..6c0319e5a94a 100644 --- a/src/lib/pickles/limb_vector/dune +++ b/src/lib/pickles/limb_vector/dune @@ -15,7 +15,6 @@ bin_prot.shape sexplib0 core_kernel - base.caml result ;; local libraries snarky.backendless diff --git a/src/lib/pickles/snarky_tests/dune b/src/lib/pickles/snarky_tests/dune index a9710cf679b4..77269b465edc 100644 --- a/src/lib/pickles/snarky_tests/dune +++ b/src/lib/pickles/snarky_tests/dune @@ -18,7 +18,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/pickles/test/chunked_circuits/dune b/src/lib/pickles/test/chunked_circuits/dune index c7410c8eb3ae..5815978d8784 100644 --- a/src/lib/pickles/test/chunked_circuits/dune +++ b/src/lib/pickles/test/chunked_circuits/dune @@ -6,7 +6,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/pickles/test/optional_custom_gates/dune b/src/lib/pickles/test/optional_custom_gates/dune index 2c33bf7a8103..9ede4472b795 100644 --- a/src/lib/pickles/test/optional_custom_gates/dune +++ b/src/lib/pickles/test/optional_custom_gates/dune @@ -9,7 +9,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune b/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune index 89dbd087de4d..7651b90a4fc1 100644 --- a/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune +++ b/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune @@ -6,7 +6,6 @@ stdio integers result - base.caml bignum.bigint core_kernel base64 diff --git a/src/lib/pickles_base/dune b/src/lib/pickles_base/dune index 17ebf908867e..dc6777dc4bc0 100644 --- a/src/lib/pickles_base/dune +++ b/src/lib/pickles_base/dune @@ -22,7 +22,6 @@ base.base_internalhash_types sexplib0 bin_prot.shape - base.caml ppxlib core_kernel ;; local libraries diff --git a/src/lib/pickles_types/dune b/src/lib/pickles_types/dune index acb78c715ba9..aeb7399b3ca3 100644 --- a/src/lib/pickles_types/dune +++ b/src/lib/pickles_types/dune @@ -28,7 +28,6 @@ sexplib0 result core_kernel - base.caml bin_prot.shape ;; local libraries kimchi_types diff --git a/src/lib/ppx_mina/dune b/src/lib/ppx_mina/dune index a5bd01c973a3..237cdd2e52d5 100644 --- a/src/lib/ppx_mina/dune +++ b/src/lib/ppx_mina/dune @@ -13,7 +13,6 @@ ppx_bin_prot core_kernel base - base.caml ;; local libraries ppx_representatives ppx_register_event diff --git a/src/lib/ppx_version/dune b/src/lib/ppx_version/dune index 9234de609ae7..e5966642dc35 100644 --- a/src/lib/ppx_version/dune +++ b/src/lib/ppx_version/dune @@ -14,7 +14,6 @@ ppx_derivers ppx_bin_prot base - base.caml core_kernel ppx_version.runtime bin_prot) diff --git a/src/lib/ppx_version/test/dune b/src/lib/ppx_version/test/dune index e97757c80691..adb0638ac956 100644 --- a/src/lib/ppx_version/test/dune +++ b/src/lib/ppx_version/test/dune @@ -8,27 +8,27 @@ (library (name good_version_syntax) (preprocess (pps ppx_jane ppx_version ppx_deriving_yojson)) - (libraries base.caml core_kernel bin_prot.shape ppx_version.runtime) + (libraries core_kernel bin_prot.shape ppx_version.runtime) (modules good_version_syntax)) ;; versioning (library (name versioned_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_good)) ;; module versioning (executable (name versioned_module_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime mina_stdlib) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime mina_stdlib) (modules versioned_module_good)) (executable (name versioned_sig_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_sig_good)) ;;; should fail @@ -38,25 +38,25 @@ (library (name bad_version_syntax_missing_versioned) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_version_syntax_missing_versioned)) (library (name bad_versioned_in_functor) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_versioned_in_functor)) (library (name bad_versioned_in_nested_functor) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_versioned_in_nested_functor)) (library (name bad_version_syntax_multiple_errors) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_version_syntax_multiple_errors)) ;; versioning @@ -64,66 +64,66 @@ (library (name versioned_bad_module_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_module_name)) (library (name versioned_bad_version_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_version_name)) (library (name versioned_bad_type_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_type_name)) (library (name versioned_bad_option) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_option)) (library (name versioned_bad_contained_types) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_contained_types)) (library (name versioned_bad_arrow_type) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_arrow_type)) ;; module versioning (library (name versioned_module_bad_stable_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_stable_name)) (library (name versioned_module_bad_version_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_version_name)) (library (name versioned_module_bad_missing_type) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_missing_type)) (library (name versioned_module_bad_version_order) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_version_order)) (library (name versioned_module_bad_missing_to_latest) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries base.caml core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_missing_to_latest)) diff --git a/src/lib/proof_carrying_data/dune b/src/lib/proof_carrying_data/dune index b9cb2799e55f..7737dcea0e1c 100644 --- a/src/lib/proof_carrying_data/dune +++ b/src/lib/proof_carrying_data/dune @@ -9,7 +9,6 @@ core_kernel bin_prot.shape base - base.caml sexplib0 ;; local libraries mina_wire_types diff --git a/src/lib/protocol_version/dune b/src/lib/protocol_version/dune index da63096b2bf3..0d095571bc0c 100644 --- a/src/lib/protocol_version/dune +++ b/src/lib/protocol_version/dune @@ -7,7 +7,6 @@ core_kernel sexplib0 bin_prot.shape - base.caml base ppx_version.runtime ;; local libraries diff --git a/src/lib/prover/dune b/src/lib/prover/dune index 014468c2207e..b26253c349b7 100644 --- a/src/lib/prover/dune +++ b/src/lib/prover/dune @@ -11,7 +11,6 @@ async_kernel core_kernel bin_prot.shape - base.caml sexplib0 ;; local libraries with_hash diff --git a/src/lib/random_oracle_input/dune b/src/lib/random_oracle_input/dune index b42a552bdc08..61a59d85cc15 100644 --- a/src/lib/random_oracle_input/dune +++ b/src/lib/random_oracle_input/dune @@ -13,4 +13,4 @@ ppx_deriving_yojson)) (inline_tests (flags -verbose -show-counts)) - (libraries core_kernel sexplib0 base.caml ppx_inline_test.config)) + (libraries core_kernel sexplib0 ppx_inline_test.config)) diff --git a/src/lib/rocksdb/dune b/src/lib/rocksdb/dune index b86b4bcb9c82..088b01e1d7a8 100644 --- a/src/lib/rocksdb/dune +++ b/src/lib/rocksdb/dune @@ -10,7 +10,6 @@ async_kernel async_unix base.base_internalhash_types - base.caml core core.uuid core_kernel diff --git a/src/lib/rocksdb/tests/dune b/src/lib/rocksdb/tests/dune index c2de1d8661b7..0273ba600d47 100644 --- a/src/lib/rocksdb/tests/dune +++ b/src/lib/rocksdb/tests/dune @@ -6,7 +6,6 @@ async async_unix base.base_internalhash_types - base.caml core core.uuid core_kernel diff --git a/src/lib/rosetta_lib/dune b/src/lib/rosetta_lib/dune index ea9ceaffae39..4b30bc967ce4 100644 --- a/src/lib/rosetta_lib/dune +++ b/src/lib/rosetta_lib/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries result - base.caml caqti core_kernel base diff --git a/src/lib/runtime_config/dune b/src/lib/runtime_config/dune index 36115bb1209f..d40998d83b4e 100644 --- a/src/lib/runtime_config/dune +++ b/src/lib/runtime_config/dune @@ -8,7 +8,6 @@ async_unix core_kernel bin_prot.shape - base.caml base base64 integers diff --git a/src/lib/secrets/dune b/src/lib/secrets/dune index 1fe011b84c37..9c90c5da5aaf 100644 --- a/src/lib/secrets/dune +++ b/src/lib/secrets/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries result - base.caml bignum.bigint async_kernel async diff --git a/src/lib/sgn/dune b/src/lib/sgn/dune index 94b41bc6cda3..48db8a0e157c 100644 --- a/src/lib/sgn/dune +++ b/src/lib/sgn/dune @@ -10,7 +10,6 @@ sexplib0 base bin_prot.shape - base.caml ;; local libraries snark_params sgn_type diff --git a/src/lib/sgn_type/dune b/src/lib/sgn_type/dune index a1069236594a..0c15278ef532 100644 --- a/src/lib/sgn_type/dune +++ b/src/lib/sgn_type/dune @@ -12,7 +12,6 @@ yojson sexplib0 bin_prot.shape - base.caml ppx_version.runtime ;; local libraries mina_wire_types)) diff --git a/src/lib/signature_lib/dune b/src/lib/signature_lib/dune index f002a77c7d8b..540cd1cdd548 100644 --- a/src/lib/signature_lib/dune +++ b/src/lib/signature_lib/dune @@ -13,7 +13,6 @@ yojson core_kernel bin_prot.shape - base.caml result ;; local libraries mina_wire_types diff --git a/src/lib/snark_keys_header/dune b/src/lib/snark_keys_header/dune index 58f0fe30dcc8..8844c4200f4d 100644 --- a/src/lib/snark_keys_header/dune +++ b/src/lib/snark_keys_header/dune @@ -1,7 +1,7 @@ (library (name snark_keys_header) (public_name snark_keys_header) - (libraries base base.caml core_kernel integers result sexplib0 stdio) + (libraries base core_kernel integers result sexplib0 stdio) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/snark_profiler_lib/dune b/src/lib/snark_profiler_lib/dune index c40dd226a822..fa1613138d59 100644 --- a/src/lib/snark_profiler_lib/dune +++ b/src/lib/snark_profiler_lib/dune @@ -13,7 +13,6 @@ core base async - base.caml base.base_internalhash_types ;;local libraries mina_stdlib diff --git a/src/lib/snark_work_lib/dune b/src/lib/snark_work_lib/dune index 49926505f3ad..a2f8f394cb78 100644 --- a/src/lib/snark_work_lib/dune +++ b/src/lib/snark_work_lib/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - base.caml bin_prot.shape core core_kernel diff --git a/src/lib/snark_worker/dune b/src/lib/snark_worker/dune index 7b91bb3cc3e6..0dc82fe916fa 100644 --- a/src/lib/snark_worker/dune +++ b/src/lib/snark_worker/dune @@ -12,7 +12,6 @@ async_unix base base.base_internalhash_types - base.caml bin_prot.shape core core_kernel diff --git a/src/lib/snark_worker/standalone/dune b/src/lib/snark_worker/standalone/dune index a20e71c2da11..9be9f8ea91d7 100644 --- a/src/lib/snark_worker/standalone/dune +++ b/src/lib/snark_worker/standalone/dune @@ -9,7 +9,6 @@ async_kernel async_unix base - base.caml core core_kernel sexplib0 diff --git a/src/lib/sparse_ledger_lib/dune b/src/lib/sparse_ledger_lib/dune index b55ebfef4bd8..c814f37ac86e 100644 --- a/src/lib/sparse_ledger_lib/dune +++ b/src/lib/sparse_ledger_lib/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - base.caml core_kernel sexplib0 base diff --git a/src/lib/staged_ledger/test/dune b/src/lib/staged_ledger/test/dune index 10cee40157e8..fe092c189569 100644 --- a/src/lib/staged_ledger/test/dune +++ b/src/lib/staged_ledger/test/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - base.caml core_kernel integers sexplib0 diff --git a/src/lib/staged_ledger_diff/dune b/src/lib/staged_ledger_diff/dune index 84d6de6342a8..3e79a95873e8 100644 --- a/src/lib/staged_ledger_diff/dune +++ b/src/lib/staged_ledger_diff/dune @@ -7,7 +7,6 @@ sexplib0 async bin_prot.shape - base.caml blake2 stdint ppx_inline_test.config diff --git a/src/lib/storage/dune b/src/lib/storage/dune index 7d0bd4450e15..adfbf170c9a0 100644 --- a/src/lib/storage/dune +++ b/src/lib/storage/dune @@ -15,7 +15,6 @@ sexplib0 async_kernel async_unix - base.caml ;; local libraries logger ppx_version.runtime) diff --git a/src/lib/sync_status/dune b/src/lib/sync_status/dune index c80e386db3f3..69f012fc1da9 100644 --- a/src/lib/sync_status/dune +++ b/src/lib/sync_status/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base.base_internalhash_types - base.caml bin_prot.shape core_kernel sexplib0 diff --git a/src/lib/syncable_ledger/dune b/src/lib/syncable_ledger/dune index bc0812574374..cb9e75ce02e3 100644 --- a/src/lib/syncable_ledger/dune +++ b/src/lib/syncable_ledger/dune @@ -8,7 +8,6 @@ async_kernel core_kernel bin_prot.shape - base.caml sexplib0 core async diff --git a/src/lib/syncable_ledger/test/dune b/src/lib/syncable_ledger/test/dune index fee120410b11..caa00acb3824 100644 --- a/src/lib/syncable_ledger/test/dune +++ b/src/lib/syncable_ledger/test/dune @@ -14,7 +14,6 @@ async sexplib0 ppx_inline_test.config - base.caml ;; local libraries mina_numbers mina_base diff --git a/src/lib/testing/integration_test_lib/dune b/src/lib/testing/integration_test_lib/dune index 9fca34661c53..5b927ea841df 100644 --- a/src/lib/testing/integration_test_lib/dune +++ b/src/lib/testing/integration_test_lib/dune @@ -30,7 +30,6 @@ ;; opam libraries result base.base_internalhash_types - base.caml base uri sexplib0 diff --git a/src/lib/testing/integration_test_local_engine/dune b/src/lib/testing/integration_test_local_engine/dune index 7f6e473c7cdc..8d23e4c3aec0 100644 --- a/src/lib/testing/integration_test_local_engine/dune +++ b/src/lib/testing/integration_test_local_engine/dune @@ -36,7 +36,6 @@ sexplib0 stdio result - base.caml integers re2 ;; local libraries diff --git a/src/lib/testing/test_util/dune b/src/lib/testing/test_util/dune index d20ea81f6e5a..2967a3d271f3 100644 --- a/src/lib/testing/test_util/dune +++ b/src/lib/testing/test_util/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries core_kernel - base.caml bin_prot ;; local libraries snark_params diff --git a/src/lib/transaction/dune b/src/lib/transaction/dune index 9ccac2cfe232..17b212854d1e 100644 --- a/src/lib/transaction/dune +++ b/src/lib/transaction/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - base.caml base base.base_internalhash_types bin_prot.shape diff --git a/src/lib/transaction_inclusion_status/dune b/src/lib/transaction_inclusion_status/dune index 434c5a1f0ea7..cb0e4dc3a2f7 100644 --- a/src/lib/transaction_inclusion_status/dune +++ b/src/lib/transaction_inclusion_status/dune @@ -7,7 +7,6 @@ ;; opam libraries async_kernel core - base.caml bin_prot.shape sexplib0 core_kernel diff --git a/src/lib/transaction_logic/dune b/src/lib/transaction_logic/dune index 9e9aa4f59de8..0c754768bbdc 100644 --- a/src/lib/transaction_logic/dune +++ b/src/lib/transaction_logic/dune @@ -11,7 +11,6 @@ yojson sexp_diff_kernel core_kernel - base.caml base base.base_internalhash_types integers diff --git a/src/lib/transaction_protocol_state/dune b/src/lib/transaction_protocol_state/dune index 0b5000b5c278..c86ffacf5501 100644 --- a/src/lib/transaction_protocol_state/dune +++ b/src/lib/transaction_protocol_state/dune @@ -10,7 +10,6 @@ core_kernel core bin_prot.shape - base.caml ;; local libraries pickles genesis_constants diff --git a/src/lib/transaction_snark/test/account_timing/dune b/src/lib/transaction_snark/test/account_timing/dune index 1272244e227e..0ea3de34efef 100644 --- a/src/lib/transaction_snark/test/account_timing/dune +++ b/src/lib/transaction_snark/test/account_timing/dune @@ -8,7 +8,6 @@ async_unix core base - base.caml core_kernel sexplib0 yojson diff --git a/src/lib/transaction_snark_scan_state/dune b/src/lib/transaction_snark_scan_state/dune index 04f098f426b8..58d70c1629f7 100644 --- a/src/lib/transaction_snark_scan_state/dune +++ b/src/lib/transaction_snark_scan_state/dune @@ -9,7 +9,6 @@ core ppx_deriving_yojson.runtime sexplib0 - base.caml digestif base core_kernel diff --git a/src/lib/transaction_snark_work/dune b/src/lib/transaction_snark_work/dune index 2dc6e16c1f90..45a09c143245 100644 --- a/src/lib/transaction_snark_work/dune +++ b/src/lib/transaction_snark_work/dune @@ -6,7 +6,6 @@ core_kernel sexplib0 bin_prot.shape - base.caml base.base_internalhash_types core ;; local libraries diff --git a/src/lib/transaction_witness/dune b/src/lib/transaction_witness/dune index 0b073a8138f3..0ad7ed0f74ad 100644 --- a/src/lib/transaction_witness/dune +++ b/src/lib/transaction_witness/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - base.caml bin_prot.shape sexplib0 core_kernel diff --git a/src/lib/transition_frontier/extensions/dune b/src/lib/transition_frontier/extensions/dune index 8278d65a5fd4..4b8e4fb490c0 100644 --- a/src/lib/transition_frontier/extensions/dune +++ b/src/lib/transition_frontier/extensions/dune @@ -3,7 +3,6 @@ (public_name transition_frontier_extensions) (libraries ;;opam libraries - base.caml async_kernel core_kernel sexplib0 diff --git a/src/lib/transition_frontier/frontier_base/dune b/src/lib/transition_frontier/frontier_base/dune index e8d6cb61c5d4..c0a42b238488 100644 --- a/src/lib/transition_frontier/frontier_base/dune +++ b/src/lib/transition_frontier/frontier_base/dune @@ -4,7 +4,6 @@ (libraries ;;opam libraries async_unix - base.caml async_kernel core_kernel bin_prot.shape diff --git a/src/lib/transition_frontier/full_frontier/dune b/src/lib/transition_frontier/full_frontier/dune index feeaff2487f1..1ecb70ec3d2b 100644 --- a/src/lib/transition_frontier/full_frontier/dune +++ b/src/lib/transition_frontier/full_frontier/dune @@ -5,7 +5,6 @@ ;;opam libraries integers core - base.caml core_kernel sexplib0 base.base_internalhash_types diff --git a/src/lib/transition_frontier/persistent_frontier/dune b/src/lib/transition_frontier/persistent_frontier/dune index 32033bdf8849..d8c9af6d362d 100644 --- a/src/lib/transition_frontier/persistent_frontier/dune +++ b/src/lib/transition_frontier/persistent_frontier/dune @@ -9,7 +9,6 @@ async core async_kernel - base.caml sexplib0 async_unix ;;local libraries diff --git a/src/lib/transition_frontier/persistent_root/dune b/src/lib/transition_frontier/persistent_root/dune index d8744d05a6ed..a67d3034bdfd 100644 --- a/src/lib/transition_frontier/persistent_root/dune +++ b/src/lib/transition_frontier/persistent_root/dune @@ -7,7 +7,6 @@ core_kernel core core.uuid - base.caml ;;local libraries precomputed_values mina_stdlib_unix diff --git a/src/lib/transition_router/dune b/src/lib/transition_router/dune index b867b4bdc4dd..48e06113787a 100644 --- a/src/lib/transition_router/dune +++ b/src/lib/transition_router/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries integers - base.caml async_kernel core_kernel core diff --git a/src/lib/trust_system/dune b/src/lib/trust_system/dune index 19fb018b4351..a6c7dc860a32 100644 --- a/src/lib/trust_system/dune +++ b/src/lib/trust_system/dune @@ -7,7 +7,6 @@ sexplib0 core ppx_inline_test.config - base.caml async_kernel core_kernel bin_prot.shape diff --git a/src/lib/unsigned_extended/dune b/src/lib/unsigned_extended/dune index a190cc423978..1790ec546893 100644 --- a/src/lib/unsigned_extended/dune +++ b/src/lib/unsigned_extended/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - base.caml result base core_kernel diff --git a/src/lib/uptime_service/dune b/src/lib/uptime_service/dune index f8f4a71e7042..366b6b943d64 100644 --- a/src/lib/uptime_service/dune +++ b/src/lib/uptime_service/dune @@ -15,7 +15,6 @@ bin_prot.shape async_kernel core - base.caml cohttp uri ;; local libraries diff --git a/src/lib/user_command_input/dune b/src/lib/user_command_input/dune index fc145b28c9e5..965d2f05c8a4 100644 --- a/src/lib/user_command_input/dune +++ b/src/lib/user_command_input/dune @@ -8,7 +8,6 @@ core_kernel async_kernel sexplib0 - base.caml async ;; local libraries logger diff --git a/src/lib/verifier/dune b/src/lib/verifier/dune index c6f67326c5dd..2b000b6eb2d2 100644 --- a/src/lib/verifier/dune +++ b/src/lib/verifier/dune @@ -3,7 +3,6 @@ (public_name verifier) (libraries ;; opam libraries - base.caml async core_kernel async_kernel diff --git a/src/lib/vrf_evaluator/dune b/src/lib/vrf_evaluator/dune index 5ddbee5b1c28..5cd5c3b18a07 100644 --- a/src/lib/vrf_evaluator/dune +++ b/src/lib/vrf_evaluator/dune @@ -11,7 +11,6 @@ core_kernel bin_prot.shape sexplib0 - base.caml integers ;; local libraries mina_wire_types diff --git a/src/lib/vrf_lib/dune b/src/lib/vrf_lib/dune index 2549d1d3da47..a7e5905aa6f8 100644 --- a/src/lib/vrf_lib/dune +++ b/src/lib/vrf_lib/dune @@ -8,7 +8,6 @@ zarith bignum.bigint bin_prot.shape - base.caml core sexplib0 core_kernel diff --git a/src/lib/with_hash/dune b/src/lib/with_hash/dune index 584204fce3cd..373f1df63982 100644 --- a/src/lib/with_hash/dune +++ b/src/lib/with_hash/dune @@ -5,7 +5,6 @@ ;; opam libraries bin_prot.shape sexplib0 - base.caml core_kernel ;; local libraries mina_wire_types diff --git a/src/lib/work_selector/dune b/src/lib/work_selector/dune index 14f9b99413f2..0a69fcaa4af3 100644 --- a/src/lib/work_selector/dune +++ b/src/lib/work_selector/dune @@ -12,7 +12,6 @@ async core_kernel base - base.caml base.base_internalhash_types async_kernel ppx_inline_test.config diff --git a/src/test/archive/patch_archive_test/dune b/src/test/archive/patch_archive_test/dune index 2504f758d06f..425733b865aa 100644 --- a/src/test/archive/patch_archive_test/dune +++ b/src/test/archive/patch_archive_test/dune @@ -21,7 +21,6 @@ core async_unix stdio - base.caml result mina_automation mina_stdlib) From 740e4e3eee75f6873e157b2ffc322f2aa556c139 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 18:16:48 +0800 Subject: [PATCH 06/56] Remove dep core.uuid as it's no longer present --- src/app/cli/src/init/dune | 1 - src/lib/consensus/dune | 1 - src/lib/fake_network/dune | 1 - src/lib/genesis_ledger_helper/dune | 1 - src/lib/merkle_ledger/dune | 1 - src/lib/merkle_ledger/test/dune | 1 - src/lib/merkle_mask/dune | 1 - src/lib/mina_graphql/dune | 1 - src/lib/mina_lib/tests/dune | 1 - src/lib/node_error_service/dune | 1 - src/lib/rocksdb/dune | 1 - src/lib/rocksdb/tests/dune | 1 - src/lib/transition_frontier/full_frontier/dune | 1 - src/lib/transition_frontier/persistent_root/dune | 1 - src/lib/transition_frontier/tests/dune | 1 - 15 files changed, 15 deletions(-) diff --git a/src/app/cli/src/init/dune b/src/app/cli/src/init/dune index 53b73005f3fd..ce9d14b9293b 100644 --- a/src/app/cli/src/init/dune +++ b/src/app/cli/src/init/dune @@ -24,7 +24,6 @@ core_kernel core_kernel.uuid core - core.uuid base async cohttp diff --git a/src/lib/consensus/dune b/src/lib/consensus/dune index 53ec561101e7..aae3df6e2547 100644 --- a/src/lib/consensus/dune +++ b/src/lib/consensus/dune @@ -10,7 +10,6 @@ ;; opam libraries ppx_inline_test.config async_unix - core.uuid async_kernel sexplib0 integers diff --git a/src/lib/fake_network/dune b/src/lib/fake_network/dune index 4b8092d6dcde..64768de56b82 100644 --- a/src/lib/fake_network/dune +++ b/src/lib/fake_network/dune @@ -6,7 +6,6 @@ async async_unix core - core.uuid ;; local libraries block_time mina_stdlib diff --git a/src/lib/genesis_ledger_helper/dune b/src/lib/genesis_ledger_helper/dune index bd1dd08690c6..a8f4a72704da 100644 --- a/src/lib/genesis_ledger_helper/dune +++ b/src/lib/genesis_ledger_helper/dune @@ -12,7 +12,6 @@ core_kernel core async_kernel - core.uuid sexplib0 digestif ;; local libraries diff --git a/src/lib/merkle_ledger/dune b/src/lib/merkle_ledger/dune index 22806f3cfaf0..89b6db204466 100644 --- a/src/lib/merkle_ledger/dune +++ b/src/lib/merkle_ledger/dune @@ -14,7 +14,6 @@ bin_prot.shape bitstring core - core.uuid core_kernel core_kernel.uuid integers diff --git a/src/lib/merkle_ledger/test/dune b/src/lib/merkle_ledger/test/dune index bd250bc25f19..b581d46b974b 100644 --- a/src/lib/merkle_ledger/test/dune +++ b/src/lib/merkle_ledger/test/dune @@ -20,7 +20,6 @@ bin_prot.shape codable core - core.uuid core_kernel core_kernel.uuid currency diff --git a/src/lib/merkle_mask/dune b/src/lib/merkle_mask/dune index 82b614c13749..445ee6768684 100644 --- a/src/lib/merkle_mask/dune +++ b/src/lib/merkle_mask/dune @@ -26,7 +26,6 @@ base.base_internalhash_types bitstring core - core.uuid core_kernel core_kernel.uuid integers diff --git a/src/lib/mina_graphql/dune b/src/lib/mina_graphql/dune index 21200a450ac0..6d2b978a8dbf 100644 --- a/src/lib/mina_graphql/dune +++ b/src/lib/mina_graphql/dune @@ -12,7 +12,6 @@ graphql-async core_kernel.uuid core - core.uuid async core_kernel async_unix diff --git a/src/lib/mina_lib/tests/dune b/src/lib/mina_lib/tests/dune index 65e7c48de96e..3000dada9482 100644 --- a/src/lib/mina_lib/tests/dune +++ b/src/lib/mina_lib/tests/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries core - core.uuid core_kernel core_kernel.uuid async_kernel diff --git a/src/lib/node_error_service/dune b/src/lib/node_error_service/dune index c8313712a09e..b9af2f095f23 100644 --- a/src/lib/node_error_service/dune +++ b/src/lib/node_error_service/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core.uuid uri cohttp-async async diff --git a/src/lib/rocksdb/dune b/src/lib/rocksdb/dune index 088b01e1d7a8..79b38072c6f7 100644 --- a/src/lib/rocksdb/dune +++ b/src/lib/rocksdb/dune @@ -11,7 +11,6 @@ async_unix base.base_internalhash_types core - core.uuid core_kernel core_kernel.uuid ppx_inline_test.config diff --git a/src/lib/rocksdb/tests/dune b/src/lib/rocksdb/tests/dune index 0273ba600d47..ef4e751824e8 100644 --- a/src/lib/rocksdb/tests/dune +++ b/src/lib/rocksdb/tests/dune @@ -7,7 +7,6 @@ async_unix base.base_internalhash_types core - core.uuid core_kernel core_kernel.uuid rocks diff --git a/src/lib/transition_frontier/full_frontier/dune b/src/lib/transition_frontier/full_frontier/dune index 1ecb70ec3d2b..26ed85c9a031 100644 --- a/src/lib/transition_frontier/full_frontier/dune +++ b/src/lib/transition_frontier/full_frontier/dune @@ -38,7 +38,6 @@ async_unix child_processes coda_genesis_ledger - core.uuid core_kernel.uuid genesis_constants merkle_ledger diff --git a/src/lib/transition_frontier/persistent_root/dune b/src/lib/transition_frontier/persistent_root/dune index a67d3034bdfd..4eb96f7699ac 100644 --- a/src/lib/transition_frontier/persistent_root/dune +++ b/src/lib/transition_frontier/persistent_root/dune @@ -6,7 +6,6 @@ core_kernel.uuid core_kernel core - core.uuid ;;local libraries precomputed_values mina_stdlib_unix diff --git a/src/lib/transition_frontier/tests/dune b/src/lib/transition_frontier/tests/dune index 9217a72b4332..5c5da73652c6 100644 --- a/src/lib/transition_frontier/tests/dune +++ b/src/lib/transition_frontier/tests/dune @@ -2,7 +2,6 @@ (name transition_frontier_tests) (libraries ;;opam libraries - core.uuid core async async_kernel From e190180421de0c9a15027d531232688370f916bd Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 18:18:20 +0800 Subject: [PATCH 07/56] remove core_kernel as it's replaced by core --- src/app/archive/lib/dune | 1 - src/app/archive_blocks/dune | 1 - src/app/archive_hardfork_toolbox/dune | 2 -- src/app/archive_hardfork_toolbox/tests/dune | 1 - src/app/batch_txn_tool/dune | 1 - src/app/benchmarks/dune | 1 - src/app/best_tip_merger/dune | 1 - src/app/cli/src/cli_entrypoint/dune | 1 - src/app/cli/src/init/dune | 1 - src/app/delegation_verify/dune | 1 - src/app/disk_caching_stats/dune | 1 - src/app/dump_blocks/dune | 1 - src/app/extract_blocks/dune | 1 - src/app/heap_usage/dune | 1 - src/app/ledger_export_bench/dune | 1 - src/app/logproc/dune | 1 - src/app/missing_blocks_auditor/dune | 1 - src/app/reformat/dune | 1 - src/app/replayer/dune | 1 - src/app/rosetta/dune | 3 --- src/app/rosetta/indexer_test/dune | 1 - src/app/rosetta/lib/dune | 1 - src/app/rosetta/ocaml-signer/dune | 1 - src/app/runtime_genesis_ledger/dune | 1 - src/app/test_executive/dune | 1 - src/app/validate_keypair/dune | 1 - src/app/zkapp_limits/dune | 1 - src/app/zkapp_test_transaction/dune | 1 - src/app/zkapp_test_transaction/lib/dune | 1 - src/app/zkapps_examples/actions/dune | 1 - src/app/zkapps_examples/add_events/dune | 1 - src/app/zkapps_examples/big_circuit/dune | 1 - src/app/zkapps_examples/calls/dune | 1 - src/app/zkapps_examples/dune | 1 - src/app/zkapps_examples/empty_update/dune | 1 - src/app/zkapps_examples/initialize_state/dune | 1 - src/app/zkapps_examples/test/actions/dune | 1 - src/app/zkapps_examples/test/add_events/dune | 1 - src/app/zkapps_examples/test/big_circuit/dune | 1 - src/app/zkapps_examples/test/calls/dune | 1 - src/app/zkapps_examples/test/empty_update/dune | 1 - src/app/zkapps_examples/test/initialize_state/dune | 1 - src/app/zkapps_examples/test/optional_custom_gates/dune | 1 - src/app/zkapps_examples/test/tokens/dune | 1 - src/app/zkapps_examples/tokens/dune | 1 - src/lib/allocation_functor/dune | 1 - src/lib/base58_check/dune | 1 - src/lib/best_tip_prover/dune | 1 - src/lib/bignum_bigint/dune | 1 - src/lib/blake2/dune | 1 - src/lib/block_producer/dune | 1 - src/lib/block_time/dune | 1 - src/lib/blockchain_snark/dune | 1 - src/lib/bootstrap_controller/dune | 1 - src/lib/cache_dir/fake/dune | 1 - src/lib/cache_dir/native/dune | 1 - src/lib/cache_lib/dune | 1 - src/lib/child_processes/dune | 1 - src/lib/cli_lib/dune | 1 - src/lib/codable/dune | 1 - src/lib/concurrency/interruptible/dune | 1 - src/lib/concurrency/interruptible/tests/dune | 1 - src/lib/concurrency/pipe_lib/dune | 1 - src/lib/concurrency/pipe_lib/test/dune | 1 - src/lib/consensus/dune | 2 -- src/lib/consensus/vrf/dune | 1 - src/lib/crypto/kimchi_backend/common/dune | 1 - src/lib/crypto/kimchi_backend/common/tests/dune | 1 - src/lib/crypto/kimchi_backend/dune | 1 - src/lib/crypto/kimchi_backend/gadgets/dune | 1 - src/lib/crypto/kimchi_backend/gadgets/runner/dune | 1 - src/lib/crypto/kimchi_backend/gadgets/runner/example/dune | 1 - src/lib/crypto/kimchi_backend/pasta/basic/dune | 1 - .../crypto/kimchi_backend/pasta/constraint_system/caml/dune | 1 - src/lib/crypto/kimchi_backend/pasta/constraint_system/dune | 1 - src/lib/crypto/kimchi_backend/pasta/dune | 1 - src/lib/crypto/kimchi_bindings/js/test/dune | 1 - src/lib/crypto/kimchi_pasta_snarky_backend/dune | 1 - src/lib/crypto/kimchi_pasta_snarky_backend/test/dune | 1 - src/lib/crypto/plonkish_prelude/dune | 1 - src/lib/crypto/plonkish_prelude/test/dune | 1 - src/lib/crypto_params/dune | 1 - src/lib/crypto_params/gen/dune | 1 - src/lib/currency/dune | 1 - src/lib/daemon_rpcs/dune | 1 - src/lib/data_hash_lib/dune | 1 - src/lib/disk_cache/intf/dune | 1 - src/lib/disk_cache/lmdb/dune | 1 - src/lib/disk_cache/test/dune | 1 - src/lib/dummy_values/dune | 1 - src/lib/dummy_values/gen_values/dune | 1 - src/lib/fields_derivers_graphql/dune | 1 - src/lib/fields_derivers_json/dune | 1 - src/lib/fields_derivers_zkapps/dune | 1 - src/lib/fields_derivers_zkapps/test/dune | 1 - src/lib/filtered_external_transition/dune | 1 - src/lib/generated_graphql_queries/gen/dune | 1 - src/lib/genesis_constants/dune | 1 - src/lib/genesis_ledger_helper/dune | 1 - src/lib/genesis_ledger_helper/lib/dune | 1 - src/lib/genesis_proof/dune | 1 - src/lib/gossip_net/dune | 1 - src/lib/graphql_basic_scalars/dune | 1 - src/lib/graphql_basic_scalars/test/dune | 1 - src/lib/graphql_lib/block_time/dune | 1 - src/lib/graphql_lib/consensus/dune | 1 - src/lib/graphql_lib/currency/dune | 1 - src/lib/graphql_lib/data_hash_lib/dune | 1 - src/lib/graphql_lib/dune | 1 - src/lib/graphql_lib/filtered_external_transition/dune | 1 - src/lib/graphql_lib/mina_base/dune | 1 - src/lib/graphql_lib/mina_block/dune | 1 - src/lib/graphql_lib/mina_numbers/dune | 1 - src/lib/graphql_lib/pickles/dune | 1 - src/lib/graphql_lib/pickles/test/dune | 1 - src/lib/graphql_lib/signature_lib/dune | 1 - src/lib/graphql_lib/snark_params/dune | 1 - src/lib/graphql_lib/transaction/dune | 1 - src/lib/hash_prefix_states/dune | 1 - src/lib/internal_tracing/context_call/dune | 1 - src/lib/key_cache/async/dune | 1 - src/lib/key_cache/sync/dune | 1 - src/lib/ledger_proof/dune | 1 - src/lib/lmdb_storage/test/dune | 1 - src/lib/logger/context_logger/dune | 1 - src/lib/logger/dune | 1 - src/lib/logger/fake/dune | 1 - src/lib/logger/native/dune | 1 - src/lib/logger/test/dune | 1 - src/lib/logproc_lib/dune | 2 -- src/lib/merkle_address/dune | 1 - src/lib/merkle_ledger/dune | 1 - src/lib/merkle_ledger/test/dune | 1 - src/lib/merkle_mask/dune | 1 - src/lib/mina_base/dune | 1 - src/lib/mina_base/test/dune | 1 - src/lib/mina_base/test/fee_excess/dune | 1 - src/lib/mina_base/test/helpers/dune | 1 - src/lib/mina_base/util/dune | 1 - src/lib/mina_caqti/dune | 1 - src/lib/mina_commands/dune | 1 - src/lib/mina_compile_config/dune | 1 - src/lib/mina_graphql/dune | 1 - src/lib/mina_intf/dune | 1 - src/lib/mina_ledger/dune | 1 - src/lib/mina_ledger/test/helpers/dune | 1 - src/lib/mina_lib/dune | 1 - src/lib/mina_lib/tests/dune | 1 - src/lib/mina_lmdb_storage/dune | 1 - src/lib/mina_metrics/prometheus_metrics/dune | 1 - src/lib/mina_net2/dune | 1 - src/lib/mina_net2/tests/dune | 1 - src/lib/mina_networking/dune | 1 - src/lib/mina_numbers/dune | 1 - src/lib/mina_plugins/dune | 1 - src/lib/mina_plugins/examples/do_nothing/dune | 1 - src/lib/mina_stdlib/dune | 1 - src/lib/mina_stdlib/tests/dune | 1 - src/lib/mina_stdlib_unix/dune | 1 - src/lib/network_peer/dune | 1 - src/lib/network_pool/test/dune | 1 - src/lib/node_addrs_and_ports/dune | 1 - src/lib/node_error_service/dune | 1 - src/lib/node_status_service/dune | 1 - src/lib/non_zero_curve_point/dune | 1 - src/lib/o1js_stub/dune | 1 - src/lib/o1trace/dune | 1 - src/lib/o1trace/webkit_event/dune | 1 - src/lib/one_or_two/dune | 1 - src/lib/otp_lib/dune | 1 - src/lib/parallel_scan/dune | 1 - src/lib/perf_histograms/dune | 1 - src/lib/pickles/composition_types/dune | 1 - src/lib/pickles/dune | 1 - src/lib/pickles/limb_vector/dune | 1 - src/lib/pickles/plonk_checks/dune | 1 - src/lib/pickles/plonk_checks/gen_scalars/dune | 1 - src/lib/pickles/pseudo/dune | 1 - src/lib/pickles/snarky_tests/dune | 1 - src/lib/pickles/test/chunked_circuits/dune | 1 - src/lib/pickles/test/dune | 1 - src/lib/pickles/test/optional_custom_gates/dune | 1 - src/lib/pickles/test/optional_custom_gates/test_gadgets/dune | 1 - src/lib/pickles_base/dune | 1 - src/lib/pickles_base/one_hot_vector/dune | 1 - src/lib/pickles_base/test/dune | 1 - src/lib/pickles_types/dune | 1 - src/lib/ppx_mina/dune | 1 - src/lib/ppx_register_event/dune | 1 - src/lib/ppx_util/dune | 1 - src/lib/ppx_version/dune | 1 - src/lib/precomputed_values/dune | 1 - src/lib/proof_cache_tag/dune | 1 - src/lib/proof_carrying_data/dune | 1 - src/lib/protocol_version/dune | 1 - src/lib/prover/dune | 1 - src/lib/random_oracle/dune | 1 - src/lib/random_oracle/permutation/external/dune | 1 - src/lib/random_oracle/permutation/ocaml/dune | 1 - src/lib/rocksdb/dune | 1 - src/lib/rocksdb/tests/dune | 1 - src/lib/rosetta_coding/dune | 1 - src/lib/rosetta_coding/test/dune | 1 - src/lib/rosetta_lib/dune | 1 - src/lib/rosetta_lib/test/dune | 1 - src/lib/runtime_config/dune | 1 - src/lib/secrets/dune | 1 - src/lib/sgn/dune | 1 - src/lib/sgn_type/dune | 1 - src/lib/signature_lib/dune | 1 - src/lib/signature_lib/find_address/dune | 1 - src/lib/snark_bits/dune | 1 - src/lib/snark_params/dune | 1 - src/lib/snark_params/test/dune | 1 - src/lib/snark_profiler_lib/dune | 1 - src/lib/snark_work_lib/dune | 1 - src/lib/snark_worker/dune | 1 - src/lib/snark_worker/standalone/dune | 1 - src/lib/snarky_blake2/dune | 1 - src/lib/snarky_blake2/test/dune | 1 - src/lib/snarky_curves/dune | 1 - src/lib/snarky_field_extensions/dune | 1 - src/lib/snarky_group_map/dune | 1 - src/lib/snarky_taylor/dune | 1 - src/lib/snarky_taylor/tests/dune | 1 - src/lib/sparse_ledger_lib/dune | 1 - src/lib/staged_ledger/test/dune | 1 - src/lib/staged_ledger_diff/dune | 1 - src/lib/storage/dune | 1 - src/lib/string_sign/dune | 1 - src/lib/string_sign/tests/dune | 1 - src/lib/structured_log_events/dune | 1 - src/lib/sync_handler/dune | 1 - src/lib/sync_status/dune | 1 - src/lib/sync_status/tests/dune | 1 - src/lib/syncable_ledger/dune | 1 - src/lib/syncable_ledger/test/dune | 1 - src/lib/testing/integration_test_lib/dune | 1 - src/lib/testing/integration_test_local_engine/dune | 1 - src/lib/testing/itn_crypto/dune | 1 - src/lib/testing/quickcheck_lib/dune | 1 - src/lib/testing/test_util/dune | 1 - src/lib/timeout_lib/dune | 1 - src/lib/transaction/dune | 1 - src/lib/transaction_inclusion_status/dune | 1 - src/lib/transaction_logic/dune | 1 - src/lib/transaction_logic/test/dune | 1 - src/lib/transaction_logic/test/transaction_logic/dune | 1 - src/lib/transaction_protocol_state/dune | 1 - src/lib/transaction_snark/test/access_permission/dune | 1 - src/lib/transaction_snark/test/account_timing/dune | 1 - src/lib/transaction_snark/test/account_update_network_id/dune | 1 - src/lib/transaction_snark/test/app_state/dune | 1 - src/lib/transaction_snark/test/delegate/dune | 1 - src/lib/transaction_snark/test/dune | 1 - src/lib/transaction_snark/test/fee_payer/dune | 1 - src/lib/transaction_snark/test/multisig_account/dune | 1 - src/lib/transaction_snark/test/permissions/dune | 1 - src/lib/transaction_snark/test/token_symbol/dune | 1 - src/lib/transaction_snark/test/transaction_union/dune | 1 - src/lib/transaction_snark/test/verification_key/dune | 1 - .../transaction_snark/test/verification_key_permission/dune | 1 - src/lib/transaction_snark/test/verify-simple-test/dune | 1 - src/lib/transaction_snark/test/voting_for/dune | 1 - src/lib/transaction_snark/test/zkapp_deploy/dune | 1 - src/lib/transaction_snark/test/zkapp_fuzzy/dune | 1 - src/lib/transaction_snark/test/zkapp_payments/dune | 1 - src/lib/transaction_snark/test/zkapp_preconditions/dune | 1 - src/lib/transaction_snark/test/zkapp_tokens/dune | 1 - src/lib/transaction_snark/test/zkapp_uri/dune | 1 - src/lib/transaction_snark_scan_state/dune | 1 - src/lib/transaction_snark_work/dune | 1 - src/lib/transaction_witness/dune | 1 - src/lib/transition_chain_prover/dune | 1 - src/lib/transition_chain_verifier/dune | 1 - src/lib/transition_frontier/extensions/dune | 1 - src/lib/transition_frontier/frontier_base/dune | 1 - src/lib/transition_frontier/full_frontier/dune | 1 - src/lib/transition_frontier/persistent_frontier/dune | 1 - src/lib/transition_frontier/persistent_root/dune | 1 - src/lib/transition_frontier/tests/dune | 1 - src/lib/transition_frontier_controller/dune | 1 - src/lib/transition_handler/dune | 1 - src/lib/transition_router/dune | 1 - src/lib/trust_system/dune | 1 - src/lib/unsigned_extended/dune | 1 - src/lib/uptime_service/dune | 1 - src/lib/user_command_input/dune | 1 - src/lib/verifier/dune | 1 - src/lib/vrf_evaluator/dune | 1 - src/lib/vrf_lib/dune | 1 - src/lib/vrf_lib/tests/dune | 1 - src/lib/webkit_trace_event/binary_output/dune | 1 - src/lib/with_hash/dune | 1 - src/lib/work_partitioner/dune | 1 - src/lib/work_selector/dune | 1 - src/lib/zkapp_command_builder/dune | 1 - src/lib/zkapp_vk_cache_tag/dune | 1 - src/libp2p_ipc/dune | 1 - src/test/archive/archive_node_tests/dune | 1 - src/test/archive/patch_archive_test/dune | 1 - src/test/command_line_tests/dune | 1 - src/test/mina_automation/dune | 1 - 303 files changed, 308 deletions(-) diff --git a/src/app/archive/lib/dune b/src/app/archive/lib/dune index ac12da4efab0..b4c3f1ea0450 100644 --- a/src/app/archive/lib/dune +++ b/src/app/archive/lib/dune @@ -15,7 +15,6 @@ caqti-async caqti-driver-postgresql core - core_kernel integers ppx_deriving_yojson.runtime ppx_inline_test.config diff --git a/src/app/archive_blocks/dune b/src/app/archive_blocks/dune index d8bdeb7b9dc8..88e4d10e0b8f 100644 --- a/src/app/archive_blocks/dune +++ b/src/app/archive_blocks/dune @@ -13,7 +13,6 @@ caqti-async caqti-driver-postgresql core - core_kernel result stdio uri diff --git a/src/app/archive_hardfork_toolbox/dune b/src/app/archive_hardfork_toolbox/dune index 477f062df96a..d8e946524d4c 100644 --- a/src/app/archive_hardfork_toolbox/dune +++ b/src/app/archive_hardfork_toolbox/dune @@ -13,7 +13,6 @@ caqti cli_lib async - core_kernel caqti-async base integers @@ -70,7 +69,6 @@ caqti cli_lib async - core_kernel caqti-async base async.async_command diff --git a/src/app/archive_hardfork_toolbox/tests/dune b/src/app/archive_hardfork_toolbox/tests/dune index f3de2b8ae7b9..01c4933bb056 100644 --- a/src/app/archive_hardfork_toolbox/tests/dune +++ b/src/app/archive_hardfork_toolbox/tests/dune @@ -12,7 +12,6 @@ caqti-driver-postgresql caqti async - core_kernel caqti-async base threads.posix diff --git a/src/app/batch_txn_tool/dune b/src/app/batch_txn_tool/dune index d39bb3906b4e..a4c1cbd63044 100644 --- a/src/app/batch_txn_tool/dune +++ b/src/app/batch_txn_tool/dune @@ -8,7 +8,6 @@ integers base uri - core_kernel core async async_kernel diff --git a/src/app/benchmarks/dune b/src/app/benchmarks/dune index c7838cbc6412..6930f76f98e8 100644 --- a/src/app/benchmarks/dune +++ b/src/app/benchmarks/dune @@ -5,7 +5,6 @@ core_bench.inline_benchmarks vrf_lib_tests mina_base - core_kernel core base mina_stdlib diff --git a/src/app/best_tip_merger/dune b/src/app/best_tip_merger/dune index 44b1e888bb00..d97df795aa3f 100644 --- a/src/app/best_tip_merger/dune +++ b/src/app/best_tip_merger/dune @@ -10,7 +10,6 @@ stdio yojson lib - core_kernel async ppx_deriving_yojson.runtime core diff --git a/src/app/cli/src/cli_entrypoint/dune b/src/app/cli/src/cli_entrypoint/dune index ad9cdc54cd1f..5f5c722127eb 100644 --- a/src/app/cli/src/cli_entrypoint/dune +++ b/src/app/cli/src/cli_entrypoint/dune @@ -8,7 +8,6 @@ async_kernel async_unix base - core_kernel core bin_prot bin_prot.shape diff --git a/src/app/cli/src/init/dune b/src/app/cli/src/init/dune index ce9d14b9293b..dc40f6cbc679 100644 --- a/src/app/cli/src/init/dune +++ b/src/app/cli/src/init/dune @@ -21,7 +21,6 @@ async_kernel async_unix uri - core_kernel core_kernel.uuid core base diff --git a/src/app/delegation_verify/dune b/src/app/delegation_verify/dune index 13216be45205..cac8067eb266 100644 --- a/src/app/delegation_verify/dune +++ b/src/app/delegation_verify/dune @@ -1,7 +1,6 @@ (executable (name delegation_verify) (libraries - core_kernel async async_kernel async_unix diff --git a/src/app/disk_caching_stats/dune b/src/app/disk_caching_stats/dune index 14f00b4729e2..5ea10c4d591e 100644 --- a/src/app/disk_caching_stats/dune +++ b/src/app/disk_caching_stats/dune @@ -35,7 +35,6 @@ bigarray-compat ; -- core - core_kernel base bin_prot splittable_random diff --git a/src/app/dump_blocks/dune b/src/app/dump_blocks/dune index 0c39ea6b928b..f0622c3f1e96 100644 --- a/src/app/dump_blocks/dune +++ b/src/app/dump_blocks/dune @@ -9,7 +9,6 @@ block_time mina_stdlib core - core_kernel core_unix.command_unix logger mina_base diff --git a/src/app/extract_blocks/dune b/src/app/extract_blocks/dune index cd583494f1cb..d464b65db099 100644 --- a/src/app/extract_blocks/dune +++ b/src/app/extract_blocks/dune @@ -11,7 +11,6 @@ caqti-async caqti-driver-postgresql async - core_kernel caqti async_kernel uri diff --git a/src/app/heap_usage/dune b/src/app/heap_usage/dune index b37904234fa9..0a7e0708c1ea 100644 --- a/src/app/heap_usage/dune +++ b/src/app/heap_usage/dune @@ -10,7 +10,6 @@ async_kernel stdio async - core_kernel base base.base_internalhash_types async.async_command diff --git a/src/app/ledger_export_bench/dune b/src/app/ledger_export_bench/dune index 0416fdc406a5..1e940bf468f1 100644 --- a/src/app/ledger_export_bench/dune +++ b/src/app/ledger_export_bench/dune @@ -6,7 +6,6 @@ base core core_bench - core_kernel yojson ; mina libraries mina_runtime_config) diff --git a/src/app/logproc/dune b/src/app/logproc/dune index 11660a270dc3..9ceee5a29418 100644 --- a/src/app/logproc/dune +++ b/src/app/logproc/dune @@ -9,7 +9,6 @@ core yojson cmdliner - core_kernel ppx_deriving_yojson.runtime ;;local libraries logger diff --git a/src/app/missing_blocks_auditor/dune b/src/app/missing_blocks_auditor/dune index 04c1502132cd..90816a9859ac 100644 --- a/src/app/missing_blocks_auditor/dune +++ b/src/app/missing_blocks_auditor/dune @@ -10,7 +10,6 @@ caqti-driver-postgresql caqti async - core_kernel caqti-async base async_unix diff --git a/src/app/reformat/dune b/src/app/reformat/dune index 90808ab3b1f3..22040fe29d7e 100644 --- a/src/app/reformat/dune +++ b/src/app/reformat/dune @@ -7,7 +7,6 @@ async.async_command async_kernel async_unix - core_kernel sexplib0) (preprocess (pps ppx_jane)) diff --git a/src/app/replayer/dune b/src/app/replayer/dune index bba757a9ec3e..184d41859c79 100644 --- a/src/app/replayer/dune +++ b/src/app/replayer/dune @@ -11,7 +11,6 @@ async bin_prot.shape caqti-async - core_kernel archive_lib caqti-driver-postgresql async_kernel diff --git a/src/app/rosetta/dune b/src/app/rosetta/dune index d1120e13d020..ea4590f7f3b5 100644 --- a/src/app/rosetta/dune +++ b/src/app/rosetta/dune @@ -7,7 +7,6 @@ (libraries lib async - core_kernel base async.async_command core @@ -28,7 +27,6 @@ lib mina_signature_kind.testnet async - core_kernel base async.async_command core @@ -49,7 +47,6 @@ lib mina_signature_kind.mainnet async - core_kernel base async.async_command core diff --git a/src/app/rosetta/indexer_test/dune b/src/app/rosetta/indexer_test/dune index c622c45d1a73..acb229f71d30 100644 --- a/src/app/rosetta/indexer_test/dune +++ b/src/app/rosetta/indexer_test/dune @@ -4,7 +4,6 @@ (libraries lib async - core_kernel base async.async_command core diff --git a/src/app/rosetta/lib/dune b/src/app/rosetta/lib/dune index 78803d5b070a..fbd9a7d6d11c 100644 --- a/src/app/rosetta/lib/dune +++ b/src/app/rosetta/lib/dune @@ -10,7 +10,6 @@ async_unix result base - core_kernel cohttp caqti async diff --git a/src/app/rosetta/ocaml-signer/dune b/src/app/rosetta/ocaml-signer/dune index 0d6c762b1a7b..8c40de8c385e 100644 --- a/src/app/rosetta/ocaml-signer/dune +++ b/src/app/rosetta/ocaml-signer/dune @@ -6,7 +6,6 @@ ;;opam libraries async_kernel core - core_kernel async base lib diff --git a/src/app/runtime_genesis_ledger/dune b/src/app/runtime_genesis_ledger/dune index f838d327f22e..00d38d2006a7 100644 --- a/src/app/runtime_genesis_ledger/dune +++ b/src/app/runtime_genesis_ledger/dune @@ -4,7 +4,6 @@ (libraries ;;opam libraries base - core_kernel async_kernel async core diff --git a/src/app/test_executive/dune b/src/app/test_executive/dune index e9dd80302e82..f79298611bfe 100644 --- a/src/app/test_executive/dune +++ b/src/app/test_executive/dune @@ -10,7 +10,6 @@ base.base_internalhash_types cmdliner core - core_kernel sexplib0 stdio uri diff --git a/src/app/validate_keypair/dune b/src/app/validate_keypair/dune index f12668943f92..1125a43b6543 100644 --- a/src/app/validate_keypair/dune +++ b/src/app/validate_keypair/dune @@ -5,7 +5,6 @@ (modes native) (libraries ;; opam libraries - core_kernel async async_unix ;; local libraries diff --git a/src/app/zkapp_limits/dune b/src/app/zkapp_limits/dune index b6bf94d94831..1c5290dd2221 100644 --- a/src/app/zkapp_limits/dune +++ b/src/app/zkapp_limits/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries mina_base genesis_constants diff --git a/src/app/zkapp_test_transaction/dune b/src/app/zkapp_test_transaction/dune index a5e5bf77d1d0..77e107a5c100 100644 --- a/src/app/zkapp_test_transaction/dune +++ b/src/app/zkapp_test_transaction/dune @@ -6,7 +6,6 @@ ;;opam libraries async.async_command base - core_kernel core async_kernel zkapp_test_transaction_lib diff --git a/src/app/zkapp_test_transaction/lib/dune b/src/app/zkapp_test_transaction/lib/dune index ec914c8c2b33..20d61e2bcc21 100644 --- a/src/app/zkapp_test_transaction/lib/dune +++ b/src/app/zkapp_test_transaction/lib/dune @@ -10,7 +10,6 @@ async async_kernel core - core_kernel base sexplib0 base_quickcheck diff --git a/src/app/zkapps_examples/actions/dune b/src/app/zkapps_examples/actions/dune index 0f23bd27309a..b5a9f653c252 100644 --- a/src/app/zkapps_examples/actions/dune +++ b/src/app/zkapps_examples/actions/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/add_events/dune b/src/app/zkapps_examples/add_events/dune index d8b70325b92d..6bfe67032dcd 100644 --- a/src/app/zkapps_examples/add_events/dune +++ b/src/app/zkapps_examples/add_events/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/big_circuit/dune b/src/app/zkapps_examples/big_circuit/dune index 7dfea27f65c6..55d472d9bc0b 100644 --- a/src/app/zkapps_examples/big_circuit/dune +++ b/src/app/zkapps_examples/big_circuit/dune @@ -2,7 +2,6 @@ (name zkapps_big_circuit) (libraries ;; opam libraries - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/calls/dune b/src/app/zkapps_examples/calls/dune index 0bf875a08106..c8458fed0207 100644 --- a/src/app/zkapps_examples/calls/dune +++ b/src/app/zkapps_examples/calls/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/dune b/src/app/zkapps_examples/dune index e06b451ec56f..cbb7f4af3452 100644 --- a/src/app/zkapps_examples/dune +++ b/src/app/zkapps_examples/dune @@ -5,7 +5,6 @@ ;; opam libraries async_kernel base - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/empty_update/dune b/src/app/zkapps_examples/empty_update/dune index 11e0c98a278d..00a8b57637a0 100644 --- a/src/app/zkapps_examples/empty_update/dune +++ b/src/app/zkapps_examples/empty_update/dune @@ -2,7 +2,6 @@ (name zkapps_empty_update) (libraries ;; opam libraries - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/initialize_state/dune b/src/app/zkapps_examples/initialize_state/dune index 63590bd026c5..e134f193b547 100644 --- a/src/app/zkapps_examples/initialize_state/dune +++ b/src/app/zkapps_examples/initialize_state/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries crypto_params currency diff --git a/src/app/zkapps_examples/test/actions/dune b/src/app/zkapps_examples/test/actions/dune index 807a26d8e795..28bbe9a76cfb 100644 --- a/src/app/zkapps_examples/test/actions/dune +++ b/src/app/zkapps_examples/test/actions/dune @@ -7,7 +7,6 @@ async_kernel async_unix core - core_kernel yojson ;; local libraries cache_dir diff --git a/src/app/zkapps_examples/test/add_events/dune b/src/app/zkapps_examples/test/add_events/dune index 3b904fa39fc8..5d7efa87f103 100644 --- a/src/app/zkapps_examples/test/add_events/dune +++ b/src/app/zkapps_examples/test/add_events/dune @@ -7,7 +7,6 @@ async_kernel async_unix core - core_kernel ;; local libraries cache_dir currency diff --git a/src/app/zkapps_examples/test/big_circuit/dune b/src/app/zkapps_examples/test/big_circuit/dune index 8bc8657f236b..dc3a854b0b3f 100644 --- a/src/app/zkapps_examples/test/big_circuit/dune +++ b/src/app/zkapps_examples/test/big_circuit/dune @@ -8,7 +8,6 @@ async_unix base core - core_kernel yojson ;; local libraries cache_dir diff --git a/src/app/zkapps_examples/test/calls/dune b/src/app/zkapps_examples/test/calls/dune index 5d6661ad1ede..552d88100885 100644 --- a/src/app/zkapps_examples/test/calls/dune +++ b/src/app/zkapps_examples/test/calls/dune @@ -8,7 +8,6 @@ async_unix base core - core_kernel yojson ;; local libraries cache_dir diff --git a/src/app/zkapps_examples/test/empty_update/dune b/src/app/zkapps_examples/test/empty_update/dune index d5662195441a..6385a147bba2 100644 --- a/src/app/zkapps_examples/test/empty_update/dune +++ b/src/app/zkapps_examples/test/empty_update/dune @@ -8,7 +8,6 @@ async_unix base core - core_kernel yojson ;; local libraries cache_dir diff --git a/src/app/zkapps_examples/test/initialize_state/dune b/src/app/zkapps_examples/test/initialize_state/dune index a0c284f80d8e..25b01b98d9b2 100644 --- a/src/app/zkapps_examples/test/initialize_state/dune +++ b/src/app/zkapps_examples/test/initialize_state/dune @@ -8,7 +8,6 @@ async_unix base core - core_kernel yojson ;; local libraries cache_dir diff --git a/src/app/zkapps_examples/test/optional_custom_gates/dune b/src/app/zkapps_examples/test/optional_custom_gates/dune index ab9bc727d5f3..bf77eb7871e9 100644 --- a/src/app/zkapps_examples/test/optional_custom_gates/dune +++ b/src/app/zkapps_examples/test/optional_custom_gates/dune @@ -8,7 +8,6 @@ async_unix base core - core_kernel integers result sexplib0 diff --git a/src/app/zkapps_examples/test/tokens/dune b/src/app/zkapps_examples/test/tokens/dune index 8574bf892d39..13dc4edf8bfe 100644 --- a/src/app/zkapps_examples/test/tokens/dune +++ b/src/app/zkapps_examples/test/tokens/dune @@ -7,7 +7,6 @@ async_unix base core - core_kernel ppx_inline_test.config yojson ;; local libraries diff --git a/src/app/zkapps_examples/tokens/dune b/src/app/zkapps_examples/tokens/dune index d9f359830bda..64befca39948 100644 --- a/src/app/zkapps_examples/tokens/dune +++ b/src/app/zkapps_examples/tokens/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - core_kernel ;; local libraries cache_dir crypto_params diff --git a/src/lib/allocation_functor/dune b/src/lib/allocation_functor/dune index 4e3a2b14d424..ebbb5ef356db 100644 --- a/src/lib/allocation_functor/dune +++ b/src/lib/allocation_functor/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel result ppx_inline_test.config sexplib0 diff --git a/src/lib/base58_check/dune b/src/lib/base58_check/dune index 822fff46236a..f34bab46530e 100644 --- a/src/lib/base58_check/dune +++ b/src/lib/base58_check/dune @@ -7,7 +7,6 @@ ;; opam libraries base base58 - core_kernel digestif ppx_inline_test.config) (library_flags (-linkall)) diff --git a/src/lib/best_tip_prover/dune b/src/lib/best_tip_prover/dune index 90721ba85a26..01923d1ea417 100644 --- a/src/lib/best_tip_prover/dune +++ b/src/lib/best_tip_prover/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries core - core_kernel async_kernel ;; local libraries genesis_constants diff --git a/src/lib/bignum_bigint/dune b/src/lib/bignum_bigint/dune index a00bfaf91666..ff3ef96bc18c 100644 --- a/src/lib/bignum_bigint/dune +++ b/src/lib/bignum_bigint/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel async_kernel bignum.bigint ;; local libraries diff --git a/src/lib/blake2/dune b/src/lib/blake2/dune index 07cdd56685e4..6cf82d603159 100644 --- a/src/lib/blake2/dune +++ b/src/lib/blake2/dune @@ -12,7 +12,6 @@ base.base_internalhash_types bigarray-compat bin_prot.shape - core_kernel digestif ppx_inline_test.config sexplib0 diff --git a/src/lib/block_producer/dune b/src/lib/block_producer/dune index a4443863a2ac..a77a9c3ed111 100644 --- a/src/lib/block_producer/dune +++ b/src/lib/block_producer/dune @@ -9,7 +9,6 @@ async async_kernel core - core_kernel integers sexplib0 ;; local libraries diff --git a/src/lib/block_time/dune b/src/lib/block_time/dune index 2654e12cf465..5940668cc003 100644 --- a/src/lib/block_time/dune +++ b/src/lib/block_time/dune @@ -10,7 +10,6 @@ bin_prot.shape sexplib0 async_kernel - core_kernel base base.base_internalhash_types ;; local libraries diff --git a/src/lib/blockchain_snark/dune b/src/lib/blockchain_snark/dune index 57c45f37d0e0..3c000ea18271 100644 --- a/src/lib/blockchain_snark/dune +++ b/src/lib/blockchain_snark/dune @@ -11,7 +11,6 @@ base.md5 bin_prot.shape core - core_kernel sexplib0 ;; local libraries allocation_functor diff --git a/src/lib/bootstrap_controller/dune b/src/lib/bootstrap_controller/dune index 825e956b4eae..fe38657da1b6 100644 --- a/src/lib/bootstrap_controller/dune +++ b/src/lib/bootstrap_controller/dune @@ -13,7 +13,6 @@ async_kernel async_unix core - core_kernel ppx_inline_test.config sexplib0 ;; local libraries diff --git a/src/lib/cache_dir/fake/dune b/src/lib/cache_dir/fake/dune index dbcaa3dc472e..8f3363cbcab8 100644 --- a/src/lib/cache_dir/fake/dune +++ b/src/lib/cache_dir/fake/dune @@ -4,7 +4,6 @@ (libraries ; opam deps async_kernel - core_kernel ; libs key_cache) (instrumentation diff --git a/src/lib/cache_dir/native/dune b/src/lib/cache_dir/native/dune index 9724ed7f08ab..6981819484d7 100644 --- a/src/lib/cache_dir/native/dune +++ b/src/lib/cache_dir/native/dune @@ -7,7 +7,6 @@ base core async - core_kernel stdio async_kernel ;; local libraries diff --git a/src/lib/cache_lib/dune b/src/lib/cache_lib/dune index ac5cf7e57222..5048abadf740 100644 --- a/src/lib/cache_lib/dune +++ b/src/lib/cache_lib/dune @@ -9,7 +9,6 @@ base base.base_internalhash_types core - core_kernel ppx_inline_test.config ;; local libraries logger) diff --git a/src/lib/child_processes/dune b/src/lib/child_processes/dune index f66d5ef71ed8..7b8890495ef0 100644 --- a/src/lib/child_processes/dune +++ b/src/lib/child_processes/dune @@ -27,7 +27,6 @@ base base.base_internalhash_types core - core_kernel ctypes ctypes.foreign integers diff --git a/src/lib/cli_lib/dune b/src/lib/cli_lib/dune index d445f5b06809..9cc9433b8650 100644 --- a/src/lib/cli_lib/dune +++ b/src/lib/cli_lib/dune @@ -12,7 +12,6 @@ async_kernel async.async_rpc camlp-streams - core_kernel yojson sodium core diff --git a/src/lib/codable/dune b/src/lib/codable/dune index 10f57fcc3af3..fb3ffd0143c6 100644 --- a/src/lib/codable/dune +++ b/src/lib/codable/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries base64 - core_kernel ppx_deriving_yojson.runtime result yojson diff --git a/src/lib/concurrency/interruptible/dune b/src/lib/concurrency/interruptible/dune index 38306977596d..213c9e19ff98 100644 --- a/src/lib/concurrency/interruptible/dune +++ b/src/lib/concurrency/interruptible/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries async_kernel - core_kernel ;; local libraries run_in_thread) (preprocess diff --git a/src/lib/concurrency/interruptible/tests/dune b/src/lib/concurrency/interruptible/tests/dune index 30221291c162..1865d1e4b95e 100644 --- a/src/lib/concurrency/interruptible/tests/dune +++ b/src/lib/concurrency/interruptible/tests/dune @@ -7,7 +7,6 @@ async_kernel async_unix core - core_kernel interruptible run_in_thread) (preprocess diff --git a/src/lib/concurrency/pipe_lib/dune b/src/lib/concurrency/pipe_lib/dune index 2f7dfe604d52..c2491c90ffba 100644 --- a/src/lib/concurrency/pipe_lib/dune +++ b/src/lib/concurrency/pipe_lib/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries sexplib - core_kernel async_kernel core ppx_inline_test.config diff --git a/src/lib/concurrency/pipe_lib/test/dune b/src/lib/concurrency/pipe_lib/test/dune index 0b26a98747bc..36ffdc97a3be 100644 --- a/src/lib/concurrency/pipe_lib/test/dune +++ b/src/lib/concurrency/pipe_lib/test/dune @@ -5,7 +5,6 @@ alcotest alcotest-async async - core_kernel ;; Local libraries pipe_lib) (preprocess diff --git a/src/lib/consensus/dune b/src/lib/consensus/dune index aae3df6e2547..6af66aaff45d 100644 --- a/src/lib/consensus/dune +++ b/src/lib/consensus/dune @@ -16,7 +16,6 @@ async core yojson - core_kernel bin_prot.shape base result @@ -100,7 +99,6 @@ (name proof_of_stake_fuzzer) (modules proof_of_stake_fuzzer) (libraries - core_kernel signature_lib mina_state mina_block diff --git a/src/lib/consensus/vrf/dune b/src/lib/consensus/vrf/dune index d494cdde21a6..eba74e0e234e 100644 --- a/src/lib/consensus/vrf/dune +++ b/src/lib/consensus/vrf/dune @@ -7,7 +7,6 @@ bignum.bigint base base64 - core_kernel sexplib0 result bignum diff --git a/src/lib/crypto/kimchi_backend/common/dune b/src/lib/crypto/kimchi_backend/common/dune index e4a9e505aa99..dfb41bec287d 100644 --- a/src/lib/crypto/kimchi_backend/common/dune +++ b/src/lib/crypto/kimchi_backend/common/dune @@ -22,7 +22,6 @@ bin_prot.shape integers digestif - core_kernel ppx_inline_test.config bignum.bigint zarith diff --git a/src/lib/crypto/kimchi_backend/common/tests/dune b/src/lib/crypto/kimchi_backend/common/tests/dune index 402f53f567ee..0fe78a106759 100644 --- a/src/lib/crypto/kimchi_backend/common/tests/dune +++ b/src/lib/crypto/kimchi_backend/common/tests/dune @@ -4,7 +4,6 @@ ;; opam libraries alcotest bignum.bigint - core_kernel base digestif ppx_inline_test.config diff --git a/src/lib/crypto/kimchi_backend/dune b/src/lib/crypto/kimchi_backend/dune index fca24483cbd4..99189b9d5e56 100644 --- a/src/lib/crypto/kimchi_backend/dune +++ b/src/lib/crypto/kimchi_backend/dune @@ -12,7 +12,6 @@ ;; opam libraries base.base_internalhash_types bin_prot.shape - core_kernel integers ppx_inline_test.config sexplib0 diff --git a/src/lib/crypto/kimchi_backend/gadgets/dune b/src/lib/crypto/kimchi_backend/gadgets/dune index f6386b04e3f6..e9556538bf6f 100644 --- a/src/lib/crypto/kimchi_backend/gadgets/dune +++ b/src/lib/crypto/kimchi_backend/gadgets/dune @@ -10,7 +10,6 @@ (libraries ;; opam libraries bignum.bigint - core_kernel digestif ppx_inline_test.config zarith diff --git a/src/lib/crypto/kimchi_backend/gadgets/runner/dune b/src/lib/crypto/kimchi_backend/gadgets/runner/dune index 30f6fcc21e30..a1f36a47b361 100644 --- a/src/lib/crypto/kimchi_backend/gadgets/runner/dune +++ b/src/lib/crypto/kimchi_backend/gadgets/runner/dune @@ -11,7 +11,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune b/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune index d5ab06229288..a5c092b00ddb 100644 --- a/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune +++ b/src/lib/crypto/kimchi_backend/gadgets/runner/example/dune @@ -10,7 +10,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/crypto/kimchi_backend/pasta/basic/dune b/src/lib/crypto/kimchi_backend/pasta/basic/dune index 670eaab5c8fb..6532b49fd497 100644 --- a/src/lib/crypto/kimchi_backend/pasta/basic/dune +++ b/src/lib/crypto/kimchi_backend/pasta/basic/dune @@ -12,7 +12,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel bin_prot.shape ;; local libraries sponge diff --git a/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune b/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune index 6a28aa6de673..67b4eebbed12 100644 --- a/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune +++ b/src/lib/crypto/kimchi_backend/pasta/constraint_system/caml/dune @@ -12,7 +12,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel bin_prot.shape ;; local libraries sponge diff --git a/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune b/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune index 25eb2b45262c..7dfb51bbd1eb 100644 --- a/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune +++ b/src/lib/crypto/kimchi_backend/pasta/constraint_system/dune @@ -12,7 +12,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel bin_prot.shape ;; local libraries sponge diff --git a/src/lib/crypto/kimchi_backend/pasta/dune b/src/lib/crypto/kimchi_backend/pasta/dune index 5a8ed9099b27..3fe151ece026 100644 --- a/src/lib/crypto/kimchi_backend/pasta/dune +++ b/src/lib/crypto/kimchi_backend/pasta/dune @@ -12,7 +12,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel bin_prot.shape ;; local libraries sponge diff --git a/src/lib/crypto/kimchi_bindings/js/test/dune b/src/lib/crypto/kimchi_bindings/js/test/dune index d54930341dfb..f553581e68cb 100644 --- a/src/lib/crypto/kimchi_bindings/js/test/dune +++ b/src/lib/crypto/kimchi_bindings/js/test/dune @@ -5,7 +5,6 @@ (libraries base bindings_js - core_kernel digestif.ocaml digestif integers_stubs_js diff --git a/src/lib/crypto/kimchi_pasta_snarky_backend/dune b/src/lib/crypto/kimchi_pasta_snarky_backend/dune index 11810f3bb0cd..5952c609ef66 100644 --- a/src/lib/crypto/kimchi_pasta_snarky_backend/dune +++ b/src/lib/crypto/kimchi_pasta_snarky_backend/dune @@ -9,7 +9,6 @@ (libraries ;; opam libraries integers - core_kernel ppx_inline_test.config sexplib0 bin_prot.shape diff --git a/src/lib/crypto/kimchi_pasta_snarky_backend/test/dune b/src/lib/crypto/kimchi_pasta_snarky_backend/test/dune index 87844b581172..0103587ee42a 100644 --- a/src/lib/crypto/kimchi_pasta_snarky_backend/test/dune +++ b/src/lib/crypto/kimchi_pasta_snarky_backend/test/dune @@ -3,7 +3,6 @@ (libraries alcotest bin_prot.shape - core_kernel kimchi_pasta_snarky_backend hex sexplib0) diff --git a/src/lib/crypto/plonkish_prelude/dune b/src/lib/crypto/plonkish_prelude/dune index 208ece655f0d..737332cfcbff 100644 --- a/src/lib/crypto/plonkish_prelude/dune +++ b/src/lib/crypto/plonkish_prelude/dune @@ -27,7 +27,6 @@ (libraries ;; opam libraries bin_prot.shape - core_kernel result sexplib0 ;; local libraries diff --git a/src/lib/crypto/plonkish_prelude/test/dune b/src/lib/crypto/plonkish_prelude/test/dune index fed9d2205a0f..00b9b8f35eb4 100644 --- a/src/lib/crypto/plonkish_prelude/test/dune +++ b/src/lib/crypto/plonkish_prelude/test/dune @@ -8,7 +8,6 @@ (pps ppx_jane)) (libraries ; Opam - core_kernel alcotest ; Mina plonkish_prelude) diff --git a/src/lib/crypto_params/dune b/src/lib/crypto_params/dune index dbe70077a7e3..d64dc61b6cd4 100644 --- a/src/lib/crypto_params/dune +++ b/src/lib/crypto_params/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries bin_prot.shape - core_kernel sexplib0 ;; local libraries cache_dir diff --git a/src/lib/crypto_params/gen/dune b/src/lib/crypto_params/gen/dune index 92785a4eaed9..1092eda246d1 100644 --- a/src/lib/crypto_params/gen/dune +++ b/src/lib/crypto_params/gen/dune @@ -4,7 +4,6 @@ ;; opam libraries stdio sexplib0 - core_kernel compiler-libs ppxlib ppxlib.astlib diff --git a/src/lib/currency/dune b/src/lib/currency/dune index ce856969b550..13b8f013b49f 100644 --- a/src/lib/currency/dune +++ b/src/lib/currency/dune @@ -9,7 +9,6 @@ base base.base_internalhash_types bin_prot.shape - core_kernel integers ppx_inline_test.config result diff --git a/src/lib/daemon_rpcs/dune b/src/lib/daemon_rpcs/dune index d157a1301d46..e6a1ca5176c7 100644 --- a/src/lib/daemon_rpcs/dune +++ b/src/lib/daemon_rpcs/dune @@ -13,7 +13,6 @@ async_unix bin_prot.shape core - core_kernel ppx_deriving_yojson.runtime sexplib0 yojson diff --git a/src/lib/data_hash_lib/dune b/src/lib/data_hash_lib/dune index 28abd7c0a89c..2f354363a582 100644 --- a/src/lib/data_hash_lib/dune +++ b/src/lib/data_hash_lib/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries base - core_kernel ppx_inline_test.config ;; local libraries base58_check diff --git a/src/lib/disk_cache/intf/dune b/src/lib/disk_cache/intf/dune index 3ffd6c646a35..b674b9e4c747 100644 --- a/src/lib/disk_cache/intf/dune +++ b/src/lib/disk_cache/intf/dune @@ -3,7 +3,6 @@ (public_name disk_cache.intf) (libraries ;; opam libraries - core_kernel async_kernel ;; local libraries logger) diff --git a/src/lib/disk_cache/lmdb/dune b/src/lib/disk_cache/lmdb/dune index 1acc32e220d7..1d68c79fb11c 100644 --- a/src/lib/disk_cache/lmdb/dune +++ b/src/lib/disk_cache/lmdb/dune @@ -4,7 +4,6 @@ (implements disk_cache) (libraries ;; opam libraries - core_kernel core ;; local libraries lmdb_storage diff --git a/src/lib/disk_cache/test/dune b/src/lib/disk_cache/test/dune index 1f2bacc0d401..e288eb24205c 100644 --- a/src/lib/disk_cache/test/dune +++ b/src/lib/disk_cache/test/dune @@ -5,7 +5,6 @@ ;; opam libraries async core - core_kernel ;; local libraries disk_cache_intf logger diff --git a/src/lib/dummy_values/dune b/src/lib/dummy_values/dune index 8fb026206b61..727e5e5c6344 100644 --- a/src/lib/dummy_values/dune +++ b/src/lib/dummy_values/dune @@ -4,7 +4,6 @@ (flags :standard -short-paths) (libraries ;; opam libraries - core_kernel ;; local libraries crypto_params snarky.backendless diff --git a/src/lib/dummy_values/gen_values/dune b/src/lib/dummy_values/gen_values/dune index 88636d0f1278..f9202d356e6e 100644 --- a/src/lib/dummy_values/gen_values/dune +++ b/src/lib/dummy_values/gen_values/dune @@ -11,7 +11,6 @@ ppxlib ppxlib.ast ppxlib.astlib - core_kernel compiler-libs async_kernel ocaml-compiler-libs.common diff --git a/src/lib/fields_derivers_graphql/dune b/src/lib/fields_derivers_graphql/dune index 972630599d63..4ffd19156fc2 100644 --- a/src/lib/fields_derivers_graphql/dune +++ b/src/lib/fields_derivers_graphql/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries async_kernel - core_kernel fieldslib graphql graphql-async diff --git a/src/lib/fields_derivers_json/dune b/src/lib/fields_derivers_json/dune index c619efff0f8e..f4b974041642 100644 --- a/src/lib/fields_derivers_json/dune +++ b/src/lib/fields_derivers_json/dune @@ -3,7 +3,6 @@ (public_name fields_derivers.json) (libraries ;; opam libraries - core_kernel fieldslib ppx_inline_test.config result diff --git a/src/lib/fields_derivers_zkapps/dune b/src/lib/fields_derivers_zkapps/dune index 25fa414ee07d..8fbea7b68fd0 100644 --- a/src/lib/fields_derivers_zkapps/dune +++ b/src/lib/fields_derivers_zkapps/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - core_kernel fieldslib graphql graphql_parser diff --git a/src/lib/fields_derivers_zkapps/test/dune b/src/lib/fields_derivers_zkapps/test/dune index 500bbe6c9eb7..119e55b8dbef 100644 --- a/src/lib/fields_derivers_zkapps/test/dune +++ b/src/lib/fields_derivers_zkapps/test/dune @@ -4,7 +4,6 @@ ;; opam libraries alcotest base - core_kernel fieldslib graphql graphql_parser diff --git a/src/lib/filtered_external_transition/dune b/src/lib/filtered_external_transition/dune index baa25afde8b2..1ff45f348090 100644 --- a/src/lib/filtered_external_transition/dune +++ b/src/lib/filtered_external_transition/dune @@ -7,7 +7,6 @@ base bin_prot.shape core - core_kernel sexplib0 ;; local libraries block_time diff --git a/src/lib/generated_graphql_queries/gen/dune b/src/lib/generated_graphql_queries/gen/dune index c13a6a7a26ff..3cf9afdb88a6 100644 --- a/src/lib/generated_graphql_queries/gen/dune +++ b/src/lib/generated_graphql_queries/gen/dune @@ -2,7 +2,6 @@ (name gen) (libraries base - core_kernel ppxlib ppxlib.ast ppxlib.astlib diff --git a/src/lib/genesis_constants/dune b/src/lib/genesis_constants/dune index 9164a020df88..2f5dfda0f190 100644 --- a/src/lib/genesis_constants/dune +++ b/src/lib/genesis_constants/dune @@ -9,7 +9,6 @@ ppx_inline_test.config base bin_prot.shape - core_kernel sexplib0 integers ;; local libraries diff --git a/src/lib/genesis_ledger_helper/dune b/src/lib/genesis_ledger_helper/dune index a8f4a72704da..3a10ec4dfd73 100644 --- a/src/lib/genesis_ledger_helper/dune +++ b/src/lib/genesis_ledger_helper/dune @@ -9,7 +9,6 @@ core_kernel.uuid async_unix async - core_kernel core async_kernel sexplib0 diff --git a/src/lib/genesis_ledger_helper/lib/dune b/src/lib/genesis_ledger_helper/lib/dune index 7637eb7c5c12..f413a11b963e 100644 --- a/src/lib/genesis_ledger_helper/lib/dune +++ b/src/lib/genesis_ledger_helper/lib/dune @@ -5,7 +5,6 @@ ;; opam libraries splittable_random integers - core_kernel core sexplib0 base64 diff --git a/src/lib/genesis_proof/dune b/src/lib/genesis_proof/dune index cc05c3660856..68f92937a357 100644 --- a/src/lib/genesis_proof/dune +++ b/src/lib/genesis_proof/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - core_kernel base.md5 core async diff --git a/src/lib/gossip_net/dune b/src/lib/gossip_net/dune index 77fb1b92e81c..e5166a872888 100644 --- a/src/lib/gossip_net/dune +++ b/src/lib/gossip_net/dune @@ -14,7 +14,6 @@ async_rpc_kernel async core - core_kernel sexplib0 cohttp-async async_unix diff --git a/src/lib/graphql_basic_scalars/dune b/src/lib/graphql_basic_scalars/dune index 0a952db7fea8..70601d192594 100644 --- a/src/lib/graphql_basic_scalars/dune +++ b/src/lib/graphql_basic_scalars/dune @@ -11,7 +11,6 @@ async async_unix async_kernel - core_kernel integers core graphql diff --git a/src/lib/graphql_basic_scalars/test/dune b/src/lib/graphql_basic_scalars/test/dune index 665adf8dff26..49a2df398fbd 100644 --- a/src/lib/graphql_basic_scalars/test/dune +++ b/src/lib/graphql_basic_scalars/test/dune @@ -11,7 +11,6 @@ async async_unix async_kernel - core_kernel integers core graphql diff --git a/src/lib/graphql_lib/block_time/dune b/src/lib/graphql_lib/block_time/dune index e2732fd4ff57..a2d72f5eb8ed 100644 --- a/src/lib/graphql_lib/block_time/dune +++ b/src/lib/graphql_lib/block_time/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/consensus/dune b/src/lib/graphql_lib/consensus/dune index 64a11a352d4e..ab7453b650ff 100644 --- a/src/lib/graphql_lib/consensus/dune +++ b/src/lib/graphql_lib/consensus/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/currency/dune b/src/lib/graphql_lib/currency/dune index 16f6b7d6d9a8..f8c2f725e667 100644 --- a/src/lib/graphql_lib/currency/dune +++ b/src/lib/graphql_lib/currency/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/data_hash_lib/dune b/src/lib/graphql_lib/data_hash_lib/dune index 3fa9906c42a0..14338d747483 100644 --- a/src/lib/graphql_lib/data_hash_lib/dune +++ b/src/lib/graphql_lib/data_hash_lib/dune @@ -9,7 +9,6 @@ graphql yojson ppx_inline_test.config - core_kernel sexplib0 base ;; local libraries diff --git a/src/lib/graphql_lib/dune b/src/lib/graphql_lib/dune index 949cb83078a7..eef0a3c8c1c5 100644 --- a/src/lib/graphql_lib/dune +++ b/src/lib/graphql_lib/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries uri - core_kernel integers async cohttp diff --git a/src/lib/graphql_lib/filtered_external_transition/dune b/src/lib/graphql_lib/filtered_external_transition/dune index 1cb973182573..d30976019dfd 100644 --- a/src/lib/graphql_lib/filtered_external_transition/dune +++ b/src/lib/graphql_lib/filtered_external_transition/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/mina_base/dune b/src/lib/graphql_lib/mina_base/dune index 9595a3911875..7cf34f92a723 100644 --- a/src/lib/graphql_lib/mina_base/dune +++ b/src/lib/graphql_lib/mina_base/dune @@ -9,7 +9,6 @@ graphql yojson ppx_inline_test.config - core_kernel sexplib0 result base diff --git a/src/lib/graphql_lib/mina_block/dune b/src/lib/graphql_lib/mina_block/dune index f8c3c9551bfc..15ea3c9406a4 100644 --- a/src/lib/graphql_lib/mina_block/dune +++ b/src/lib/graphql_lib/mina_block/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/mina_numbers/dune b/src/lib/graphql_lib/mina_numbers/dune index 842e25b43421..558273f5f9ec 100644 --- a/src/lib/graphql_lib/mina_numbers/dune +++ b/src/lib/graphql_lib/mina_numbers/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/pickles/dune b/src/lib/graphql_lib/pickles/dune index 1dea8980c553..b909dd788e1a 100644 --- a/src/lib/graphql_lib/pickles/dune +++ b/src/lib/graphql_lib/pickles/dune @@ -10,7 +10,6 @@ (libraries ;; opam libraries base - core_kernel graphql sexplib0 yojson diff --git a/src/lib/graphql_lib/pickles/test/dune b/src/lib/graphql_lib/pickles/test/dune index ffa717d4eb4d..c6868b098b10 100644 --- a/src/lib/graphql_lib/pickles/test/dune +++ b/src/lib/graphql_lib/pickles/test/dune @@ -12,7 +12,6 @@ (libraries ; opam libraries alcotest - core_kernel sexplib0 ; local libraries kimchi_pasta diff --git a/src/lib/graphql_lib/signature_lib/dune b/src/lib/graphql_lib/signature_lib/dune index 29a326dfe9ad..79eb0c18462a 100644 --- a/src/lib/graphql_lib/signature_lib/dune +++ b/src/lib/graphql_lib/signature_lib/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/graphql_lib/snark_params/dune b/src/lib/graphql_lib/snark_params/dune index 4d73dbf92b2c..d9f0dcb7b427 100644 --- a/src/lib/graphql_lib/snark_params/dune +++ b/src/lib/graphql_lib/snark_params/dune @@ -9,7 +9,6 @@ graphql yojson ppx_inline_test.config - core_kernel sexplib0 base ;; local libraries diff --git a/src/lib/graphql_lib/transaction/dune b/src/lib/graphql_lib/transaction/dune index 4042dd709d8b..5fa673743f47 100644 --- a/src/lib/graphql_lib/transaction/dune +++ b/src/lib/graphql_lib/transaction/dune @@ -8,7 +8,6 @@ graphql-async graphql yojson - core_kernel core sexplib0 ppx_inline_test.config diff --git a/src/lib/hash_prefix_states/dune b/src/lib/hash_prefix_states/dune index a501814f29be..2d295b77ffe9 100644 --- a/src/lib/hash_prefix_states/dune +++ b/src/lib/hash_prefix_states/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel base ;; local libraries snark_params diff --git a/src/lib/internal_tracing/context_call/dune b/src/lib/internal_tracing/context_call/dune index 6d6a866c2560..af41dfa0bdfa 100644 --- a/src/lib/internal_tracing/context_call/dune +++ b/src/lib/internal_tracing/context_call/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries base.base_internalhash_types - core_kernel sexplib0 async_kernel) (preprocess diff --git a/src/lib/key_cache/async/dune b/src/lib/key_cache/async/dune index 9b8d64785c72..5d8baf5033a7 100644 --- a/src/lib/key_cache/async/dune +++ b/src/lib/key_cache/async/dune @@ -7,7 +7,6 @@ core async_kernel async_unix - core_kernel base ;; local libraries key_cache diff --git a/src/lib/key_cache/sync/dune b/src/lib/key_cache/sync/dune index 3a8533a27c2f..cdb97687a1db 100644 --- a/src/lib/key_cache/sync/dune +++ b/src/lib/key_cache/sync/dune @@ -5,7 +5,6 @@ ;; opam libraries async core - core_kernel base stdio ;; local libraries diff --git a/src/lib/ledger_proof/dune b/src/lib/ledger_proof/dune index 571db19e7c23..334c1ebaf882 100644 --- a/src/lib/ledger_proof/dune +++ b/src/lib/ledger_proof/dune @@ -3,7 +3,6 @@ (public_name ledger_proof) (libraries ;; opam libraries - core_kernel ;; local libraries transaction_snark mina_base diff --git a/src/lib/lmdb_storage/test/dune b/src/lib/lmdb_storage/test/dune index 0c59f9bc957f..9b98f8a5f300 100644 --- a/src/lib/lmdb_storage/test/dune +++ b/src/lib/lmdb_storage/test/dune @@ -5,7 +5,6 @@ alcotest async_kernel base_quickcheck - core_kernel lmdb ;; local libraries blake2 diff --git a/src/lib/logger/context_logger/dune b/src/lib/logger/context_logger/dune index 53175f54f932..17f434c6c7f1 100644 --- a/src/lib/logger/context_logger/dune +++ b/src/lib/logger/context_logger/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries base.base_internalhash_types - core_kernel sexplib0 async_kernel ;; local libraries diff --git a/src/lib/logger/dune b/src/lib/logger/dune index 67e655385a37..2befe937a847 100644 --- a/src/lib/logger/dune +++ b/src/lib/logger/dune @@ -3,7 +3,6 @@ (name logger) (libraries ;; opam libraries - core_kernel sexplib0 ;; local libraries interpolator_lib) diff --git a/src/lib/logger/fake/dune b/src/lib/logger/fake/dune index 36f5f3679611..025cd498538b 100644 --- a/src/lib/logger/fake/dune +++ b/src/lib/logger/fake/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries result - core_kernel sexplib0 bin_prot.shape base.base_internalhash_types diff --git a/src/lib/logger/native/dune b/src/lib/logger/native/dune index 342500399fa7..2b42e7574558 100644 --- a/src/lib/logger/native/dune +++ b/src/lib/logger/native/dune @@ -8,7 +8,6 @@ ;; opam libraries result core - core_kernel sexplib0 bin_prot.shape base.base_internalhash_types diff --git a/src/lib/logger/test/dune b/src/lib/logger/test/dune index 2a0dbeaec17a..e3f58975508e 100644 --- a/src/lib/logger/test/dune +++ b/src/lib/logger/test/dune @@ -5,7 +5,6 @@ alcotest async core - core_kernel ;; local libraries logger logger.file_system) diff --git a/src/lib/logproc_lib/dune b/src/lib/logproc_lib/dune index 3db6c3dcdde5..e6ee38b1a06c 100644 --- a/src/lib/logproc_lib/dune +++ b/src/lib/logproc_lib/dune @@ -4,7 +4,6 @@ (modules logproc_lib filter) (libraries ;; opam libraries - core_kernel yojson angstrom re2 @@ -28,7 +27,6 @@ (modules interpolator) (libraries ;; opam libraries - core_kernel yojson angstrom ;; local libraries diff --git a/src/lib/merkle_address/dune b/src/lib/merkle_address/dune index 3639e66c07b6..2aa45a0b85ea 100644 --- a/src/lib/merkle_address/dune +++ b/src/lib/merkle_address/dune @@ -9,7 +9,6 @@ base.base_internalhash_types bin_prot.shape bitstring - core_kernel sexplib0 ppx_inline_test.config ;; local libraries diff --git a/src/lib/merkle_ledger/dune b/src/lib/merkle_ledger/dune index 89b6db204466..1ccfc7b5af72 100644 --- a/src/lib/merkle_ledger/dune +++ b/src/lib/merkle_ledger/dune @@ -14,7 +14,6 @@ bin_prot.shape bitstring core - core_kernel core_kernel.uuid integers rocks diff --git a/src/lib/merkle_ledger/test/dune b/src/lib/merkle_ledger/test/dune index b581d46b974b..d7b79fc016cb 100644 --- a/src/lib/merkle_ledger/test/dune +++ b/src/lib/merkle_ledger/test/dune @@ -20,7 +20,6 @@ bin_prot.shape codable core - core_kernel core_kernel.uuid currency data_hash_lib diff --git a/src/lib/merkle_mask/dune b/src/lib/merkle_mask/dune index 445ee6768684..725e051a17fe 100644 --- a/src/lib/merkle_mask/dune +++ b/src/lib/merkle_mask/dune @@ -26,7 +26,6 @@ base.base_internalhash_types bitstring core - core_kernel core_kernel.uuid integers sexplib0 diff --git a/src/lib/mina_base/dune b/src/lib/mina_base/dune index 0c55dc89e494..e48cb78e54a3 100644 --- a/src/lib/mina_base/dune +++ b/src/lib/mina_base/dune @@ -14,7 +14,6 @@ yojson digestif sexp_diff_kernel - core_kernel base base.base_internalhash_types integers diff --git a/src/lib/mina_base/test/dune b/src/lib/mina_base/test/dune index d32d72a7de33..15f4e8cf0665 100644 --- a/src/lib/mina_base/test/dune +++ b/src/lib/mina_base/test/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - core_kernel integers sexplib0 yojson diff --git a/src/lib/mina_base/test/fee_excess/dune b/src/lib/mina_base/test/fee_excess/dune index 091a906c5c45..a55cb627bb19 100644 --- a/src/lib/mina_base/test/fee_excess/dune +++ b/src/lib/mina_base/test/fee_excess/dune @@ -4,7 +4,6 @@ ;; opam libraries alcotest base - core_kernel integers ppx_inline_test.config sexplib0 diff --git a/src/lib/mina_base/test/helpers/dune b/src/lib/mina_base/test/helpers/dune index 778aac6be205..cc61a13840d6 100644 --- a/src/lib/mina_base/test/helpers/dune +++ b/src/lib/mina_base/test/helpers/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries base - core_kernel integers sexplib0 yojson diff --git a/src/lib/mina_base/util/dune b/src/lib/mina_base/util/dune index 09026dc377d9..02495277ed69 100644 --- a/src/lib/mina_base/util/dune +++ b/src/lib/mina_base/util/dune @@ -3,7 +3,6 @@ (public_name mina_base.util) (libraries ;; opam libraries - core_kernel ;; local libraries snark_params bignum_bigint) diff --git a/src/lib/mina_caqti/dune b/src/lib/mina_caqti/dune index 9d2f52c4ef61..3beb92f873df 100644 --- a/src/lib/mina_caqti/dune +++ b/src/lib/mina_caqti/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel async caqti-async caqti diff --git a/src/lib/mina_commands/dune b/src/lib/mina_commands/dune index ee7ef90259a8..fb24bc0bbf65 100644 --- a/src/lib/mina_commands/dune +++ b/src/lib/mina_commands/dune @@ -5,7 +5,6 @@ ;; opam libraries async_kernel base - core_kernel core async async_unix diff --git a/src/lib/mina_compile_config/dune b/src/lib/mina_compile_config/dune index b15425ad7e25..5f20899f0e7c 100644 --- a/src/lib/mina_compile_config/dune +++ b/src/lib/mina_compile_config/dune @@ -4,7 +4,6 @@ (libraries mina_node_config mina_node_config.for_unit_tests - core_kernel currency) (instrumentation (backend bisect_ppx)) diff --git a/src/lib/mina_graphql/dune b/src/lib/mina_graphql/dune index 6d2b978a8dbf..d7f00dfd47be 100644 --- a/src/lib/mina_graphql/dune +++ b/src/lib/mina_graphql/dune @@ -13,7 +13,6 @@ core_kernel.uuid core async - core_kernel async_unix result sexplib0 diff --git a/src/lib/mina_intf/dune b/src/lib/mina_intf/dune index 8feb576ab3bb..124ba4333968 100644 --- a/src/lib/mina_intf/dune +++ b/src/lib/mina_intf/dune @@ -5,7 +5,6 @@ ;; opam libraries async_kernel core - core_kernel sexplib0 ;; local libraries mina_net2 diff --git a/src/lib/mina_ledger/dune b/src/lib/mina_ledger/dune index 454737511575..6fb3bdebff09 100644 --- a/src/lib/mina_ledger/dune +++ b/src/lib/mina_ledger/dune @@ -22,7 +22,6 @@ async_kernel base core - core_kernel sexplib0 bin_prot.shape base.base_internalhash_types diff --git a/src/lib/mina_ledger/test/helpers/dune b/src/lib/mina_ledger/test/helpers/dune index eea57aea1f52..c2ff9f8b33cc 100644 --- a/src/lib/mina_ledger/test/helpers/dune +++ b/src/lib/mina_ledger/test/helpers/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel core integers sexplib0 diff --git a/src/lib/mina_lib/dune b/src/lib/mina_lib/dune index 26a23cbb0761..37c4314b0cbc 100644 --- a/src/lib/mina_lib/dune +++ b/src/lib/mina_lib/dune @@ -13,7 +13,6 @@ core async incremental - core_kernel async_kernel base.base_internalhash_types uri diff --git a/src/lib/mina_lib/tests/dune b/src/lib/mina_lib/tests/dune index 3000dada9482..cc6677a26920 100644 --- a/src/lib/mina_lib/tests/dune +++ b/src/lib/mina_lib/tests/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries core - core_kernel core_kernel.uuid async_kernel async diff --git a/src/lib/mina_lmdb_storage/dune b/src/lib/mina_lmdb_storage/dune index 38a0046386db..0668942b078c 100644 --- a/src/lib/mina_lmdb_storage/dune +++ b/src/lib/mina_lmdb_storage/dune @@ -13,7 +13,6 @@ libp2p_ipc yojson async_kernel - core_kernel bin_prot.shape ppx_inline_test.config async_unix diff --git a/src/lib/mina_metrics/prometheus_metrics/dune b/src/lib/mina_metrics/prometheus_metrics/dune index 4439d1d76d85..6da875398a00 100644 --- a/src/lib/mina_metrics/prometheus_metrics/dune +++ b/src/lib/mina_metrics/prometheus_metrics/dune @@ -10,7 +10,6 @@ base core async_kernel - core_kernel prometheus cohttp-async cohttp diff --git a/src/lib/mina_net2/dune b/src/lib/mina_net2/dune index a85d7d2cffa6..418964bd884c 100644 --- a/src/lib/mina_net2/dune +++ b/src/lib/mina_net2/dune @@ -13,7 +13,6 @@ libp2p_ipc yojson async_kernel - core_kernel bin_prot.shape ppx_inline_test.config async_unix diff --git a/src/lib/mina_net2/tests/dune b/src/lib/mina_net2/tests/dune index e17642b5d30e..55d818d4408f 100644 --- a/src/lib/mina_net2/tests/dune +++ b/src/lib/mina_net2/tests/dune @@ -7,7 +7,6 @@ ppx_inline_test.config async_kernel async_unix - core_kernel sexplib0 bin_prot.shape ;; local libraries diff --git a/src/lib/mina_networking/dune b/src/lib/mina_networking/dune index 556363b902d5..74a33e05f20c 100644 --- a/src/lib/mina_networking/dune +++ b/src/lib/mina_networking/dune @@ -8,7 +8,6 @@ result core async - core_kernel sexplib0 base bin_prot.shape diff --git a/src/lib/mina_numbers/dune b/src/lib/mina_numbers/dune index e98ba965ce48..1c623e32e2ae 100644 --- a/src/lib/mina_numbers/dune +++ b/src/lib/mina_numbers/dune @@ -9,7 +9,6 @@ result bin_prot.shape bignum.bigint - core_kernel integers sexplib0 base diff --git a/src/lib/mina_plugins/dune b/src/lib/mina_plugins/dune index 2424ddf47fb2..06585567dd9a 100644 --- a/src/lib/mina_plugins/dune +++ b/src/lib/mina_plugins/dune @@ -3,7 +3,6 @@ (name mina_plugins) (libraries ;; opam libraries - core_kernel dynlink core base diff --git a/src/lib/mina_plugins/examples/do_nothing/dune b/src/lib/mina_plugins/examples/do_nothing/dune index c45ec56935c1..fcf90d1f4210 100644 --- a/src/lib/mina_plugins/examples/do_nothing/dune +++ b/src/lib/mina_plugins/examples/do_nothing/dune @@ -2,7 +2,6 @@ (name plugin_do_nothing) (libraries ;; opam libraries - core_kernel core ;; local libraries mina_plugins diff --git a/src/lib/mina_stdlib/dune b/src/lib/mina_stdlib/dune index f24e07e79756..4403e73d6fd6 100644 --- a/src/lib/mina_stdlib/dune +++ b/src/lib/mina_stdlib/dune @@ -13,7 +13,6 @@ async_kernel bin_prot bin_prot.shape - core_kernel ppx_inline_test.config result sexplib0 diff --git a/src/lib/mina_stdlib/tests/dune b/src/lib/mina_stdlib/tests/dune index 28f28fc43fb4..4876378f1358 100644 --- a/src/lib/mina_stdlib/tests/dune +++ b/src/lib/mina_stdlib/tests/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - core_kernel sexplib0 yojson ;; local libraries diff --git a/src/lib/mina_stdlib_unix/dune b/src/lib/mina_stdlib_unix/dune index a4526013fa3a..d110adf3d10e 100644 --- a/src/lib/mina_stdlib_unix/dune +++ b/src/lib/mina_stdlib_unix/dune @@ -8,7 +8,6 @@ async_kernel async_unix core - core_kernel ptime ;; local libraries logger) diff --git a/src/lib/network_peer/dune b/src/lib/network_peer/dune index faa06eb1391e..b9018b013fbf 100644 --- a/src/lib/network_peer/dune +++ b/src/lib/network_peer/dune @@ -7,7 +7,6 @@ async async.async_rpc async_rpc_kernel - core_kernel bin_prot.shape sexplib0 base.base_internalhash_types diff --git a/src/lib/network_pool/test/dune b/src/lib/network_pool/test/dune index 363441351aad..dea63913b953 100644 --- a/src/lib/network_pool/test/dune +++ b/src/lib/network_pool/test/dune @@ -7,7 +7,6 @@ async_unix base base.base_internalhash_types - core_kernel core integers sexplib0 diff --git a/src/lib/node_addrs_and_ports/dune b/src/lib/node_addrs_and_ports/dune index 17f7e5b1f8a6..38775f12d267 100644 --- a/src/lib/node_addrs_and_ports/dune +++ b/src/lib/node_addrs_and_ports/dune @@ -7,7 +7,6 @@ async yojson sexplib0 - core_kernel bin_prot.shape ;; local libraries network_peer diff --git a/src/lib/node_error_service/dune b/src/lib/node_error_service/dune index b9af2f095f23..89aa6938232a 100644 --- a/src/lib/node_error_service/dune +++ b/src/lib/node_error_service/dune @@ -8,7 +8,6 @@ uri cohttp-async async - core_kernel core cohttp async_kernel diff --git a/src/lib/node_status_service/dune b/src/lib/node_status_service/dune index e87e1b910eca..4b85ee0940eb 100644 --- a/src/lib/node_status_service/dune +++ b/src/lib/node_status_service/dune @@ -9,7 +9,6 @@ core.linux_ext cohttp-async async - core_kernel cohttp async_kernel uri diff --git a/src/lib/non_zero_curve_point/dune b/src/lib/non_zero_curve_point/dune index cf046a41bbbd..80b214a3da59 100644 --- a/src/lib/non_zero_curve_point/dune +++ b/src/lib/non_zero_curve_point/dune @@ -9,7 +9,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel bin_prot.shape base base.base_internalhash_types diff --git a/src/lib/o1js_stub/dune b/src/lib/o1js_stub/dune index 86b13d5947c6..5f58aae04c4a 100644 --- a/src/lib/o1js_stub/dune +++ b/src/lib/o1js_stub/dune @@ -9,7 +9,6 @@ ../crypto/kimchi_bindings/js/node_js/plonk_wasm_bg.wasm) (libraries ;; opam libraries ;; - core_kernel base integers sexplib0 diff --git a/src/lib/o1trace/dune b/src/lib/o1trace/dune index b9f3aa249214..9adf734b979b 100644 --- a/src/lib/o1trace/dune +++ b/src/lib/o1trace/dune @@ -8,7 +8,6 @@ async_unix base.base_internalhash_types core - core_kernel ocamlgraph ppx_inline_test.config sexplib0 diff --git a/src/lib/o1trace/webkit_event/dune b/src/lib/o1trace/webkit_event/dune index 92d0aa6ee59e..f732f0b7441f 100644 --- a/src/lib/o1trace/webkit_event/dune +++ b/src/lib/o1trace/webkit_event/dune @@ -9,7 +9,6 @@ async_unix core core.time_stamp_counter - core_kernel sexplib0 ;; local libraries webkit_trace_event.binary diff --git a/src/lib/one_or_two/dune b/src/lib/one_or_two/dune index 52d7f9f23593..ed259b8dccdc 100644 --- a/src/lib/one_or_two/dune +++ b/src/lib/one_or_two/dune @@ -8,7 +8,6 @@ bin_prot.shape base async_kernel - core_kernel ppx_hash.runtime-lib sexplib0 ppx_version.runtime) diff --git a/src/lib/otp_lib/dune b/src/lib/otp_lib/dune index 52a6f296603f..f8e1381ced80 100644 --- a/src/lib/otp_lib/dune +++ b/src/lib/otp_lib/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel async_kernel ppx_inline_test.config ;; local libraries diff --git a/src/lib/parallel_scan/dune b/src/lib/parallel_scan/dune index 1b2ede0d19ef..f30b8a0c3965 100644 --- a/src/lib/parallel_scan/dune +++ b/src/lib/parallel_scan/dune @@ -8,7 +8,6 @@ ;; opam libraries ppx_inline_test.config base - core_kernel sexplib0 async digestif diff --git a/src/lib/perf_histograms/dune b/src/lib/perf_histograms/dune index c6c4c28be76e..a08833574e43 100644 --- a/src/lib/perf_histograms/dune +++ b/src/lib/perf_histograms/dune @@ -13,7 +13,6 @@ yojson async core - core_kernel ppx_deriving_yojson.runtime async.async_rpc async_kernel diff --git a/src/lib/pickles/composition_types/dune b/src/lib/pickles/composition_types/dune index 3d05d3326fd8..5a9fe6f8e36b 100644 --- a/src/lib/pickles/composition_types/dune +++ b/src/lib/pickles/composition_types/dune @@ -32,7 +32,6 @@ ;; opam libraries sexplib0 bin_prot.shape - core_kernel ;; local libraries mina_wire_types kimchi_pasta diff --git a/src/lib/pickles/dune b/src/lib/pickles/dune index e47badd46eeb..7662ca8db4a9 100644 --- a/src/lib/pickles/dune +++ b/src/lib/pickles/dune @@ -21,7 +21,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/pickles/limb_vector/dune b/src/lib/pickles/limb_vector/dune index 6c0319e5a94a..97c0ffb05a85 100644 --- a/src/lib/pickles/limb_vector/dune +++ b/src/lib/pickles/limb_vector/dune @@ -14,7 +14,6 @@ ;; opam libraries bin_prot.shape sexplib0 - core_kernel result ;; local libraries snarky.backendless diff --git a/src/lib/pickles/plonk_checks/dune b/src/lib/pickles/plonk_checks/dune index 44f2e1db1b8c..1a3deb694199 100644 --- a/src/lib/pickles/plonk_checks/dune +++ b/src/lib/pickles/plonk_checks/dune @@ -13,7 +13,6 @@ ;; opam libraries sexplib0 ppxlib.ast - core_kernel ocaml-migrate-parsetree base.base_internalhash_types ;; local libraries diff --git a/src/lib/pickles/plonk_checks/gen_scalars/dune b/src/lib/pickles/plonk_checks/gen_scalars/dune index 3e08abc11e0e..b9305f564bfa 100644 --- a/src/lib/pickles/plonk_checks/gen_scalars/dune +++ b/src/lib/pickles/plonk_checks/gen_scalars/dune @@ -8,7 +8,6 @@ (link_flags (-linkall)) (libraries ;; opam libraries - core_kernel stdio base ;; local libraries diff --git a/src/lib/pickles/pseudo/dune b/src/lib/pickles/pseudo/dune index 67a24708654e..b6e6b018f082 100644 --- a/src/lib/pickles/pseudo/dune +++ b/src/lib/pickles/pseudo/dune @@ -11,7 +11,6 @@ (pps ppx_version ppx_mina ppx_jane ppx_deriving.std ppx_deriving_yojson)) (libraries ;; opam libraries - core_kernel ;; local libraries pickles_types pickles.plonk_checks diff --git a/src/lib/pickles/snarky_tests/dune b/src/lib/pickles/snarky_tests/dune index 77269b465edc..d4a2c568c6f5 100644 --- a/src/lib/pickles/snarky_tests/dune +++ b/src/lib/pickles/snarky_tests/dune @@ -19,7 +19,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/pickles/test/chunked_circuits/dune b/src/lib/pickles/test/chunked_circuits/dune index 5815978d8784..5da1e8739022 100644 --- a/src/lib/pickles/test/chunked_circuits/dune +++ b/src/lib/pickles/test/chunked_circuits/dune @@ -7,7 +7,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/pickles/test/dune b/src/lib/pickles/test/dune index ae1c083e1537..e642d2d1d567 100644 --- a/src/lib/pickles/test/dune +++ b/src/lib/pickles/test/dune @@ -24,7 +24,6 @@ (libraries ; Opam libraries alcotest - core_kernel fmt integers sexplib0 diff --git a/src/lib/pickles/test/optional_custom_gates/dune b/src/lib/pickles/test/optional_custom_gates/dune index 9ede4472b795..a25a7b22802c 100644 --- a/src/lib/pickles/test/optional_custom_gates/dune +++ b/src/lib/pickles/test/optional_custom_gates/dune @@ -10,7 +10,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune b/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune index 7651b90a4fc1..41b313a7f901 100644 --- a/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune +++ b/src/lib/pickles/test/optional_custom_gates/test_gadgets/dune @@ -7,7 +7,6 @@ integers result bignum.bigint - core_kernel base64 digestif ppx_inline_test.config diff --git a/src/lib/pickles_base/dune b/src/lib/pickles_base/dune index dc6777dc4bc0..f28c308a0584 100644 --- a/src/lib/pickles_base/dune +++ b/src/lib/pickles_base/dune @@ -23,7 +23,6 @@ sexplib0 bin_prot.shape ppxlib - core_kernel ;; local libraries mina_wire_types snarky.backendless diff --git a/src/lib/pickles_base/one_hot_vector/dune b/src/lib/pickles_base/one_hot_vector/dune index 27773bdf37b2..97842da0c0d6 100644 --- a/src/lib/pickles_base/one_hot_vector/dune +++ b/src/lib/pickles_base/one_hot_vector/dune @@ -11,7 +11,6 @@ (pps ppx_version ppx_jane)) (libraries ;; opam libraries - core_kernel ;; local libraries snarky.backendless pickles_types)) diff --git a/src/lib/pickles_base/test/dune b/src/lib/pickles_base/test/dune index 98618b8680de..34f90359a800 100644 --- a/src/lib/pickles_base/test/dune +++ b/src/lib/pickles_base/test/dune @@ -9,7 +9,6 @@ (libraries ; Opam alcotest - core_kernel ; Mina pickles_base pickles_types) diff --git a/src/lib/pickles_types/dune b/src/lib/pickles_types/dune index aeb7399b3ca3..50ca7e2465af 100644 --- a/src/lib/pickles_types/dune +++ b/src/lib/pickles_types/dune @@ -27,7 +27,6 @@ ;; opam libraries sexplib0 result - core_kernel bin_prot.shape ;; local libraries kimchi_types diff --git a/src/lib/ppx_mina/dune b/src/lib/ppx_mina/dune index 237cdd2e52d5..114c0d95ce7c 100644 --- a/src/lib/ppx_mina/dune +++ b/src/lib/ppx_mina/dune @@ -11,7 +11,6 @@ ppx_deriving.api ppxlib ppx_bin_prot - core_kernel base ;; local libraries ppx_representatives diff --git a/src/lib/ppx_register_event/dune b/src/lib/ppx_register_event/dune index b64f6d47e2fd..d6c6c77bb3ca 100644 --- a/src/lib/ppx_register_event/dune +++ b/src/lib/ppx_register_event/dune @@ -7,7 +7,6 @@ ocaml-compiler-libs.common ppxlib.ast ppx_deriving_yojson - core_kernel ppxlib compiler-libs.common ocaml-migrate-parsetree diff --git a/src/lib/ppx_util/dune b/src/lib/ppx_util/dune index cabfcc9dce3d..e7d96b3aac49 100644 --- a/src/lib/ppx_util/dune +++ b/src/lib/ppx_util/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel ppxlib) (preprocess (pps ppx_version ppx_jane ppxlib.metaquot)) diff --git a/src/lib/ppx_version/dune b/src/lib/ppx_version/dune index e5966642dc35..a77f67ce8e15 100644 --- a/src/lib/ppx_version/dune +++ b/src/lib/ppx_version/dune @@ -14,7 +14,6 @@ ppx_derivers ppx_bin_prot base - core_kernel ppx_version.runtime bin_prot) (preprocess diff --git a/src/lib/precomputed_values/dune b/src/lib/precomputed_values/dune index 0dd0a3b05743..1d9d95db409b 100644 --- a/src/lib/precomputed_values/dune +++ b/src/lib/precomputed_values/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries core - core_kernel ;; local libraries genesis_constants mina_state diff --git a/src/lib/proof_cache_tag/dune b/src/lib/proof_cache_tag/dune index 0a5023361a02..ea3910975b9c 100644 --- a/src/lib/proof_cache_tag/dune +++ b/src/lib/proof_cache_tag/dune @@ -3,7 +3,6 @@ (public_name proof_cache_tag) (libraries ;; opam libraries - core_kernel async_kernel ;; local libraries logger diff --git a/src/lib/proof_carrying_data/dune b/src/lib/proof_carrying_data/dune index 7737dcea0e1c..46a0a7da79ce 100644 --- a/src/lib/proof_carrying_data/dune +++ b/src/lib/proof_carrying_data/dune @@ -6,7 +6,6 @@ (pps ppx_deriving_yojson ppx_version ppx_jane)) (libraries ;; opam libraries - core_kernel bin_prot.shape base sexplib0 diff --git a/src/lib/protocol_version/dune b/src/lib/protocol_version/dune index 0d095571bc0c..02d7e48f161c 100644 --- a/src/lib/protocol_version/dune +++ b/src/lib/protocol_version/dune @@ -4,7 +4,6 @@ (library_flags -linkall) (libraries ;; opam libraries - core_kernel sexplib0 bin_prot.shape base diff --git a/src/lib/prover/dune b/src/lib/prover/dune index b26253c349b7..0cb27c7bb4d0 100644 --- a/src/lib/prover/dune +++ b/src/lib/prover/dune @@ -9,7 +9,6 @@ core async async_kernel - core_kernel bin_prot.shape sexplib0 ;; local libraries diff --git a/src/lib/random_oracle/dune b/src/lib/random_oracle/dune index 3580046494b5..9020f3074fe9 100644 --- a/src/lib/random_oracle/dune +++ b/src/lib/random_oracle/dune @@ -19,7 +19,6 @@ ;; opam libraries ppx_inline_test.config base - core_kernel sexplib0 ;; local libraries snark_params diff --git a/src/lib/random_oracle/permutation/external/dune b/src/lib/random_oracle/permutation/external/dune index 2f65a83b6b21..f38c11b92a2c 100644 --- a/src/lib/random_oracle/permutation/external/dune +++ b/src/lib/random_oracle/permutation/external/dune @@ -11,7 +11,6 @@ ;; opam libraries ppx_inline_test.config base - core_kernel sexplib0 ;; local libraries sponge diff --git a/src/lib/random_oracle/permutation/ocaml/dune b/src/lib/random_oracle/permutation/ocaml/dune index 2795e4d67924..229b95856c71 100644 --- a/src/lib/random_oracle/permutation/ocaml/dune +++ b/src/lib/random_oracle/permutation/ocaml/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries sponge pickles diff --git a/src/lib/rocksdb/dune b/src/lib/rocksdb/dune index 79b38072c6f7..fa62dcd555f4 100644 --- a/src/lib/rocksdb/dune +++ b/src/lib/rocksdb/dune @@ -11,7 +11,6 @@ async_unix base.base_internalhash_types core - core_kernel core_kernel.uuid ppx_inline_test.config rocks diff --git a/src/lib/rocksdb/tests/dune b/src/lib/rocksdb/tests/dune index ef4e751824e8..0f4a29c4735a 100644 --- a/src/lib/rocksdb/tests/dune +++ b/src/lib/rocksdb/tests/dune @@ -7,7 +7,6 @@ async_unix base.base_internalhash_types core - core_kernel core_kernel.uuid rocks ;; local libraries diff --git a/src/lib/rosetta_coding/dune b/src/lib/rosetta_coding/dune index 3146d2b0d5b1..d257f2bcbc21 100644 --- a/src/lib/rosetta_coding/dune +++ b/src/lib/rosetta_coding/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries mina_stdlib signature_lib diff --git a/src/lib/rosetta_coding/test/dune b/src/lib/rosetta_coding/test/dune index 9e04a695ae56..c437afc9844d 100644 --- a/src/lib/rosetta_coding/test/dune +++ b/src/lib/rosetta_coding/test/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries alcotest - core_kernel ;; local libraries rosetta_coding snark_params diff --git a/src/lib/rosetta_lib/dune b/src/lib/rosetta_lib/dune index 4b30bc967ce4..74f6b671a765 100644 --- a/src/lib/rosetta_lib/dune +++ b/src/lib/rosetta_lib/dune @@ -6,7 +6,6 @@ ;; opam libraries result caqti - core_kernel base async_kernel uri diff --git a/src/lib/rosetta_lib/test/dune b/src/lib/rosetta_lib/test/dune index fc918d752d7f..9feb1c6b5b22 100644 --- a/src/lib/rosetta_lib/test/dune +++ b/src/lib/rosetta_lib/test/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries alcotest - core_kernel ;; local libraries mina_base rosetta_coding diff --git a/src/lib/runtime_config/dune b/src/lib/runtime_config/dune index d40998d83b4e..d92e4aba8f31 100644 --- a/src/lib/runtime_config/dune +++ b/src/lib/runtime_config/dune @@ -6,7 +6,6 @@ async async_kernel async_unix - core_kernel bin_prot.shape base base64 diff --git a/src/lib/secrets/dune b/src/lib/secrets/dune index 9c90c5da5aaf..2bdd7395e78c 100644 --- a/src/lib/secrets/dune +++ b/src/lib/secrets/dune @@ -15,7 +15,6 @@ sodium ppx_deriving_yojson.runtime yojson - core_kernel sexplib0 base58 ppx_inline_test.config diff --git a/src/lib/sgn/dune b/src/lib/sgn/dune index 48db8a0e157c..e40c6d4bfba0 100644 --- a/src/lib/sgn/dune +++ b/src/lib/sgn/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries ppx_deriving_yojson.runtime - core_kernel yojson sexplib0 base diff --git a/src/lib/sgn_type/dune b/src/lib/sgn_type/dune index 0c15278ef532..34d5a0537c28 100644 --- a/src/lib/sgn_type/dune +++ b/src/lib/sgn_type/dune @@ -7,7 +7,6 @@ (pps ppx_jane ppx_version ppx_compare ppx_deriving_yojson)) (libraries ;; opam libraries - core_kernel ppx_deriving_yojson.runtime yojson sexplib0 diff --git a/src/lib/signature_lib/dune b/src/lib/signature_lib/dune index 540cd1cdd548..4e3038d0e6c0 100644 --- a/src/lib/signature_lib/dune +++ b/src/lib/signature_lib/dune @@ -11,7 +11,6 @@ base sexplib0 yojson - core_kernel bin_prot.shape result ;; local libraries diff --git a/src/lib/signature_lib/find_address/dune b/src/lib/signature_lib/find_address/dune index a6f6d4ae31a6..5d78ee2e47b8 100644 --- a/src/lib/signature_lib/find_address/dune +++ b/src/lib/signature_lib/find_address/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries base - core_kernel ;; local libraries pickles.backend pickles diff --git a/src/lib/snark_bits/dune b/src/lib/snark_bits/dune index 8aa014acda9b..1d8bf6a9f070 100644 --- a/src/lib/snark_bits/dune +++ b/src/lib/snark_bits/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel integers base ;; local libraries diff --git a/src/lib/snark_params/dune b/src/lib/snark_params/dune index b8494a340449..13bb4acfb83b 100644 --- a/src/lib/snark_params/dune +++ b/src/lib/snark_params/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries base.base_internalhash_types - core_kernel digestif base sexplib0 diff --git a/src/lib/snark_params/test/dune b/src/lib/snark_params/test/dune index 5b210c8447a1..8fc8d8bb5038 100644 --- a/src/lib/snark_params/test/dune +++ b/src/lib/snark_params/test/dune @@ -4,7 +4,6 @@ ;; opam libraries alcotest base - core_kernel ;; local libraries bignum_bigint crypto_params diff --git a/src/lib/snark_profiler_lib/dune b/src/lib/snark_profiler_lib/dune index fa1613138d59..0f86c891f4d5 100644 --- a/src/lib/snark_profiler_lib/dune +++ b/src/lib/snark_profiler_lib/dune @@ -9,7 +9,6 @@ result async_kernel async_unix - core_kernel core base async diff --git a/src/lib/snark_work_lib/dune b/src/lib/snark_work_lib/dune index a2f8f394cb78..5d3dfa42c02f 100644 --- a/src/lib/snark_work_lib/dune +++ b/src/lib/snark_work_lib/dune @@ -7,7 +7,6 @@ ;; opam libraries bin_prot.shape core - core_kernel sexplib0 ;; local libraries currency diff --git a/src/lib/snark_worker/dune b/src/lib/snark_worker/dune index 0dc82fe916fa..c3e77bc1c5c2 100644 --- a/src/lib/snark_worker/dune +++ b/src/lib/snark_worker/dune @@ -14,7 +14,6 @@ base.base_internalhash_types bin_prot.shape core - core_kernel core_kernel.hash_heap ppx_hash.runtime-lib ppx_version.runtime diff --git a/src/lib/snark_worker/standalone/dune b/src/lib/snark_worker/standalone/dune index 9be9f8ea91d7..5fd2907a7008 100644 --- a/src/lib/snark_worker/standalone/dune +++ b/src/lib/snark_worker/standalone/dune @@ -10,7 +10,6 @@ async_unix base core - core_kernel sexplib0 uri ;; local libraries diff --git a/src/lib/snarky_blake2/dune b/src/lib/snarky_blake2/dune index b1881d8dee11..05ddf746c8ab 100644 --- a/src/lib/snarky_blake2/dune +++ b/src/lib/snarky_blake2/dune @@ -7,7 +7,6 @@ (pps ppx_compare ppx_jane ppx_version)) (libraries blake2 - core_kernel digestif integers mina_stdlib diff --git a/src/lib/snarky_blake2/test/dune b/src/lib/snarky_blake2/test/dune index e1cde96a9d47..88ac482a2f09 100644 --- a/src/lib/snarky_blake2/test/dune +++ b/src/lib/snarky_blake2/test/dune @@ -4,7 +4,6 @@ alcotest base blake2 - core_kernel crypto_params digestif snark_params diff --git a/src/lib/snarky_curves/dune b/src/lib/snarky_curves/dune index aa3cb23d5532..82182a120b05 100644 --- a/src/lib/snarky_curves/dune +++ b/src/lib/snarky_curves/dune @@ -7,7 +7,6 @@ (pps ppx_version ppx_snarky ppx_jane ppx_compare)) (libraries ;; opam libraries - core_kernel sexplib0 bignum.bigint ;; local libraries diff --git a/src/lib/snarky_field_extensions/dune b/src/lib/snarky_field_extensions/dune index 6ab7dc5cf2e1..cfbaa7e48fbd 100644 --- a/src/lib/snarky_field_extensions/dune +++ b/src/lib/snarky_field_extensions/dune @@ -11,7 +11,6 @@ ;; opam libraries bignum.bigint sexplib0 - core_kernel ppx_inline_test.config result ;; local libraries diff --git a/src/lib/snarky_group_map/dune b/src/lib/snarky_group_map/dune index 5d96bd93ef87..2331d6f5e8e0 100644 --- a/src/lib/snarky_group_map/dune +++ b/src/lib/snarky_group_map/dune @@ -9,7 +9,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel ;; local libraries snarky.backendless group_map)) diff --git a/src/lib/snarky_taylor/dune b/src/lib/snarky_taylor/dune index 910eef521323..cfd9d8364c03 100644 --- a/src/lib/snarky_taylor/dune +++ b/src/lib/snarky_taylor/dune @@ -9,7 +9,6 @@ ;; opam libraries bignum bignum.bigint - core_kernel sexplib0 ;; local libraries snarky.backendless diff --git a/src/lib/snarky_taylor/tests/dune b/src/lib/snarky_taylor/tests/dune index 97d15c1bf2a5..2298f6635f5f 100644 --- a/src/lib/snarky_taylor/tests/dune +++ b/src/lib/snarky_taylor/tests/dune @@ -6,7 +6,6 @@ base bignum bignum.bigint - core_kernel ;; local libraries bitstring_lib snark_params diff --git a/src/lib/sparse_ledger_lib/dune b/src/lib/sparse_ledger_lib/dune index c814f37ac86e..1a130825832d 100644 --- a/src/lib/sparse_ledger_lib/dune +++ b/src/lib/sparse_ledger_lib/dune @@ -6,7 +6,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel sexplib0 base ppx_inline_test.config diff --git a/src/lib/staged_ledger/test/dune b/src/lib/staged_ledger/test/dune index fe092c189569..5f53a47cb249 100644 --- a/src/lib/staged_ledger/test/dune +++ b/src/lib/staged_ledger/test/dune @@ -6,7 +6,6 @@ async_kernel async_unix base - core_kernel integers sexplib0 yojson diff --git a/src/lib/staged_ledger_diff/dune b/src/lib/staged_ledger_diff/dune index 3e79a95873e8..be54c645cd2d 100644 --- a/src/lib/staged_ledger_diff/dune +++ b/src/lib/staged_ledger_diff/dune @@ -3,7 +3,6 @@ (public_name staged_ledger_diff) (libraries ;; opam libraries - core_kernel sexplib0 async bin_prot.shape diff --git a/src/lib/storage/dune b/src/lib/storage/dune index adfbf170c9a0..dbcc072a8a29 100644 --- a/src/lib/storage/dune +++ b/src/lib/storage/dune @@ -8,7 +8,6 @@ ;; opam libraries core async - core_kernel bin_prot.shape bin_prot base diff --git a/src/lib/string_sign/dune b/src/lib/string_sign/dune index 46f2b1d03b2e..e59cd7ed0c2a 100644 --- a/src/lib/string_sign/dune +++ b/src/lib/string_sign/dune @@ -3,7 +3,6 @@ (public_name string_sign) (libraries ;; opam libraries - core_kernel result ;; local libraries kimchi_backend diff --git a/src/lib/string_sign/tests/dune b/src/lib/string_sign/tests/dune index dbccf4cfb286..d851ca63f92d 100644 --- a/src/lib/string_sign/tests/dune +++ b/src/lib/string_sign/tests/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries alcotest - core_kernel result ;; local libraries mina_base diff --git a/src/lib/structured_log_events/dune b/src/lib/structured_log_events/dune index 8a17068ac36d..9d6c5d97869a 100644 --- a/src/lib/structured_log_events/dune +++ b/src/lib/structured_log_events/dune @@ -6,7 +6,6 @@ (library_flags -linkall) (libraries ;; opam libraries - core_kernel yojson sexplib0 ;; local libraries diff --git a/src/lib/sync_handler/dune b/src/lib/sync_handler/dune index 7d8d1794bdc4..9d182ac54225 100644 --- a/src/lib/sync_handler/dune +++ b/src/lib/sync_handler/dune @@ -12,7 +12,6 @@ sexplib0 core async - core_kernel async_kernel ;; local libraries with_hash diff --git a/src/lib/sync_status/dune b/src/lib/sync_status/dune index 69f012fc1da9..50310968e911 100644 --- a/src/lib/sync_status/dune +++ b/src/lib/sync_status/dune @@ -5,7 +5,6 @@ ;; opam libraries base.base_internalhash_types bin_prot.shape - core_kernel sexplib0 ppx_version.runtime) (preprocess diff --git a/src/lib/sync_status/tests/dune b/src/lib/sync_status/tests/dune index e41b74edebd3..b3467bdcd6bd 100644 --- a/src/lib/sync_status/tests/dune +++ b/src/lib/sync_status/tests/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries alcotest - core_kernel ;; local libraries sync_status) (instrumentation diff --git a/src/lib/syncable_ledger/dune b/src/lib/syncable_ledger/dune index cb9e75ce02e3..04c235e8fcca 100644 --- a/src/lib/syncable_ledger/dune +++ b/src/lib/syncable_ledger/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries async_kernel - core_kernel bin_prot.shape sexplib0 core diff --git a/src/lib/syncable_ledger/test/dune b/src/lib/syncable_ledger/test/dune index caa00acb3824..6a85db88943f 100644 --- a/src/lib/syncable_ledger/test/dune +++ b/src/lib/syncable_ledger/test/dune @@ -9,7 +9,6 @@ bin_prot.shape async_unix async_kernel - core_kernel core async sexplib0 diff --git a/src/lib/testing/integration_test_lib/dune b/src/lib/testing/integration_test_lib/dune index 5b927ea841df..f7916e5f20d1 100644 --- a/src/lib/testing/integration_test_lib/dune +++ b/src/lib/testing/integration_test_lib/dune @@ -37,7 +37,6 @@ async core lens - core_kernel async_kernel ppx_inline_test.config async_unix diff --git a/src/lib/testing/integration_test_local_engine/dune b/src/lib/testing/integration_test_local_engine/dune index 8d23e4c3aec0..8b0277c8c836 100644 --- a/src/lib/testing/integration_test_local_engine/dune +++ b/src/lib/testing/integration_test_local_engine/dune @@ -27,7 +27,6 @@ ;; opam libraries async_unix async_kernel - core_kernel core async cmdliner diff --git a/src/lib/testing/itn_crypto/dune b/src/lib/testing/itn_crypto/dune index 959c26b7f926..e6fe5689fe10 100644 --- a/src/lib/testing/itn_crypto/dune +++ b/src/lib/testing/itn_crypto/dune @@ -5,7 +5,6 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - core_kernel base64 cstruct mirage-crypto-ec diff --git a/src/lib/testing/quickcheck_lib/dune b/src/lib/testing/quickcheck_lib/dune index ad636b40213e..190758052186 100644 --- a/src/lib/testing/quickcheck_lib/dune +++ b/src/lib/testing/quickcheck_lib/dune @@ -3,7 +3,6 @@ (public_name quickcheck_lib) (libraries ;; opam libraries - core_kernel base ppx_inline_test.config ;; local libraries diff --git a/src/lib/testing/test_util/dune b/src/lib/testing/test_util/dune index 2967a3d271f3..caaf5456a73c 100644 --- a/src/lib/testing/test_util/dune +++ b/src/lib/testing/test_util/dune @@ -4,7 +4,6 @@ (library_flags -linkall) (libraries ;; opam libraries - core_kernel bin_prot ;; local libraries snark_params diff --git a/src/lib/timeout_lib/dune b/src/lib/timeout_lib/dune index 8a429d423581..8db3d2e601f7 100644 --- a/src/lib/timeout_lib/dune +++ b/src/lib/timeout_lib/dune @@ -3,7 +3,6 @@ (public_name timeout_lib) (libraries ;; opam libraries - core_kernel async_kernel ;; local libraries logger) diff --git a/src/lib/transaction/dune b/src/lib/transaction/dune index 17b212854d1e..9a382b3f0d8a 100644 --- a/src/lib/transaction/dune +++ b/src/lib/transaction/dune @@ -8,7 +8,6 @@ base base.base_internalhash_types bin_prot.shape - core_kernel ppx_inline_test.config result sexplib0 diff --git a/src/lib/transaction_inclusion_status/dune b/src/lib/transaction_inclusion_status/dune index cb0e4dc3a2f7..aacfe7cd04f1 100644 --- a/src/lib/transaction_inclusion_status/dune +++ b/src/lib/transaction_inclusion_status/dune @@ -9,7 +9,6 @@ core bin_prot.shape sexplib0 - core_kernel ppx_inline_test.config async async_unix diff --git a/src/lib/transaction_logic/dune b/src/lib/transaction_logic/dune index 0c754768bbdc..d080b57969eb 100644 --- a/src/lib/transaction_logic/dune +++ b/src/lib/transaction_logic/dune @@ -10,7 +10,6 @@ sexplib0 yojson sexp_diff_kernel - core_kernel base base.base_internalhash_types integers diff --git a/src/lib/transaction_logic/test/dune b/src/lib/transaction_logic/test/dune index 56fc3603fa3f..a73c5b50071e 100644 --- a/src/lib/transaction_logic/test/dune +++ b/src/lib/transaction_logic/test/dune @@ -7,7 +7,6 @@ base base.base_internalhash_types core - core_kernel integers ppx_inline_test.config sexplib0 diff --git a/src/lib/transaction_logic/test/transaction_logic/dune b/src/lib/transaction_logic/test/transaction_logic/dune index 65989a7830a5..810922a246ec 100644 --- a/src/lib/transaction_logic/test/transaction_logic/dune +++ b/src/lib/transaction_logic/test/transaction_logic/dune @@ -8,7 +8,6 @@ base base.base_internalhash_types core - core_kernel integers ppx_inline_test.config sexplib0 diff --git a/src/lib/transaction_protocol_state/dune b/src/lib/transaction_protocol_state/dune index c86ffacf5501..e26887d2ef14 100644 --- a/src/lib/transaction_protocol_state/dune +++ b/src/lib/transaction_protocol_state/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries sexplib0 - core_kernel core bin_prot.shape ;; local libraries diff --git a/src/lib/transaction_snark/test/access_permission/dune b/src/lib/transaction_snark/test/access_permission/dune index 38ec422a1a42..8fe182dd298d 100644 --- a/src/lib/transaction_snark/test/access_permission/dune +++ b/src/lib/transaction_snark/test/access_permission/dune @@ -7,7 +7,6 @@ async_unix base core - core_kernel ppx_inline_test.config sexplib0 yojson diff --git a/src/lib/transaction_snark/test/account_timing/dune b/src/lib/transaction_snark/test/account_timing/dune index 0ea3de34efef..69acc94e3c16 100644 --- a/src/lib/transaction_snark/test/account_timing/dune +++ b/src/lib/transaction_snark/test/account_timing/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel sexplib0 yojson ;; local libraries diff --git a/src/lib/transaction_snark/test/account_update_network_id/dune b/src/lib/transaction_snark/test/account_update_network_id/dune index 451c9077f464..5a2958a38065 100644 --- a/src/lib/transaction_snark/test/account_update_network_id/dune +++ b/src/lib/transaction_snark/test/account_update_network_id/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel yojson sexplib0 ;; local libraries diff --git a/src/lib/transaction_snark/test/app_state/dune b/src/lib/transaction_snark/test/app_state/dune index 4722d46b4b11..68e4acaa3f2c 100644 --- a/src/lib/transaction_snark/test/app_state/dune +++ b/src/lib/transaction_snark/test/app_state/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/delegate/dune b/src/lib/transaction_snark/test/delegate/dune index 92f5a05fbb22..bf416eda0078 100644 --- a/src/lib/transaction_snark/test/delegate/dune +++ b/src/lib/transaction_snark/test/delegate/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/dune b/src/lib/transaction_snark/test/dune index 7b8781a2d88d..6e3c2cf6dfd0 100644 --- a/src/lib/transaction_snark/test/dune +++ b/src/lib/transaction_snark/test/dune @@ -9,7 +9,6 @@ async_unix core base - core_kernel base64 yojson integers diff --git a/src/lib/transaction_snark/test/fee_payer/dune b/src/lib/transaction_snark/test/fee_payer/dune index 61d3db386270..3bfcab7adddb 100644 --- a/src/lib/transaction_snark/test/fee_payer/dune +++ b/src/lib/transaction_snark/test/fee_payer/dune @@ -8,7 +8,6 @@ async_kernel core base - core_kernel yojson sexplib0 integers diff --git a/src/lib/transaction_snark/test/multisig_account/dune b/src/lib/transaction_snark/test/multisig_account/dune index b036a25fba10..64c21839d27b 100644 --- a/src/lib/transaction_snark/test/multisig_account/dune +++ b/src/lib/transaction_snark/test/multisig_account/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/permissions/dune b/src/lib/transaction_snark/test/permissions/dune index 7cf609965ef2..95297c146d12 100644 --- a/src/lib/transaction_snark/test/permissions/dune +++ b/src/lib/transaction_snark/test/permissions/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/token_symbol/dune b/src/lib/transaction_snark/test/token_symbol/dune index 1f89a6b228fe..6b74e99e53ea 100644 --- a/src/lib/transaction_snark/test/token_symbol/dune +++ b/src/lib/transaction_snark/test/token_symbol/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/transaction_union/dune b/src/lib/transaction_snark/test/transaction_union/dune index da17b3106c69..4be6b260b09f 100644 --- a/src/lib/transaction_snark/test/transaction_union/dune +++ b/src/lib/transaction_snark/test/transaction_union/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel yojson ;; local libraries mina_base.import diff --git a/src/lib/transaction_snark/test/verification_key/dune b/src/lib/transaction_snark/test/verification_key/dune index b050bbbf5a5a..40c1a8b003b5 100644 --- a/src/lib/transaction_snark/test/verification_key/dune +++ b/src/lib/transaction_snark/test/verification_key/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/verification_key_permission/dune b/src/lib/transaction_snark/test/verification_key_permission/dune index e4a7df67111b..2c8833699ca6 100644 --- a/src/lib/transaction_snark/test/verification_key_permission/dune +++ b/src/lib/transaction_snark/test/verification_key_permission/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/verify-simple-test/dune b/src/lib/transaction_snark/test/verify-simple-test/dune index fdc52417acbf..78d4792a7f35 100644 --- a/src/lib/transaction_snark/test/verify-simple-test/dune +++ b/src/lib/transaction_snark/test/verify-simple-test/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel base64 yojson ;; local libraries diff --git a/src/lib/transaction_snark/test/voting_for/dune b/src/lib/transaction_snark/test/voting_for/dune index 2c6ded34c119..4e790b618bde 100644 --- a/src/lib/transaction_snark/test/voting_for/dune +++ b/src/lib/transaction_snark/test/voting_for/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/zkapp_deploy/dune b/src/lib/transaction_snark/test/zkapp_deploy/dune index 623696695bd7..f41281ad29e5 100644 --- a/src/lib/transaction_snark/test/zkapp_deploy/dune +++ b/src/lib/transaction_snark/test/zkapp_deploy/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/zkapp_fuzzy/dune b/src/lib/transaction_snark/test/zkapp_fuzzy/dune index 62f36af962fa..988a7d7e8f4c 100644 --- a/src/lib/transaction_snark/test/zkapp_fuzzy/dune +++ b/src/lib/transaction_snark/test/zkapp_fuzzy/dune @@ -9,7 +9,6 @@ async.async_command core base - core_kernel yojson splittable_random ;; local libraries diff --git a/src/lib/transaction_snark/test/zkapp_payments/dune b/src/lib/transaction_snark/test/zkapp_payments/dune index 458aa2550569..062237b78ffb 100644 --- a/src/lib/transaction_snark/test/zkapp_payments/dune +++ b/src/lib/transaction_snark/test/zkapp_payments/dune @@ -8,7 +8,6 @@ async_unix core base - core_kernel yojson sexplib0 ppx_deriving_yojson.runtime diff --git a/src/lib/transaction_snark/test/zkapp_preconditions/dune b/src/lib/transaction_snark/test/zkapp_preconditions/dune index a6ac3774756e..f5248c94e9a6 100644 --- a/src/lib/transaction_snark/test/zkapp_preconditions/dune +++ b/src/lib/transaction_snark/test/zkapp_preconditions/dune @@ -8,7 +8,6 @@ async_kernel core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/zkapp_tokens/dune b/src/lib/transaction_snark/test/zkapp_tokens/dune index d7a53d0541ee..4ef0efba9550 100644 --- a/src/lib/transaction_snark/test/zkapp_tokens/dune +++ b/src/lib/transaction_snark/test/zkapp_tokens/dune @@ -6,7 +6,6 @@ async async_kernel async_unix - core_kernel sexplib0 ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark/test/zkapp_uri/dune b/src/lib/transaction_snark/test/zkapp_uri/dune index 8e3f168338a1..0fd8db649ede 100644 --- a/src/lib/transaction_snark/test/zkapp_uri/dune +++ b/src/lib/transaction_snark/test/zkapp_uri/dune @@ -7,7 +7,6 @@ async core base - core_kernel yojson ppx_deriving_yojson.runtime result diff --git a/src/lib/transaction_snark_scan_state/dune b/src/lib/transaction_snark_scan_state/dune index 58d70c1629f7..053120defa45 100644 --- a/src/lib/transaction_snark_scan_state/dune +++ b/src/lib/transaction_snark_scan_state/dune @@ -11,7 +11,6 @@ sexplib0 digestif base - core_kernel async yojson bin_prot.shape diff --git a/src/lib/transaction_snark_work/dune b/src/lib/transaction_snark_work/dune index 45a09c143245..ddec9d3750dc 100644 --- a/src/lib/transaction_snark_work/dune +++ b/src/lib/transaction_snark_work/dune @@ -3,7 +3,6 @@ (public_name transaction_snark_work) (libraries ;; opam libraries - core_kernel sexplib0 bin_prot.shape base.base_internalhash_types diff --git a/src/lib/transaction_witness/dune b/src/lib/transaction_witness/dune index 0ad7ed0f74ad..8c74adf4ddfb 100644 --- a/src/lib/transaction_witness/dune +++ b/src/lib/transaction_witness/dune @@ -7,7 +7,6 @@ ;; opam libraries bin_prot.shape sexplib0 - core_kernel core ;; local libraries currency diff --git a/src/lib/transition_chain_prover/dune b/src/lib/transition_chain_prover/dune index 5ed06e3caebb..226540d5ba93 100644 --- a/src/lib/transition_chain_prover/dune +++ b/src/lib/transition_chain_prover/dune @@ -8,7 +8,6 @@ (libraries ;; opam libraries core - core_kernel ;; local libraries transition_frontier_extensions mina_block diff --git a/src/lib/transition_chain_verifier/dune b/src/lib/transition_chain_verifier/dune index 6730daca8875..29ddc565458c 100644 --- a/src/lib/transition_chain_verifier/dune +++ b/src/lib/transition_chain_verifier/dune @@ -7,7 +7,6 @@ (pps ppx_version ppx_jane ppx_compare)) (libraries ;; opam libraries - core_kernel core ;; local libraries merkle_list_verifier diff --git a/src/lib/transition_frontier/extensions/dune b/src/lib/transition_frontier/extensions/dune index 4b8e4fb490c0..ab0cfa482c8a 100644 --- a/src/lib/transition_frontier/extensions/dune +++ b/src/lib/transition_frontier/extensions/dune @@ -4,7 +4,6 @@ (libraries ;;opam libraries async_kernel - core_kernel sexplib0 result base.base_internalhash_types diff --git a/src/lib/transition_frontier/frontier_base/dune b/src/lib/transition_frontier/frontier_base/dune index c0a42b238488..6821241d2496 100644 --- a/src/lib/transition_frontier/frontier_base/dune +++ b/src/lib/transition_frontier/frontier_base/dune @@ -5,7 +5,6 @@ ;;opam libraries async_unix async_kernel - core_kernel bin_prot.shape sexplib0 integers diff --git a/src/lib/transition_frontier/full_frontier/dune b/src/lib/transition_frontier/full_frontier/dune index 26ed85c9a031..ca89179aee5c 100644 --- a/src/lib/transition_frontier/full_frontier/dune +++ b/src/lib/transition_frontier/full_frontier/dune @@ -5,7 +5,6 @@ ;;opam libraries integers core - core_kernel sexplib0 base.base_internalhash_types stdio diff --git a/src/lib/transition_frontier/persistent_frontier/dune b/src/lib/transition_frontier/persistent_frontier/dune index d8c9af6d362d..6944fe8cff49 100644 --- a/src/lib/transition_frontier/persistent_frontier/dune +++ b/src/lib/transition_frontier/persistent_frontier/dune @@ -5,7 +5,6 @@ ;;opam libraries result bin_prot.shape - core_kernel async core async_kernel diff --git a/src/lib/transition_frontier/persistent_root/dune b/src/lib/transition_frontier/persistent_root/dune index 4eb96f7699ac..cd1872bd028f 100644 --- a/src/lib/transition_frontier/persistent_root/dune +++ b/src/lib/transition_frontier/persistent_root/dune @@ -4,7 +4,6 @@ (libraries ;;opam libraries core_kernel.uuid - core_kernel core ;;local libraries precomputed_values diff --git a/src/lib/transition_frontier/tests/dune b/src/lib/transition_frontier/tests/dune index 5c5da73652c6..50b997805dca 100644 --- a/src/lib/transition_frontier/tests/dune +++ b/src/lib/transition_frontier/tests/dune @@ -5,7 +5,6 @@ core async async_kernel - core_kernel ppx_inline_test.config async_unix core_kernel.uuid diff --git a/src/lib/transition_frontier_controller/dune b/src/lib/transition_frontier_controller/dune index ebb44b9c4c06..76dd1c4c9ace 100644 --- a/src/lib/transition_frontier_controller/dune +++ b/src/lib/transition_frontier_controller/dune @@ -9,7 +9,6 @@ ;; opam libraries base async_kernel - core_kernel core ;; local libraries transition_frontier diff --git a/src/lib/transition_handler/dune b/src/lib/transition_handler/dune index a0ffbf3c03c5..a2902319762f 100644 --- a/src/lib/transition_handler/dune +++ b/src/lib/transition_handler/dune @@ -7,7 +7,6 @@ ;; opam libraries ppx_inline_test.config sexplib0 - core_kernel core async async_unix diff --git a/src/lib/transition_router/dune b/src/lib/transition_router/dune index 48e06113787a..d5a35891ddf9 100644 --- a/src/lib/transition_router/dune +++ b/src/lib/transition_router/dune @@ -9,7 +9,6 @@ ;; opam libraries integers async_kernel - core_kernel core async sexplib0 diff --git a/src/lib/trust_system/dune b/src/lib/trust_system/dune index a6c7dc860a32..d3c7a2163815 100644 --- a/src/lib/trust_system/dune +++ b/src/lib/trust_system/dune @@ -8,7 +8,6 @@ core ppx_inline_test.config async_kernel - core_kernel bin_prot.shape base result diff --git a/src/lib/unsigned_extended/dune b/src/lib/unsigned_extended/dune index 1790ec546893..b129f4666965 100644 --- a/src/lib/unsigned_extended/dune +++ b/src/lib/unsigned_extended/dune @@ -8,7 +8,6 @@ ;; opam libraries result base - core_kernel integers sexplib0 bignum.bigint diff --git a/src/lib/uptime_service/dune b/src/lib/uptime_service/dune index 366b6b943d64..bdd24e2d3815 100644 --- a/src/lib/uptime_service/dune +++ b/src/lib/uptime_service/dune @@ -10,7 +10,6 @@ async_unix rpc_parallel ptime - core_kernel async bin_prot.shape async_kernel diff --git a/src/lib/user_command_input/dune b/src/lib/user_command_input/dune index 965d2f05c8a4..b64edf4489ea 100644 --- a/src/lib/user_command_input/dune +++ b/src/lib/user_command_input/dune @@ -5,7 +5,6 @@ ;; opam libraries bin_prot.shape core - core_kernel async_kernel sexplib0 async diff --git a/src/lib/verifier/dune b/src/lib/verifier/dune index 2b000b6eb2d2..7d9484f8d9c8 100644 --- a/src/lib/verifier/dune +++ b/src/lib/verifier/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries async - core_kernel async_kernel rpc_parallel sexplib0 diff --git a/src/lib/vrf_evaluator/dune b/src/lib/vrf_evaluator/dune index 5cd5c3b18a07..39a30fded513 100644 --- a/src/lib/vrf_evaluator/dune +++ b/src/lib/vrf_evaluator/dune @@ -8,7 +8,6 @@ rpc_parallel core async - core_kernel bin_prot.shape sexplib0 integers diff --git a/src/lib/vrf_lib/dune b/src/lib/vrf_lib/dune index a7e5905aa6f8..378ffabe8441 100644 --- a/src/lib/vrf_lib/dune +++ b/src/lib/vrf_lib/dune @@ -10,7 +10,6 @@ bin_prot.shape core sexplib0 - core_kernel bignum ppx_inline_test.config ;; local libraries diff --git a/src/lib/vrf_lib/tests/dune b/src/lib/vrf_lib/tests/dune index b81344c6379b..c99938403708 100644 --- a/src/lib/vrf_lib/tests/dune +++ b/src/lib/vrf_lib/tests/dune @@ -7,7 +7,6 @@ (libraries ;; opam libraries core - core_kernel ppx_inline_test.config sexplib0 ppx_deriving.runtime diff --git a/src/lib/webkit_trace_event/binary_output/dune b/src/lib/webkit_trace_event/binary_output/dune index c0f535b0a25a..04dcfe399f93 100644 --- a/src/lib/webkit_trace_event/binary_output/dune +++ b/src/lib/webkit_trace_event/binary_output/dune @@ -6,7 +6,6 @@ core async base - core_kernel async_unix ;; local libraries webkit_trace_event) diff --git a/src/lib/with_hash/dune b/src/lib/with_hash/dune index 373f1df63982..320f55b0cacb 100644 --- a/src/lib/with_hash/dune +++ b/src/lib/with_hash/dune @@ -5,7 +5,6 @@ ;; opam libraries bin_prot.shape sexplib0 - core_kernel ;; local libraries mina_wire_types ppx_version.runtime diff --git a/src/lib/work_partitioner/dune b/src/lib/work_partitioner/dune index 1beec6a9d2cb..ebf0ce659b8f 100644 --- a/src/lib/work_partitioner/dune +++ b/src/lib/work_partitioner/dune @@ -5,7 +5,6 @@ (libraries ;; OPAM libraries async - core_kernel ;; Local libraries mina_base snark_work_lib diff --git a/src/lib/work_selector/dune b/src/lib/work_selector/dune index 0a69fcaa4af3..e1936a5c668f 100644 --- a/src/lib/work_selector/dune +++ b/src/lib/work_selector/dune @@ -10,7 +10,6 @@ sexplib0 core async - core_kernel base base.base_internalhash_types async_kernel diff --git a/src/lib/zkapp_command_builder/dune b/src/lib/zkapp_command_builder/dune index dfc326a3957e..c57f3946358b 100644 --- a/src/lib/zkapp_command_builder/dune +++ b/src/lib/zkapp_command_builder/dune @@ -6,7 +6,6 @@ ;; opam libraries async_kernel async_unix - core_kernel ;; local libraries mina_base currency diff --git a/src/lib/zkapp_vk_cache_tag/dune b/src/lib/zkapp_vk_cache_tag/dune index 0046073e2db6..9edb6c07726b 100644 --- a/src/lib/zkapp_vk_cache_tag/dune +++ b/src/lib/zkapp_vk_cache_tag/dune @@ -2,7 +2,6 @@ (public_name zkapp_vk_cache_tag) (libraries ;; opam libraries - core_kernel async ;; local libraries logger diff --git a/src/libp2p_ipc/dune b/src/libp2p_ipc/dune index 3784401139df..2f84e24e4cf2 100644 --- a/src/libp2p_ipc/dune +++ b/src/libp2p_ipc/dune @@ -13,7 +13,6 @@ core capnp stdint - core_kernel async_unix ppx_sexp_conv.runtime-lib ppx_hash.runtime-lib diff --git a/src/test/archive/archive_node_tests/dune b/src/test/archive/archive_node_tests/dune index b1b533b57f08..99cd67b72611 100644 --- a/src/test/archive/archive_node_tests/dune +++ b/src/test/archive/archive_node_tests/dune @@ -3,7 +3,6 @@ (libraries ;; opam libraries async_kernel - core_kernel ppx_inline_test.config async core diff --git a/src/test/archive/patch_archive_test/dune b/src/test/archive/patch_archive_test/dune index 425733b865aa..348df9f4f9f0 100644 --- a/src/test/archive/patch_archive_test/dune +++ b/src/test/archive/patch_archive_test/dune @@ -5,7 +5,6 @@ (libraries async async.async_command - core_kernel caqti caqti-async caqti-driver-postgresql diff --git a/src/test/command_line_tests/dune b/src/test/command_line_tests/dune index fe64bbcfec2b..df4e602b0559 100644 --- a/src/test/command_line_tests/dune +++ b/src/test/command_line_tests/dune @@ -5,7 +5,6 @@ (libraries ;; opam libraries async_kernel - core_kernel ppx_inline_test.config async core diff --git a/src/test/mina_automation/dune b/src/test/mina_automation/dune index 05c36bf400c5..24a4bea6dc06 100644 --- a/src/test/mina_automation/dune +++ b/src/test/mina_automation/dune @@ -4,7 +4,6 @@ (libraries ;; opam libraries async_kernel - core_kernel ppx_inline_test.config async core From 4c33e6266b4b7dbbfb514ba0794f5868d5042fd7 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 19:09:54 +0800 Subject: [PATCH 08/56] remove ocaml-migrate-parsetree as it's replaced by ppxlib --- src/lib/crypto_params/gen/dune | 1 - src/lib/dummy_values/gen_values/dune | 1 - src/lib/generated_graphql_queries/gen/dune | 1 - src/lib/pickles/plonk_checks/dune | 1 - src/lib/ppx_register_event/dune | 1 - 5 files changed, 5 deletions(-) diff --git a/src/lib/crypto_params/gen/dune b/src/lib/crypto_params/gen/dune index 1092eda246d1..98b53810824f 100644 --- a/src/lib/crypto_params/gen/dune +++ b/src/lib/crypto_params/gen/dune @@ -10,7 +10,6 @@ digestif core async - ocaml-migrate-parsetree ppxlib.ast base bin_prot.shape diff --git a/src/lib/dummy_values/gen_values/dune b/src/lib/dummy_values/gen_values/dune index f9202d356e6e..c0afb19ad0a9 100644 --- a/src/lib/dummy_values/gen_values/dune +++ b/src/lib/dummy_values/gen_values/dune @@ -5,7 +5,6 @@ ;; opam libraries async_unix stdio - ocaml-migrate-parsetree core async ppxlib diff --git a/src/lib/generated_graphql_queries/gen/dune b/src/lib/generated_graphql_queries/gen/dune index 3cf9afdb88a6..92b83f8fa574 100644 --- a/src/lib/generated_graphql_queries/gen/dune +++ b/src/lib/generated_graphql_queries/gen/dune @@ -8,7 +8,6 @@ yojson mina_base compiler-libs - ocaml-migrate-parsetree stdio) (preprocess (pps ppx_base ppx_version ppxlib.metaquot graphql_ppx)) diff --git a/src/lib/pickles/plonk_checks/dune b/src/lib/pickles/plonk_checks/dune index 1a3deb694199..93401d172cab 100644 --- a/src/lib/pickles/plonk_checks/dune +++ b/src/lib/pickles/plonk_checks/dune @@ -13,7 +13,6 @@ ;; opam libraries sexplib0 ppxlib.ast - ocaml-migrate-parsetree base.base_internalhash_types ;; local libraries pickles_types diff --git a/src/lib/ppx_register_event/dune b/src/lib/ppx_register_event/dune index d6c6c77bb3ca..8feab21de508 100644 --- a/src/lib/ppx_register_event/dune +++ b/src/lib/ppx_register_event/dune @@ -9,7 +9,6 @@ ppx_deriving_yojson ppxlib compiler-libs.common - ocaml-migrate-parsetree base ;; local libraries interpolator_lib) From 68d92923ee11a4c48a1b3710a40883e3074be7ed Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:02:50 +0800 Subject: [PATCH 09/56] forbid core_unix instead of core as core_kernel is replaced by core --- src/lib/crypto/kimchi_bindings/js/test/nodejs/dune | 2 +- src/lib/mina_metrics/js_test/dune | 2 +- src/lib/o1js_stub/dune | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/crypto/kimchi_bindings/js/test/nodejs/dune b/src/lib/crypto/kimchi_bindings/js/test/nodejs/dune index 22de480f16f8..1842a74c1461 100644 --- a/src/lib/crypto/kimchi_bindings/js/test/nodejs/dune +++ b/src/lib/crypto/kimchi_bindings/js/test/nodejs/dune @@ -16,6 +16,6 @@ (link_deps ../../node_js/plonk_wasm.js ../../node_js/plonk_wasm_bg.wasm) (instrumentation (backend bisect_ppx)) - (forbidden_libraries core async) + (forbidden_libraries core_unix async) (preprocess (pps ppx_version js_of_ocaml-ppx))) diff --git a/src/lib/mina_metrics/js_test/dune b/src/lib/mina_metrics/js_test/dune index a1e4fb1f78dc..4fd7ac7ef61b 100644 --- a/src/lib/mina_metrics/js_test/dune +++ b/src/lib/mina_metrics/js_test/dune @@ -6,4 +6,4 @@ (backend bisect_ppx)) (preprocess (pps ppx_version)) - (forbidden_libraries async core re2)) + (forbidden_libraries async core_unix re2)) diff --git a/src/lib/o1js_stub/dune b/src/lib/o1js_stub/dune index 5f58aae04c4a..b9967a6b96c5 100644 --- a/src/lib/o1js_stub/dune +++ b/src/lib/o1js_stub/dune @@ -71,6 +71,6 @@ run_in_thread.fake) (instrumentation (backend bisect_ppx)) - (forbidden_libraries async core re2 ctypes) + (forbidden_libraries async core_unix re2 ctypes) (preprocess (pps ppx_custom_printf ppx_version js_of_ocaml-ppx))) From b9f2963bda6f3c241f5d6fadb63428e48832a05a Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:04:03 +0800 Subject: [PATCH 10/56] remove sexp_diff_kernel as it's replaced by sexp_diff --- src/lib/consensus/dune | 1 - src/lib/mina_base/dune | 1 - src/lib/testing/integration_test_lib/dune | 1 - src/lib/transaction_logic/dune | 1 - 4 files changed, 4 deletions(-) diff --git a/src/lib/consensus/dune b/src/lib/consensus/dune index 6af66aaff45d..747373b9753e 100644 --- a/src/lib/consensus/dune +++ b/src/lib/consensus/dune @@ -21,7 +21,6 @@ result core_kernel.uuid async_rpc_kernel - sexp_diff_kernel ;; local libraries mina_wire_types mina_base.util diff --git a/src/lib/mina_base/dune b/src/lib/mina_base/dune index e48cb78e54a3..62d9544163da 100644 --- a/src/lib/mina_base/dune +++ b/src/lib/mina_base/dune @@ -13,7 +13,6 @@ sexplib0 yojson digestif - sexp_diff_kernel base base.base_internalhash_types integers diff --git a/src/lib/testing/integration_test_lib/dune b/src/lib/testing/integration_test_lib/dune index f7916e5f20d1..28425cc30b4a 100644 --- a/src/lib/testing/integration_test_lib/dune +++ b/src/lib/testing/integration_test_lib/dune @@ -41,7 +41,6 @@ ppx_inline_test.config async_unix stdio - sexp_diff_kernel ;; local libraries key_gen visualization diff --git a/src/lib/transaction_logic/dune b/src/lib/transaction_logic/dune index d080b57969eb..97af91792589 100644 --- a/src/lib/transaction_logic/dune +++ b/src/lib/transaction_logic/dune @@ -9,7 +9,6 @@ ppx_inline_test.config sexplib0 yojson - sexp_diff_kernel base base.base_internalhash_types integers From f9765f4aca2fb7fa9f8ba12377bdf259755a51ce Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:12:29 +0800 Subject: [PATCH 11/56] remove a bunch of other libs that no longer exists --- src/app/cli/src/cli_entrypoint/dune | 1 - src/lib/node_status_service/dune | 1 - src/lib/o1trace/webkit_event/dune | 1 - src/lib/testing/itn_crypto/dune | 1 - 4 files changed, 4 deletions(-) diff --git a/src/app/cli/src/cli_entrypoint/dune b/src/app/cli/src/cli_entrypoint/dune index 5f5c722127eb..7c0d0ba4588c 100644 --- a/src/app/cli/src/cli_entrypoint/dune +++ b/src/app/cli/src/cli_entrypoint/dune @@ -13,7 +13,6 @@ bin_prot.shape init async - core.daemon uri async.async_command result diff --git a/src/lib/node_status_service/dune b/src/lib/node_status_service/dune index 4b85ee0940eb..8206ae11e344 100644 --- a/src/lib/node_status_service/dune +++ b/src/lib/node_status_service/dune @@ -6,7 +6,6 @@ (libraries ;; opam libraries core - core.linux_ext cohttp-async async cohttp diff --git a/src/lib/o1trace/webkit_event/dune b/src/lib/o1trace/webkit_event/dune index f732f0b7441f..e0ba735a2167 100644 --- a/src/lib/o1trace/webkit_event/dune +++ b/src/lib/o1trace/webkit_event/dune @@ -8,7 +8,6 @@ async_kernel async_unix core - core.time_stamp_counter sexplib0 ;; local libraries webkit_trace_event.binary diff --git a/src/lib/testing/itn_crypto/dune b/src/lib/testing/itn_crypto/dune index e6fe5689fe10..b9524cfc8b9c 100644 --- a/src/lib/testing/itn_crypto/dune +++ b/src/lib/testing/itn_crypto/dune @@ -9,7 +9,6 @@ cstruct mirage-crypto-ec mirage-crypto-rng - mirage-crypto-rng-async ;; local libraries codable) (instrumentation From fe52493a5a497861c4c698bb7b85439eac67b83a Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:30:55 +0800 Subject: [PATCH 12/56] node config: use relative inclusion for config.mlh --- src/lib/node_config/node_config.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/node_config/node_config.ml b/src/lib/node_config/node_config.ml index fb2aec07effc..8b8906f295a8 100644 --- a/src/lib/node_config/node_config.ml +++ b/src/lib/node_config/node_config.ml @@ -1,4 +1,4 @@ -[%%import "/src/config.mlh"] +[%%import "../../config.mlh"] (** This file consists of compile-time constants that are not in Genesis_constants. From 5f6327f60c5764951286bb74f219986c873cad08 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:32:54 +0800 Subject: [PATCH 13/56] patch lib/snark_keys_header to OCaml 5.2.1 --- src/lib/snark_keys_header/dune | 2 +- .../snark_keys_header/snark_keys_header.ml | 105 +++++++++--------- src/lib/snark_keys_header/tests/dune | 2 +- .../tests/test_snark_keys_header.ml | 2 +- 4 files changed, 56 insertions(+), 55 deletions(-) diff --git a/src/lib/snark_keys_header/dune b/src/lib/snark_keys_header/dune index 8844c4200f4d..2372962d5758 100644 --- a/src/lib/snark_keys_header/dune +++ b/src/lib/snark_keys_header/dune @@ -1,7 +1,7 @@ (library (name snark_keys_header) (public_name snark_keys_header) - (libraries base core_kernel integers result sexplib0 stdio) + (libraries base core integers result sexplib0 stdio) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/snark_keys_header/snark_keys_header.ml b/src/lib/snark_keys_header/snark_keys_header.ml index 9dd6042426ea..754642e269ac 100644 --- a/src/lib/snark_keys_header/snark_keys_header.ml +++ b/src/lib/snark_keys_header/snark_keys_header.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** The string that preceeds the JSON header, to identify the file kind before attempting to parse it. @@ -19,10 +19,10 @@ module UInt64 = struct | `String x -> Or_error.try_with (fun () -> Unsigned.UInt64.of_string x) |> Result.map_error ~f:(fun err -> - sprintf - "Snark_keys_header.UInt64.of_yojson: Could not parse string \ - as UInt64: %s" - (Error.to_string_hum err) ) + sprintf + "Snark_keys_header.UInt64.of_yojson: Could not parse string as \ + UInt64: %s" + (Error.to_string_hum err) ) | _ -> Error "Snark_keys_header.UInt64.of_yojson: Expected a string" @@ -146,67 +146,68 @@ let parse_prefix (lexbuf : Lexing.lexbuf) = Error.tag_arg err "Could not read prefix" ("prefix", prefix) [%sexp_of: string * string] ) @@ Or_error.try_with_join (fun () -> - (* This roughly mirrors the behavior of [Yojson.Safe.read_ident], + (* This roughly mirrors the behavior of [Yojson.Safe.read_ident], except that we have a known fixed length to parse, and that it is a failure to read any string except the prefix. We manually update the lexbuf to be consistent with the output of this function. *) - (* Manually step the lexbuffer forward to the [lex_curr_pos], so that + (* Manually step the lexbuffer forward to the [lex_curr_pos], so that [refill_buf] will know that we're only interested in buffer contents from that position onwards. *) - lexbuf.lex_start_pos <- lexbuf.lex_curr_pos ; - lexbuf.lex_last_pos <- lexbuf.lex_curr_pos ; - lexbuf.lex_start_p <- lexbuf.lex_curr_p ; - let%bind () = - (* Read more if the buffer doesn't contain the whole prefix. *) - if lexbuf.lex_buffer_len - lexbuf.lex_curr_pos >= prefix_len then - return () - else if lexbuf.lex_eof_reached then - Or_error.error_string "Unexpected end-of-file" - else ( - lexbuf.refill_buff lexbuf ; - if lexbuf.lex_buffer_len - lexbuf.lex_curr_pos >= prefix_len then - return () - else if lexbuf.lex_eof_reached then - Or_error.error_string "Unexpected end-of-file" - else - Or_error.error_string - "Unexpected short read: broken lexbuffer or end-of-file" ) - in - let read_prefix = - Lexing.sub_lexeme lexbuf lexbuf.lex_curr_pos - (lexbuf.lex_curr_pos + prefix_len) - in - let%map () = - if String.equal prefix read_prefix then return () - else - Or_error.error "Incorrect prefix" - ("read prefix", read_prefix) - [%sexp_of: string * string] - in - (* Update the positions to match our end state *) - lexbuf.lex_curr_pos <- lexbuf.lex_curr_pos + prefix_len ; - lexbuf.lex_last_pos <- lexbuf.lex_last_pos ; - lexbuf.lex_curr_p <- - { lexbuf.lex_curr_p with - pos_bol = lexbuf.lex_curr_p.pos_bol + prefix_len - ; pos_cnum = lexbuf.lex_curr_p.pos_cnum + prefix_len - } ; - (* This matches the action given by [Yojson.Safe.read_ident]. *) - lexbuf.lex_last_action <- 1 ) + lexbuf.lex_start_pos <- lexbuf.lex_curr_pos ; + lexbuf.lex_last_pos <- lexbuf.lex_curr_pos ; + lexbuf.lex_start_p <- lexbuf.lex_curr_p ; + let%bind () = + (* Read more if the buffer doesn't contain the whole prefix. *) + if lexbuf.lex_buffer_len - lexbuf.lex_curr_pos >= prefix_len then + return () + else if lexbuf.lex_eof_reached then + Or_error.error_string "Unexpected end-of-file" + else ( + lexbuf.refill_buff lexbuf ; + if lexbuf.lex_buffer_len - lexbuf.lex_curr_pos >= prefix_len then + return () + else if lexbuf.lex_eof_reached then + Or_error.error_string "Unexpected end-of-file" + else + Or_error.error_string + "Unexpected short read: broken lexbuffer or end-of-file" ) + in + let read_prefix = + Lexing.sub_lexeme lexbuf lexbuf.lex_curr_pos + (lexbuf.lex_curr_pos + prefix_len) + in + let%map () = + if String.equal prefix read_prefix then return () + else + Or_error.error "Incorrect prefix" + ("read prefix", read_prefix) + [%sexp_of: string * string] + in + (* Update the positions to match our end state *) + lexbuf.lex_curr_pos <- lexbuf.lex_curr_pos + prefix_len ; + lexbuf.lex_last_pos <- lexbuf.lex_last_pos ; + lexbuf.lex_curr_p <- + { lexbuf.lex_curr_p with + pos_bol = lexbuf.lex_curr_p.pos_bol + prefix_len + ; pos_cnum = lexbuf.lex_curr_p.pos_cnum + prefix_len + } ; + (* This matches the action given by [Yojson.Safe.read_ident]. *) + lexbuf.lex_last_action <- 1 ) let parse_lexbuf (lexbuf : Lexing.lexbuf) = let open Or_error.Let_syntax in Result.map_error ~f:(Error.tag ~tag:"Failed to read snark key header") - @@ let%bind () = parse_prefix lexbuf in - Or_error.try_with (fun () -> - let yojson_parsebuffer = Yojson.init_lexer () in - (* We use [read_t] here rather than one of the alternatives to avoid + @@ + let%bind () = parse_prefix lexbuf in + Or_error.try_with (fun () -> + let yojson_parsebuffer = Yojson.init_lexer () in + (* We use [read_t] here rather than one of the alternatives to avoid 'greedy' parsing that will attempt to continue and read the file's contents beyond the header. *) - Yojson.Safe.read_t yojson_parsebuffer lexbuf ) + Yojson.Safe.read_t yojson_parsebuffer lexbuf ) let write_with_header ~expected_max_size_log2 ~append_data header filename = (* In order to write the correct length here, we provide the maximum expected diff --git a/src/lib/snark_keys_header/tests/dune b/src/lib/snark_keys_header/tests/dune index c53aaef4815e..bc2a46aa312b 100644 --- a/src/lib/snark_keys_header/tests/dune +++ b/src/lib/snark_keys_header/tests/dune @@ -1,5 +1,5 @@ (tests (names test_snark_keys_header) - (libraries alcotest core_kernel snark_keys_header) + (libraries alcotest core snark_keys_header) (preprocess (pps ppx_let))) diff --git a/src/lib/snark_keys_header/tests/test_snark_keys_header.ml b/src/lib/snark_keys_header/tests/test_snark_keys_header.ml index 205b8ca8ff7d..ace5dcb64404 100644 --- a/src/lib/snark_keys_header/tests/test_snark_keys_header.ml +++ b/src/lib/snark_keys_header/tests/test_snark_keys_header.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* Import the module we're testing *) module Header = Snark_keys_header From fe4ef8a372355ac2bc70fd6d8c999b3cf26c2457 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:33:08 +0800 Subject: [PATCH 14/56] patch lib/webkit_trace_event for 5.2.1 --- src/lib/webkit_trace_event/webkit_trace_event.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/webkit_trace_event/webkit_trace_event.ml b/src/lib/webkit_trace_event/webkit_trace_event.ml index c69d2d815728..9c73873e7cc5 100644 --- a/src/lib/webkit_trace_event/webkit_trace_event.ml +++ b/src/lib/webkit_trace_event/webkit_trace_event.ml @@ -3,7 +3,7 @@ https://docs.google.com/document/d/1CvAClvFfyA5R-PhYUmn5OOQtYMH4h6I0nSsKchNAySU/ *) -open Core_kernel +open Core type event_kind = | New_thread From 9e3a48b393db14380e79656695a04920046aaccc Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:33:35 +0800 Subject: [PATCH 15/56] patch lib/visualization for 5.2.1 --- src/lib/visualization/dune | 2 +- src/lib/visualization/visualization.ml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/visualization/dune b/src/lib/visualization/dune index 67ae073673d7..828731b5b973 100644 --- a/src/lib/visualization/dune +++ b/src/lib/visualization/dune @@ -1,7 +1,7 @@ (library (name visualization) (public_name visualization) - (libraries core_kernel async_kernel ocamlgraph yojson sexplib0) + (libraries core async_kernel ocamlgraph yojson sexplib0) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/visualization/visualization.ml b/src/lib/visualization/visualization.ml index 6f5865def71d..3ceb50750595 100644 --- a/src/lib/visualization/visualization.ml +++ b/src/lib/visualization/visualization.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** [Visualization] is a set of tools that lets a client visualize complex data structures like the transition_frontier *) From 2ea457c80e58b1e414be8d48eb3239059c71afd5 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:34:08 +0800 Subject: [PATCH 16/56] patch lib/ppx_util for 5.2.1 --- src/lib/ppx_util/dune | 3 ++- src/lib/ppx_util/ppx_util.ml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lib/ppx_util/dune b/src/lib/ppx_util/dune index e7d96b3aac49..9b08b8bfd93f 100644 --- a/src/lib/ppx_util/dune +++ b/src/lib/ppx_util/dune @@ -6,7 +6,8 @@ (flags -verbose -show-counts)) (libraries ;; opam libraries - ppxlib) + ppxlib + core) (preprocess (pps ppx_version ppx_jane ppxlib.metaquot)) (instrumentation diff --git a/src/lib/ppx_util/ppx_util.ml b/src/lib/ppx_util/ppx_util.ml index e937f0bd5f9e..14d581f24cad 100644 --- a/src/lib/ppx_util/ppx_util.ml +++ b/src/lib/ppx_util/ppx_util.ml @@ -1,5 +1,5 @@ open Ppxlib -open Core_kernel +open Core let expr_of_sexp ~loc s = let module E = Ppxlib.Ast_builder.Make (struct From c106b58e3ae04f2782eea02fdd801e41069e7558 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:34:41 +0800 Subject: [PATCH 17/56] patch lib/ppx_annot for 5.2.1 --- src/lib/ppx_annot/dune | 2 +- src/lib/ppx_annot/ppx_annot.ml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/ppx_annot/dune b/src/lib/ppx_annot/dune index aa95595a50e3..287392b1e884 100644 --- a/src/lib/ppx_annot/dune +++ b/src/lib/ppx_annot/dune @@ -2,7 +2,7 @@ (name ppx_annot) (public_name ppx_annot) (kind ppx_deriver) - (libraries ppxlib core_kernel base compiler-libs) + (libraries ppxlib core base compiler-libs) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/ppx_annot/ppx_annot.ml b/src/lib/ppx_annot/ppx_annot.ml index e5368e69ba42..b2c782a8679d 100644 --- a/src/lib/ppx_annot/ppx_annot.ml +++ b/src/lib/ppx_annot/ppx_annot.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Ppxlib open Ast_builder.Default From 072fde9c382ec6f593f5a148463758e5b8eca5d6 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:36:11 +0800 Subject: [PATCH 18/56] patch lib/sync_status for 5.2.1 --- src/lib/sync_status/sync_status.ml | 2 +- src/lib/sync_status/tests/test_sync_status.ml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lib/sync_status/sync_status.ml b/src/lib/sync_status/sync_status.ml index 4da10a6db8c9..5c70edac23a5 100644 --- a/src/lib/sync_status/sync_status.ml +++ b/src/lib/sync_status/sync_status.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** Sync_status represent states interacting with peers in the Mina protocol. When the protocol is starting, the node should be in the CONNECT state diff --git a/src/lib/sync_status/tests/test_sync_status.ml b/src/lib/sync_status/tests/test_sync_status.ml index 705fc19839dc..4f2b0b5f05c1 100644 --- a/src/lib/sync_status/tests/test_sync_status.ml +++ b/src/lib/sync_status/tests/test_sync_status.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Sync_status (* Test helper to check round-trip conversion *) @@ -37,7 +37,7 @@ let test_json_conversion () = | Error e -> failwith e | Ok x -> - x ) ) + x )) (* Individual JSON conversion tests for better error reporting *) let test_json_conversions_individual () = From 1256b3880f09441ef67da500cbb8c3a89efa6ea9 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:42:38 +0800 Subject: [PATCH 19/56] patch lib/structured_log_events for 5.2.1 --- src/lib/structured_log_events/structured_log_events.ml | 10 ++++------ .../structured_log_events/structured_log_events.mli | 2 +- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/src/lib/structured_log_events/structured_log_events.ml b/src/lib/structured_log_events/structured_log_events.ml index 4322c0cf6021..e845669ad57e 100644 --- a/src/lib/structured_log_events/structured_log_events.ml +++ b/src/lib/structured_log_events/structured_log_events.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type t = .. @@ -33,7 +33,7 @@ let parse_exn id json_pairs = message. *) List.filter json_pairs ~f:(fun (field_name, _) -> - Set.mem repr.arguments field_name ) + Core.Set.mem repr.arguments field_name ) in match repr.parse json_pairs with | Some t -> @@ -64,16 +64,14 @@ let log t = | Some data -> data | None -> - let[@warning "-3"] name = - Obj.extension_name (Obj.extension_constructor t) - in + let[@warning "-3"] name = Obj.Extension_constructor.(of_val t |> name) in failwithf "log: did not find matching logger for %s" name () let register_constructor = Registry.register_constructor let dump_registered_events () = List.map !Registry.reprs ~f:(fun { event_name; id; arguments; _ } -> - (event_name, id, Set.to_list arguments) ) + (event_name, id, Core.Set.to_list arguments) ) let check_interpolations_exn ~msg_loc msg label_names = (* don't use Logproc_lib, which depends on C++ code diff --git a/src/lib/structured_log_events/structured_log_events.mli b/src/lib/structured_log_events/structured_log_events.mli index ff705440c303..0b7e4bddb482 100644 --- a/src/lib/structured_log_events/structured_log_events.mli +++ b/src/lib/structured_log_events/structured_log_events.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** The type of structured log events. From 6d082f20ec55dc41219b0a91099e6979269562b7 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:52:15 +0800 Subject: [PATCH 20/56] CHATGPT_GENERATED: patch ppx_register_event for 5.2.1 --- src/lib/ppx_register_event/register_event.ml | 68 +++++++++----------- 1 file changed, 32 insertions(+), 36 deletions(-) diff --git a/src/lib/ppx_register_event/register_event.ml b/src/lib/ppx_register_event/register_event.ml index 7a1fb9a12bd4..35b5611b045f 100644 --- a/src/lib/ppx_register_event/register_event.ml +++ b/src/lib/ppx_register_event/register_event.ml @@ -31,7 +31,7 @@ [@@deriving register_event { msg = "n = $n, s = $s, and p = $p" } ] *) -open Core_kernel +open Core open Ppxlib let deriver = "register_event" @@ -66,10 +66,10 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = let ctor, label_decls = match ty_ext.ptyext_constructors with (* record argument *) - | [ { pext_name; pext_kind = Pext_decl (Pcstr_record labels, None); _ } ] -> + | [ { pext_name; pext_kind = Pext_decl (_, Pcstr_record labels, _); _ } ] -> (pext_name.txt, labels) (* no arguments *) - | [ { pext_name; pext_kind = Pext_decl (Pcstr_tuple [], None); _ } ] -> + | [ { pext_name; pext_kind = Pext_decl (_, Pcstr_tuple [], _); _ } ] -> (pext_name.txt, []) | _ -> Location.raise_errorf ~loc:ty_ext.ptyext_path.loc @@ -81,7 +81,7 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = in let has_record_arg = not @@ List.is_empty label_names in let deriver_loc = - (* succeeds, because we're calling this deriver *) + (* succeeds because we're calling this deriver *) let find_deriver = function | { pstr_desc = Pstr_eval ({ pexp_desc = Pexp_ident { txt = Lident id; loc }; _ }, _) @@ -114,6 +114,7 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = in let (module Ast_builder) = Ast_builder.make deriver_loc in let open Ast_builder in + (* message expression *) let (msg : expression), msg_loc = match msg_opt with | Some expr -> @@ -133,12 +134,12 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = let checked_interpolations = checked_interpolations_statically ~loc:msg_loc msg label_names in + let event_name = String.lowercase ctor in let event_path = path ^ "." ^ ctor in - let split_path = String.split path ~on:'.' in - let to_yojson = Ppx_deriving_yojson.ser_expr_of_typ in - let of_yojson = Ppx_deriving_yojson.desu_expr_of_typ in + let elist ~f l = elist (List.map ~f l) in + let record_pattern = let arg = if has_record_arg then @@ -151,6 +152,7 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = in ppat_construct (Located.mk (Lident ctor)) arg in + let record_expr = let arg = if has_record_arg then @@ -163,6 +165,7 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = in pexp_construct (Located.mk (Lident ctor)) arg in + let stris = [ [%stri let ([%p pvar (event_name ^ "_structured_events_id")] : @@ -182,43 +185,37 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = ( [%e msg] , [%e elist label_decls - ~f:(fun { pld_name = { txt = name; _ }; pld_type; _ } - -> - Ppx_deriving_yojson.wrap_runtime - @@ [%expr - [%e estring name] - , [%e to_yojson pld_type] [%e evar name]] )] ) + ~f:(fun + { pld_name = { txt = name; _ }; pld_type; _ } -> + [%expr + [%e estring name] + , [%to_yojson: [%t pld_type]] [%e evar name]] )] ) | _ -> None ) ; parse = (fun args -> let result = let args_list = Core_kernel.String.Map.of_alist_exn args in - (* We use this to avoid an unused value warning. *) ignore args_list ; [%e List.fold_right label_decls - ~f:(fun { pld_name = { txt = name; _ }; pld_type; _ } acc -> - Ppx_deriving_yojson.wrap_runtime - @@ [%expr - let module Result = Core_kernel.Result in - match - Core_kernel.Map.find args_list [%e estring name] - with - | Some [%p pvar name] -> - Result.bind - ([%e - of_yojson - ~path:(split_path @ [ ctor; name ]) - pld_type] - [%e evar name] ) - ~f:(fun [%p pvar name] -> [%e acc]) - | None -> - Result.fail - [%e - estring - (sprintf "%s, parse: missing argument %s" - event_path name )]] ) + ~f:(fun + { pld_name = { txt = name; _ }; pld_type; _ } acc -> + [%expr + let module Result = Core_kernel.Result in + match + Core_kernel.Map.find args_list [%e estring name] + with + | Some [%p pvar name] -> + Result.bind + ([%of_yojson: [%t pld_type]] [%e evar name]) + ~f:(fun [%p pvar name] -> [%e acc]) + | None -> + Result.fail + [%e + estring + (sprintf "%s, parse: missing argument %s" + event_path name )]] ) ~init:[%expr Core_kernel.Result.return [%e record_expr]]] in match result with Ok ev -> Some ev | Error _ -> None ) @@ -232,7 +229,6 @@ let generate_loggers_and_parsers ~loc:_ ~path ty_ext msg_opt = if checked_interpolations then stris else let msg_loc_str = - (* same formatting as in Ppxlib.Location.print *) estring (sprintf "File \"%s\", line %d, characters %d-%d:" msg_loc.loc_start.pos_fname msg_loc.loc_start.pos_lnum From 0f55832ad946bee907c8b32157437a0e3aa338dd Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:54:15 +0800 Subject: [PATCH 21/56] patch lib/ppx_mina for 5.2.1 --- src/lib/ppx_mina/define_from_scope.ml | 2 +- src/lib/ppx_mina/define_locally.ml | 2 +- src/lib/ppx_mina/expires_after.ml | 8 ++++---- src/lib/ppx_mina/getenv_ppx.ml | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/lib/ppx_mina/define_from_scope.ml b/src/lib/ppx_mina/define_from_scope.ml index 4f9e7fb6928e..4ae112b6b0b5 100644 --- a/src/lib/ppx_mina/define_from_scope.ml +++ b/src/lib/ppx_mina/define_from_scope.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Ppxlib open Asttypes diff --git a/src/lib/ppx_mina/define_locally.ml b/src/lib/ppx_mina/define_locally.ml index ca828693781b..c22b991525c4 100644 --- a/src/lib/ppx_mina/define_locally.ml +++ b/src/lib/ppx_mina/define_locally.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Ppxlib (* define_locally mirrors local definitions from some other module diff --git a/src/lib/ppx_mina/expires_after.ml b/src/lib/ppx_mina/expires_after.ml index 230755486268..85864a273dc7 100644 --- a/src/lib/ppx_mina/expires_after.ml +++ b/src/lib/ppx_mina/expires_after.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Ppxlib (** This is a ppx to flag code that will expire after a certain date @@ -24,12 +24,12 @@ let expand ~loc ~path:_ str = if String.length str.txt > 8 then Location.raise_errorf ~loc:str.loc "Not a valid date, string too long; must be in form YYYYMMDD" ; - Core_kernel.Date.of_string_iso8601_basic ~pos:0 str.txt + Date.of_string_iso8601_basic ~pos:0 str.txt with _ -> Location.raise_errorf ~loc:str.loc "Not a valid date; must be in form YYYYMMDD" in - let today = Date.today ~zone:Time.Zone.utc in + let today = Date.today ~zone:Time_float.Zone.utc in if Date.( >= ) today date then Location.raise_errorf ~loc:str.loc "Code is expired" ; [%stri let () = ()] @@ -37,7 +37,7 @@ let expand ~loc ~path:_ str = let ext = Extension.declare name Extension.Context.structure_item Ast_pattern.( - single_expr_payload (pexp_constant (pconst_string __' drop drop))) + single_expr_payload (pexp_constant (pconst_string __' drop drop)) ) expand let () = diff --git a/src/lib/ppx_mina/getenv_ppx.ml b/src/lib/ppx_mina/getenv_ppx.ml index 8ef8bf56cb89..b4b30bd0ad7f 100644 --- a/src/lib/ppx_mina/getenv_ppx.ml +++ b/src/lib/ppx_mina/getenv_ppx.ml @@ -3,7 +3,7 @@ open Ppxlib let name = "getenv" let expand ~loc ~path:_ var = - match Caml.Sys.getenv var with + match Sys.getenv var with | s -> [%expr Some [%e Ast_builder.Default.estring s ~loc]] | exception Not_found -> From ba207b2250b7499374740e5f0cd0a95cbf889340 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:54:53 +0800 Subject: [PATCH 22/56] patch lib/fields_deriviers for 5.2.1 --- src/lib/fields_derivers/fields_derivers.ml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/lib/fields_derivers/fields_derivers.ml b/src/lib/fields_derivers/fields_derivers.ml index 7fb606fef7db..4d5c504bbbb0 100644 --- a/src/lib/fields_derivers/fields_derivers.ml +++ b/src/lib/fields_derivers/fields_derivers.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Annotations = struct module Utils = struct @@ -91,7 +91,6 @@ let under_to_camel s = String.concat [ prefix_us; result ] let%test_unit "under_to_camel works as expected" = - let open Core_kernel in [%test_eq: string] "fooHello" (under_to_camel "foo_hello") ; [%test_eq: string] "fooHello" (under_to_camel "foo_hello___") ; [%test_eq: string] "_fooHello" (under_to_camel "_foo_hello__") From e4f78261f9298eb1ef3315352515add4a308e1c3 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:56:25 +0800 Subject: [PATCH 23/56] patch lib/fields_derivers_graphql for 5.2.1 --- .../fields_derivers_graphql.ml | 48 ++++++++++--------- 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/src/lib/fields_derivers_graphql/fields_derivers_graphql.ml b/src/lib/fields_derivers_graphql/fields_derivers_graphql.ml index 608890ebe061..3d230cd237b4 100644 --- a/src/lib/fields_derivers_graphql/fields_derivers_graphql.ml +++ b/src/lib/fields_derivers_graphql/fields_derivers_graphql.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Fieldslib module Graphql_raw = struct @@ -138,7 +138,7 @@ module Graphql_raw = struct obj ?doc:annotations.doc (annotations.name ^ "Input") ~fields:graphql_arg_fields ~coerce:graphql_arg_coerce - |> non_null) ) ; + |> non_null ) ) ; (acc#nullable_graphql_arg := fun () -> match !(acc#graphql_arg_accumulator) with @@ -150,7 +150,7 @@ module Graphql_raw = struct @@ Schema.Arg.( obj ?doc:annotations.doc (annotations.name ^ "Input") - ~fields:graphql_arg_fields ~coerce:graphql_arg_coerce) + ~fields:graphql_arg_fields ~coerce:graphql_arg_coerce ) ) ; acc @@ -286,10 +286,10 @@ module Graphql_raw = struct { Input.T.run = (fun () -> Schema.obj annotations.name ?doc:annotations.doc - ~fields:(fun _ -> - List.rev + ~fields: + ( List.rev @@ List.filter_map graphql_fields_accumulator ~f:(fun g -> - g.Accumulator.T.run () ) ) + g.Accumulator.T.run () ) ) |> Schema.non_null ) } in @@ -297,10 +297,10 @@ module Graphql_raw = struct { Input.T.run = (fun () -> Schema.obj annotations.name ?doc:annotations.doc - ~fields:(fun _ -> - List.rev + ~fields: + ( List.rev @@ List.filter_map graphql_fields_accumulator ~f:(fun g -> - g.Accumulator.T.run () ) ) ) + g.Accumulator.T.run () ) ) ) } in obj#graphql_fields := graphql_fields ; @@ -436,11 +436,11 @@ module Graphql_query = struct let rest = !(acc_obj#graphql_query_accumulator) in acc_obj#graphql_query_accumulator := ( if annotations.skip || !(t_field#skip) then None - else - Some - ( Option.value annotations.name - ~default:(Fields_derivers.name_under_to_camel field) - , !(t_field#graphql_query) ) ) + else + Some + ( Option.value annotations.name + ~default:(Fields_derivers.name_under_to_camel field) + , !(t_field#graphql_query) ) ) :: rest ; ((fun _ -> failwith "unused"), acc_obj) @@ -492,7 +492,7 @@ module IO = struct let map t f = Async_kernel.Pipe.map' t ~f:(fun q -> - Async_kernel.Deferred.Queue.map q ~f ) + Async_kernel.Deferred.Queue.map ~how:`Sequential q ~f ) let iter t f = Async_kernel.Pipe.iter t ~f @@ -620,7 +620,7 @@ let%test_module "Test" = field "query" ~typ:(non_null typ) ~args:Arg.[] ~doc:"sample query" - ~resolve:(fun _ _ -> v)) + ~resolve:(fun _ _ -> v) ) let query_for_all typ v str = raw_server (query_schema typ v) (Test.parse_query str) @@ -636,7 +636,7 @@ let%test_module "Test" = field "args" ~typ:(non_null int) ~args:Arg.[ arg "input" ~typ:arg_typ ] ~doc:"sample args query" - ~resolve:(fun _ _ _ -> 0)) + ~resolve:(fun _ _ _ -> 0) ) module T1 = struct (** T1 is foo *) @@ -653,7 +653,8 @@ let%test_module "Test" = let manual_typ = Schema.( - obj "T1" ~doc ~fields:(fun _ -> + obj "T1" ~doc + ~fields: [ field "fooHello" ~args:Arg.[] ~typ:int @@ -662,7 +663,7 @@ let%test_module "Test" = ~args:Arg.[] ~typ:(non_null (list (non_null string))) ~resolve:(fun _ t -> t.bar) - ] )) + ] ) let derived init = let open Graphql_fields in @@ -681,7 +682,7 @@ let%test_module "Test" = [ arg "bar1" ~typ:(non_null (list (non_null string))) ; arg "fooHello" ~typ:int ] - ~coerce:(fun bar foo_hello -> { bar; skipped = 0; foo_hello })) + ~coerce:(fun bar foo_hello -> { bar; skipped = 0; foo_hello }) ) let derived init = let open Graphql_args in @@ -748,12 +749,13 @@ let%test_module "Test" = let manual_typ = Schema.( - obj "T2" ?doc:None ~fields:(fun _ -> + obj "T2" ?doc:None + ~fields: [ field "foo" ~args:Arg.[] ~typ:T1.manual_typ ~resolve:(fun _ t -> Or_ignore_test.to_option t.foo) - ] )) + ] ) let derived init = let open Graphql_fields in @@ -767,7 +769,7 @@ let%test_module "Test" = Schema.Arg.( obj "T2Input" ?doc:None ~fields:[ arg "foo" ~typ:T1.Args.manual_typ ] - ~coerce:(fun foo -> Or_ignore_test.of_option foo)) + ~coerce:(fun foo -> Or_ignore_test.of_option foo) ) let derived init = let open Graphql_args in From 856e51a984dfdafcdb13d31f35ffdbd41827295d Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:59:05 +0800 Subject: [PATCH 24/56] mina version: patch to 5.2.1 --- src/lib/mina_version/dummy/dune | 1 - src/lib/mina_version/dummy/mina_version.ml | 2 +- src/lib/mina_version/normal/gen.sh | 2 +- src/lib/mina_version/runtime/dune | 2 +- src/lib/mina_version/runtime/mina_version.ml | 2 +- 5 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/lib/mina_version/dummy/dune b/src/lib/mina_version/dummy/dune index 70576d2c5b29..22202d428578 100644 --- a/src/lib/mina_version/dummy/dune +++ b/src/lib/mina_version/dummy/dune @@ -1,6 +1,5 @@ (library (name mina_version_dummy) - (libraries core_kernel base) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/mina_version/dummy/mina_version.ml b/src/lib/mina_version/dummy/mina_version.ml index 10047a4df25a..79c45fc741f0 100644 --- a/src/lib/mina_version/dummy/mina_version.ml +++ b/src/lib/mina_version/dummy/mina_version.ml @@ -2,4 +2,4 @@ let commit_id = "[UNKNOWN]" let commit_id_short = "[UNKNOWN]" -let print_version () = Core_kernel.printf "Commit %s\n%!" commit_id +let print_version () = Printf.printf "Commit %s\n%!" commit_id diff --git a/src/lib/mina_version/normal/gen.sh b/src/lib/mina_version/normal/gen.sh index d37f3a7e75ba..3c37d35e4f83 100755 --- a/src/lib/mina_version/normal/gen.sh +++ b/src/lib/mina_version/normal/gen.sh @@ -17,5 +17,5 @@ id_short="$(printf "%s" "$id" | cut -c1-8)" printf 'let commit_id = "%s"\n' "$id" printf 'let commit_id_short = "%s"\n' "$id_short" - printf 'let print_version () = Core_kernel.printf "Commit %%s\\n%%!" commit_id\n' + printf 'let print_version () = Printf.printf "Commit %%s\\n%%!" commit_id\n' } > "$1" diff --git a/src/lib/mina_version/runtime/dune b/src/lib/mina_version/runtime/dune index 4c7cde02807d..d6a628a06cda 100644 --- a/src/lib/mina_version/runtime/dune +++ b/src/lib/mina_version/runtime/dune @@ -1,6 +1,6 @@ (library (name mina_version_runtime) - (libraries core_kernel base unix) + (libraries base unix) (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/mina_version/runtime/mina_version.ml b/src/lib/mina_version/runtime/mina_version.ml index 75c7cf56aec3..e8bf83afbf43 100644 --- a/src/lib/mina_version/runtime/mina_version.ml +++ b/src/lib/mina_version/runtime/mina_version.ml @@ -2,4 +2,4 @@ let commit_id = Unix.getenv "MINA_COMMIT_SHA1" let commit_id_short = String.sub commit_id 0 7 -let print_version () = Core_kernel.printf "Commit %s\n%!" commit_id +let print_version () = Printf.printf "Commit %s\n%!" commit_id From 2731a2ef89b57a7fa77237ba7bae446d31bca197 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:59:34 +0800 Subject: [PATCH 25/56] snark_field_extensions: patch for 5.2.1 --- .../field_extensions.ml | 49 ++++++++++--------- 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/src/lib/snarky_field_extensions/field_extensions.ml b/src/lib/snarky_field_extensions/field_extensions.ml index b284dc2a6c2d..047a2d19e40d 100644 --- a/src/lib/snarky_field_extensions/field_extensions.ml +++ b/src/lib/snarky_field_extensions/field_extensions.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Make_test (F : Intf.Basic) = struct let test arg_typ gen_arg sexp_of_arg label unchecked checked = @@ -7,8 +7,8 @@ module Make_test (F : Intf.Basic) = struct let r = run_and_check (let open Checked.Let_syntax in - let%bind x = exists arg_typ ~compute:(As_prover.return x) in - checked x >>| As_prover.read F.typ) + let%bind x = exists arg_typ ~compute:(As_prover.return x) in + checked x >>| As_prover.read F.typ ) |> Or_error.ok_exn in r @@ -105,8 +105,7 @@ module Make (F : Intf.Basic) = struct let%bind res = exists typ ~compute: - As_prover.( - map2 (read typ x) (read typ y) ~f:Unchecked.( * )) + As_prover.(map2 (read typ x) (read typ y) ~f:Unchecked.( * )) in let%map () = assert_r1cs x y res in res ) @@ -147,8 +146,7 @@ module Make (F : Intf.Basic) = struct return (constant (Unchecked.inv x)) | None -> let%bind res = - exists typ - ~compute:As_prover.(map (read typ t) ~f:Unchecked.inv) + exists typ ~compute:As_prover.(map (read typ t) ~f:Unchecked.inv) in let%map () = assert_r1cs t res one in res ) @@ -293,7 +291,8 @@ end such that x^2 - s does not have a root in F, construct the field F(sqrt(s)) = F[x] / (x^2 - s) *) module E2 - (F : Intf.S) (Params : sig + (F : Intf.S) + (Params : sig val non_residue : F.Unchecked.t val mul_by_non_residue : F.t -> F.t @@ -431,7 +430,8 @@ module T3 = struct end module E3 - (F : Intf.S) (Params : sig + (F : Intf.S) + (Params : sig val non_residue : F.Unchecked.t val frobenius_coeffs_c1 : F.Unchecked.t array @@ -589,7 +589,8 @@ module E3 end module F3 - (F : Intf.S with type 'a A.t = 'a and type 'a Base.t_ = 'a) (Params : sig + (F : Intf.S with type 'a A.t = 'a and type 'a Base.t_ = 'a) + (Params : sig val non_residue : F.Unchecked.t val frobenius_coeffs_c1 : F.Unchecked.t array @@ -692,9 +693,10 @@ module Cyclotomic_square = struct end module Make_F6 - (F2 : Intf.S_with_primitive_element - with type 'a A.t = 'a * 'a - and type 'a Base.t_ = 'a) + (F2 : + Intf.S_with_primitive_element + with type 'a A.t = 'a * 'a + and type 'a Base.t_ = 'a) (Params : sig val cubic_non_residue : F2.Impl.Field.t end) = @@ -722,10 +724,11 @@ end module F6 (Fq : Intf.S with type 'a A.t = 'a and type 'a Base.t_ = 'a) - (Fq2 : Intf.S_with_primitive_element - with module Impl = Fq.Impl - and type 'a A.t = 'a * 'a - and type 'a Base.t_ = 'a Fq.t_) + (Fq2 : + Intf.S_with_primitive_element + with module Impl = Fq.Impl + and type 'a A.t = 'a * 'a + and type 'a Base.t_ = 'a Fq.t_) (Fq3 : sig include Intf.S_with_primitive_element @@ -740,7 +743,8 @@ module F6 val frobenius_coeffs_c2 : Fq.Unchecked.t array end - end) (Params : sig + end) + (Params : sig val frobenius_coeffs_c1 : Fq.Unchecked.t array end) = struct @@ -778,7 +782,7 @@ struct exists Fq3.typ ~compute: As_prover.( - map2 ~f:Fq3.Unchecked.( * ) (read Fq3.typ a0) (read Fq3.typ b0)) + map2 ~f:Fq3.Unchecked.( * ) (read Fq3.typ a0) (read Fq3.typ b0) ) (* v0 = (a00 + s a01 s^2 a02) (s^2 b02) = non_residue a01 b02 + non_residue s a02 b02 + s^2 a00 b02 *) @@ -836,9 +840,10 @@ struct end module F4 - (Fq2 : Intf.S_with_primitive_element - with type 'a A.t = 'a * 'a - and type 'a Base.t_ = 'a) + (Fq2 : + Intf.S_with_primitive_element + with type 'a A.t = 'a * 'a + and type 'a Base.t_ = 'a) (Params : sig val frobenius_coeffs_c1 : Fq2.Impl.Field.t array end) = From 203d419e5d32958b123bbaf3628b736ce3dfa984 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 22:00:47 +0800 Subject: [PATCH 26/56] app > reformat: patch for 5.2.1 --- src/app/reformat/dune | 1 + src/app/reformat/reformat.ml | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/reformat/dune b/src/app/reformat/dune index 22040fe29d7e..fd65b10602d8 100644 --- a/src/app/reformat/dune +++ b/src/app/reformat/dune @@ -3,6 +3,7 @@ (public_name reformat) (libraries core + core_unix.command_unix async async.async_command async_kernel diff --git a/src/app/reformat/reformat.ml b/src/app/reformat/reformat.ml index 57a73ebd1356..e29646cfcd05 100644 --- a/src/app/reformat/reformat.ml +++ b/src/app/reformat/reformat.ml @@ -109,6 +109,6 @@ let _cli = ~doc:"Return with error code if any file needs formatting" in fun () -> main dry_run check path ) - |> Command.run + |> Command_unix.run let () = never_returns (Scheduler.go ()) From e6f585e56f9e0933a5a3682fcfc3ba0b37402db1 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 22:02:34 +0800 Subject: [PATCH 27/56] patch lib/signature_kind to 5.2.1 --- src/lib/signature_kind/type/mina_signature_kind_type.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/signature_kind/type/mina_signature_kind_type.ml b/src/lib/signature_kind/type/mina_signature_kind_type.ml index 7b4c05f102fd..afa7a9369b18 100644 --- a/src/lib/signature_kind/type/mina_signature_kind_type.ml +++ b/src/lib/signature_kind/type/mina_signature_kind_type.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type t = Testnet | Mainnet | Other_network of string [@@deriving bin_io_unversioned, to_yojson] From c764cd17ec50a2716cfa3ba6f76306a35b8274ca Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 22:43:25 +0800 Subject: [PATCH 28/56] lib/testing/itn_logger: bump to 5.2.1 --- src/lib/testing/itn_logger/dune | 2 +- src/lib/testing/itn_logger/itn_logger.ml | 13 +++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/lib/testing/itn_logger/dune b/src/lib/testing/itn_logger/dune index 0507c53e72fe..bfbab4c27ff5 100644 --- a/src/lib/testing/itn_logger/dune +++ b/src/lib/testing/itn_logger/dune @@ -12,4 +12,4 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_version ppx_mina ppx_jane))) + (pps ppx_let ppx_version ppx_mina))) diff --git a/src/lib/testing/itn_logger/itn_logger.ml b/src/lib/testing/itn_logger/itn_logger.ml index 11e5f50c997e..3cb7e981de49 100644 --- a/src/lib/testing/itn_logger/itn_logger.ml +++ b/src/lib/testing/itn_logger/itn_logger.ml @@ -12,7 +12,7 @@ type t = (* log received from verifier or prover *) type remote_log = - { timestamp : Time.t + { timestamp : Time_float.t ; message : string ; metadata : (string * string) list ; process : string @@ -64,7 +64,7 @@ module Submit_internal_log = struct let rpc : (query, response) Async.Rpc.Rpc.t = Async.Rpc.Rpc.create ~name:"Submit_internal_log" ~version:0 ~bin_query - ~bin_response + ~bin_response ~include_in_error_count:Only_on_exn end let dispatch_remote_log log = @@ -81,7 +81,7 @@ let dispatch_remote_log log = let%map res = Async.Rpc.Connection.with_client ~handshake_timeout: - (Time.Span.of_sec + (Time_float.Span.of_sec Node_config_unconfigurable_constants.rpc_handshake_timeout_sec ) ~heartbeat_config: (Async.Rpc.Connection.Heartbeat_config.create @@ -145,7 +145,8 @@ let log ?process ~timestamp ~message ~metadata () = in let t = { sequence_no = get_counter () - ; timestamp = Time.to_string_abs timestamp ~zone:Time.Zone.utc + ; timestamp = + Time_float.to_string_abs timestamp ~zone:Time_float.Zone.utc ; message ; metadata ; process @@ -172,10 +173,10 @@ let flush_queue end_log_counter = (* Post-processing hook *) type message_postprocessor = - timestamp:Time.t + timestamp:Time_float.t -> message:string -> metadata:(string * Yojson.Safe.t) list - -> (Time.t * string * (string * Yojson.Safe.t) list) list + -> (Time_float.t * string * (string * Yojson.Safe.t) list) list let set_message_postprocessor, postprocess_message = let message_postprocessor : message_postprocessor ref = From 74ac439e5641e8dc7e10a098f5e3a4e6c76af8b1 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 22:45:13 +0800 Subject: [PATCH 29/56] lib/logger: bump to 5.2.1 --- .../logger/context_logger/context_logger.ml | 2 +- src/lib/logger/context_logger/dune | 2 +- src/lib/logger/dune | 2 +- src/lib/logger/fake/dune | 2 +- src/lib/logger/fake/logger.ml | 4 +- src/lib/logger/file_system/dune | 4 +- .../logger/file_system/logger_file_system.ml | 7 ++-- .../logger/file_system/logger_file_system.mli | 2 +- src/lib/logger/logger.mli | 4 +- src/lib/logger/native/dune | 2 +- src/lib/logger/native/logger.ml | 40 ++++++++++--------- src/lib/logger/test/dune | 3 +- src/lib/logger/test/logger_test.ml | 14 ++++--- 13 files changed, 47 insertions(+), 41 deletions(-) diff --git a/src/lib/logger/context_logger/context_logger.ml b/src/lib/logger/context_logger/context_logger.ml index 8e5c321f7447..58001e21b34a 100644 --- a/src/lib/logger/context_logger/context_logger.ml +++ b/src/lib/logger/context_logger/context_logger.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core let key = Univ_map.Key.create ~name:"logger" sexp_of_opaque diff --git a/src/lib/logger/context_logger/dune b/src/lib/logger/context_logger/dune index 17f434c6c7f1..8247e1419e2b 100644 --- a/src/lib/logger/context_logger/dune +++ b/src/lib/logger/context_logger/dune @@ -12,7 +12,7 @@ ;; local libraries logger) (preprocess - (pps ppx_jane ppx_mina ppx_version ppx_deriving_yojson)) + (pps ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (instrumentation (backend bisect_ppx)) (synopsis diff --git a/src/lib/logger/dune b/src/lib/logger/dune index 2befe937a847..be65b3ff6447 100644 --- a/src/lib/logger/dune +++ b/src/lib/logger/dune @@ -9,6 +9,6 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_version ppx_mina ppx_jane ppx_deriving_yojson ppx_deriving.std)) + (pps ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (virtual_modules logger) (default_implementation logger.native)) diff --git a/src/lib/logger/fake/dune b/src/lib/logger/fake/dune index 025cd498538b..0e5d6231fab0 100644 --- a/src/lib/logger/fake/dune +++ b/src/lib/logger/fake/dune @@ -14,6 +14,6 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_version ppx_mina ppx_jane ppx_deriving.std ppx_deriving_yojson)) + (pps ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (implements logger) (synopsis "Fake logging library")) diff --git a/src/lib/logger/fake/logger.ml b/src/lib/logger/fake/logger.ml index 959a7a6c5675..2baad9dccd80 100644 --- a/src/lib/logger/fake/logger.ml +++ b/src/lib/logger/fake/logger.ml @@ -1,6 +1,6 @@ (* logger.ml : the fake one *) -open Core_kernel +open Core let not_implemented () = failwith "Not implemented" @@ -26,7 +26,7 @@ end (* Core modules extended with Yojson converters *) module Time = struct - include Time + include Time_float let to_yojson _ = not_implemented () diff --git a/src/lib/logger/file_system/dune b/src/lib/logger/file_system/dune index 3e44dbcba78e..72d093f13a6b 100644 --- a/src/lib/logger/file_system/dune +++ b/src/lib/logger/file_system/dune @@ -4,9 +4,9 @@ (library_flags -linkall) (inline_tests (flags -verbose -show-counts)) - (libraries core yojson logger core_kernel) + (libraries core core_unix core_unix.time_float_unix yojson logger core_kernel) (preprocess - (pps ppx_version ppx_mina ppx_jane ppx_deriving.std ppx_deriving_yojson)) + (pps ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (instrumentation (backend bisect_ppx)) (synopsis "Logging library")) diff --git a/src/lib/logger/file_system/logger_file_system.ml b/src/lib/logger/file_system/logger_file_system.ml index 5b7fed7f9b23..d3f62ded8ff6 100644 --- a/src/lib/logger/file_system/logger_file_system.ml +++ b/src/lib/logger/file_system/logger_file_system.ml @@ -1,10 +1,9 @@ open Core +open Core_unix let log_perm = 0o644 module Dumb_logrotate = struct - open Core.Unix - type t = { directory : string ; log_filename : string @@ -69,7 +68,6 @@ let dumb_logrotate ~directory ~log_filename ~max_size ~num_rotate = (Dumb_logrotate.create ~directory ~log_filename ~max_size ~num_rotate) let evergrowing ~log_filename = - let open Unix in Logger.Transport.create ( module struct type t = File_descr.t @@ -83,6 +81,7 @@ let evergrowing ~log_filename = (openfile ~perm:log_perm ~mode:[ O_RDWR; O_APPEND; O_CREAT ] log_filename) let time_pretty_to_string timestamp = - Time.format timestamp "%Y-%m-%d %H:%M:%S UTC" ~zone:Time.Zone.utc + Time_float_unix.format timestamp "%Y-%m-%d %H:%M:%S UTC" + ~zone:Time_float.Zone.utc let () = Logger.Time.set_pretty_to_string time_pretty_to_string diff --git a/src/lib/logger/file_system/logger_file_system.mli b/src/lib/logger/file_system/logger_file_system.mli index 3868bffc8c93..b6496ac0adee 100644 --- a/src/lib/logger/file_system/logger_file_system.mli +++ b/src/lib/logger/file_system/logger_file_system.mli @@ -18,4 +18,4 @@ val evergrowing : log_filename:string -> Logger.Transport.t On linking this library, this is used to override the JS-safe implementation given in [Logger.Time.pretty_to_string]. *) -val time_pretty_to_string : Core.Time.t -> string +val time_pretty_to_string : Time_float_unix.t -> string diff --git a/src/lib/logger/logger.mli b/src/lib/logger/logger.mli index c2cb406e29ec..47212fc0f165 100644 --- a/src/lib/logger/logger.mli +++ b/src/lib/logger/logger.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core type t [@@deriving bin_io] @@ -20,7 +20,7 @@ module Level : sig end module Time : sig - include module type of Time + include module type of Time_float val to_yojson : t -> Yojson.Safe.t diff --git a/src/lib/logger/native/dune b/src/lib/logger/native/dune index 2b42e7574558..d46d0ebd41f1 100644 --- a/src/lib/logger/native/dune +++ b/src/lib/logger/native/dune @@ -17,7 +17,7 @@ ppx_version.runtime mina_stdlib) (preprocess - (pps ppx_version ppx_mina ppx_jane ppx_deriving.std ppx_deriving_yojson)) + (pps ppx_let ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (instrumentation (backend bisect_ppx)) (implements logger) diff --git a/src/lib/logger/native/logger.ml b/src/lib/logger/native/logger.ml index f5094ed40cec..aba283ea2097 100644 --- a/src/lib/logger/native/logger.ml +++ b/src/lib/logger/native/logger.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core let max_log_line_length = 1 lsl 20 @@ -26,12 +26,14 @@ end (* Core modules extended with Yojson converters *) module Time = struct - include Time + include Time_float - let to_yojson t = `String (Time.to_string_abs t ~zone:Zone.utc) + let to_yojson t = + `String (Time_float.to_sec_string_with_zone ~zone:Zone.utc t) let of_yojson json = - json |> Yojson.Safe.Util.to_string |> fun s -> Ok (Time.of_string s) + json |> Yojson.Safe.Util.to_string + |> fun s -> Ok (Time_float.of_string_with_utc_offset s) let pp ppf timestamp = (* This used to be @@ -41,9 +43,9 @@ module Time = struct don't want to load that just for the pretty printing. Instead, we simulate it here. *) - let zone = Time.Zone.utc in - let date, time = Time.to_date_ofday ~zone timestamp in - let time_parts = Time.Ofday.to_parts time in + let zone = Time_float.Zone.utc in + let date, time = Time_float.to_date_ofday ~zone timestamp in + let time_parts = Time_float.Ofday.to_parts time in Format.fprintf ppf "%i-%02d-%02d %02d:%02d:%02d UTC" (Date.year date) (Date.month date |> Month.to_int) (Date.day date) time_parts.hr time_parts.min time_parts.sec @@ -72,7 +74,7 @@ module Metadata = struct let to_latest = Fn.id - let to_yojson t = `Assoc (String.Map.to_alist t) + let to_yojson t = `Assoc (Map.to_alist t) let of_yojson = function | `Assoc alist -> @@ -101,13 +103,13 @@ module Metadata = struct let of_alist_exn = String.Map.of_alist_exn - let mem = String.Map.mem + let mem = Map.mem let extend (t : t) alist = List.fold_left alist ~init:t ~f:(fun acc (key, data) -> - String.Map.set acc ~key ~data ) + Map.set acc ~key ~data ) - let merge (a : t) (b : t) = extend a (String.Map.to_alist b) + let merge (a : t) (b : t) = extend a (Map.to_alist b) end let global_metadata = ref [] @@ -207,7 +209,7 @@ module Processor = struct Format.asprintf "@[%a [%a] %s@,%a@]" Time.pp msg.timestamp Level.pp msg.level str (Format.pp_print_list ~pp_sep:Format.pp_print_cut - (fun ppf (k, v) -> Format.fprintf ppf "%s: %s" k v) ) + (fun ppf (k, v) -> Format.fprintf ppf "%s: %s" k v ) ) extra in Some msg @@ -277,7 +279,7 @@ module Consumer_registry = struct type id = string let register ?commit_id ~(id : id) ~processor ~transport () = - Consumer_tbl.add_multi t ~key:id ~data:{ processor; transport; commit_id } + Hashtbl.add_multi t ~key:id ~data:{ processor; transport; commit_id } let rec broadcast_log_message ~id msg = let consumers = @@ -300,7 +302,7 @@ module Consumer_registry = struct let msg = Option.value_map ~default:msg commit_id' ~f:(fun cid -> let metadata = - String.Map.set ~key:"commit_id" ~data:(`String cid) + Map.set ~key:"commit_id" ~data:(`String cid) msg.Message.metadata in { msg with metadata } ) @@ -376,11 +378,11 @@ let make_message (t : t) ~level ~module_ ~location ~metadata ~message ~event_id ; message ; metadata = ( if skip_merge_global_metadata then - Metadata.extend Metadata.empty metadata - else - Metadata.extend - (Metadata.merge (Metadata.of_alist_exn global_metadata') t.metadata) - metadata ) + Metadata.extend Metadata.empty metadata + else + Metadata.extend + (Metadata.merge (Metadata.of_alist_exn global_metadata') t.metadata) + metadata ) ; event_id } diff --git a/src/lib/logger/test/dune b/src/lib/logger/test/dune index e3f58975508e..29dab42693d6 100644 --- a/src/lib/logger/test/dune +++ b/src/lib/logger/test/dune @@ -5,10 +5,11 @@ alcotest async core + core_unix.filename_unix ;; local libraries logger logger.file_system) (preprocess - (pps ppx_version ppx_mina ppx_jane ppx_deriving.std ppx_deriving_yojson)) + (pps ppx_compare ppx_enumerate ppx_deriving.show ppx_deriving_yojson ppx_mina ppx_sexp_conv ppx_version)) (instrumentation (backend bisect_ppx))) diff --git a/src/lib/logger/test/logger_test.ml b/src/lib/logger/test/logger_test.ml index 769ee420ebf2..dfd81405fe9c 100644 --- a/src/lib/logger/test/logger_test.ml +++ b/src/lib/logger/test/logger_test.ml @@ -1,16 +1,20 @@ open Core +open Core_unix let test_dumb_logrotate_rotates_logs_when_expected () = - let max_size = 1024 * 2 (* 2KB *) in + let max_size = + 1024 * 2 + (* 2KB *) + in let num_rotate = 1 in let logger = Logger.create () ~id:"test" in - let directory = Filename.temp_dir ~in_dir:"/tmp" "coda_spun_test" "" in + let directory = Filename_unix.temp_dir ~in_dir:"/tmp" "coda_spun_test" "" in let log_filename = "mina.log" in let exists name = - Result.is_ok (Unix.access (Filename.concat directory name) [ `Exists ]) + Result.is_ok (access (Filename.concat directory name) [ `Exists ]) in let get_size name = - Int64.to_int_exn (Unix.stat (Filename.concat directory name)).st_size + Int64.to_int_exn (stat (Filename.concat directory name)).st_size in let rec run_test ~last_size ~rotations ~rotation_expected = Logger.info logger ~module_:__MODULE__ ~location:__LOC__ "test" ; @@ -37,7 +41,7 @@ let test_dumb_logrotate_rotates_logs_when_expected () = () ; run_test ~last_size:0 ~rotations:0 ~rotation_expected:false with exn -> - ignore (Unix.system ("rm -rf " ^ directory) : Unix.Exit_or_signal.t) ; + ignore (system ("rm -rf " ^ directory) : Exit_or_signal.t) ; raise exn let () = From e862dfd5b0fcc7a04b4821fa95289f9db5512bc1 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 23:00:53 +0800 Subject: [PATCH 30/56] lib/bowe_gabizon_hash: bump to 5.2.1 --- src/lib/bowe_gabizon_hash/bowe_gabizon_hash.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/bowe_gabizon_hash/bowe_gabizon_hash.ml b/src/lib/bowe_gabizon_hash/bowe_gabizon_hash.ml index 9d9fa915ff83..62b1a07acaee 100644 --- a/src/lib/bowe_gabizon_hash/bowe_gabizon_hash.ml +++ b/src/lib/bowe_gabizon_hash/bowe_gabizon_hash.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Make (Inputs : Inputs_intf.S) = struct open Inputs From 1d95c7b32deff4f06e8e8a7ce6d04b657f603d85 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 23:02:30 +0800 Subject: [PATCH 31/56] patch lib/sparse_ledger to 5.2.1 --- src/lib/sparse_ledger_lib/sparse_ledger.ml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/lib/sparse_ledger_lib/sparse_ledger.ml b/src/lib/sparse_ledger_lib/sparse_ledger.ml index ca6c8aa77116..552cd430c879 100644 --- a/src/lib/sparse_ledger_lib/sparse_ledger.ml +++ b/src/lib/sparse_ledger_lib/sparse_ledger.ml @@ -40,7 +40,7 @@ tracking, Merkle path reconstruction, and hash correctness. *) -open Core_kernel +open Core module Tree = struct [%%versioned @@ -361,15 +361,15 @@ type ('hash, 'key, 'account) t = ('hash, 'key, 'account) T.t [@@deriving yojson] let%test_module "sparse-ledger-test" = ( module struct module Hash = struct - type t = Core_kernel.Md5.t [@@deriving sexp, compare] + type t = Md5.t [@@deriving sexp, compare] let equal h1 h2 = Int.equal (compare h1 h2) 0 - let to_yojson md5 = `String (Core_kernel.Md5.to_hex md5) + let to_yojson md5 = `String (Md5.to_hex md5) let of_yojson = function | `String x -> - Or_error.try_with (fun () -> Core_kernel.Md5.of_hex_exn x) + Or_error.try_with (fun () -> Md5.of_hex_exn x) |> Result.map_error ~f:Error.to_string_hum | _ -> Error "Expected a hex-encoded MD5 hash" @@ -461,7 +461,7 @@ let%test_module "sparse-ledger-test" = ~message: "Iteri index should be contained in the indexes auxillary \ structure" - ~expect:true (Int.Set.mem indexes i) ) ) + ~expect:true (Set.mem indexes i) ) ) let%test_unit "path_test" = Quickcheck.test gen ~f:(fun t -> From 349e5435e81505138a0b6ecbbcdf125b205e9f5a Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 19:07:34 +0800 Subject: [PATCH 32/56] patch snarky for ocaml 5.2.1 --- src/lib/snarky | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/snarky b/src/lib/snarky index d97a38c44828..1070ceec6043 160000 --- a/src/lib/snarky +++ b/src/lib/snarky @@ -1 +1 @@ -Subproject commit d97a38c448285294ed3631412b7f01f39a043d1e +Subproject commit 1070ceec60430376b4a920f59b7afe600e9df33f From 2b5c6ee10e27a352fd8bdace085371e330eb9aff Mon Sep 17 00:00:00 2001 From: glyh Date: Sun, 30 Nov 2025 23:35:57 +0800 Subject: [PATCH 33/56] port mina_debug to 5.2.1 --- src/lib/mina_debug/call_logger.ml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/lib/mina_debug/call_logger.ml b/src/lib/mina_debug/call_logger.ml index d86ea4f15cb6..6f1ebb1cc8b0 100644 --- a/src/lib/mina_debug/call_logger.ml +++ b/src/lib/mina_debug/call_logger.ml @@ -1,6 +1,6 @@ -open Core_kernel +open Core -let genesis = Time.now () +let genesis = Time_float.now () module Call_ring = struct type t = string * int ref * int array @@ -14,10 +14,10 @@ module Call_ring = struct (String.concat ~sep:"," (Array.to_list (Array.map cs ~f:string_of_int))) let record ((name, epoch, cs) : t) = - let now = Time.now () in - let span_since_genesis = Time.diff now genesis in + let now = Time_float.now () in + let span_since_genesis = Time_float.diff now genesis in let mins_since_genesis = - int_of_float (Time.Span.to_min span_since_genesis) + int_of_float (Time_float.Span.to_min span_since_genesis) in let curr_epoch = mins_since_genesis / window in let curr_index = mins_since_genesis mod window in From a88dbaa4e65791867493268557e8c861e02a9af6 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:24:34 +0800 Subject: [PATCH 34/56] port o1trace to 5.2.1 --- src/lib/o1trace/dune | 2 +- src/lib/o1trace/execution_timer.ml | 4 +-- src/lib/o1trace/execution_timer.mli | 4 +-- src/lib/o1trace/{thread.ml => o1thread.ml} | 10 +++---- src/lib/o1trace/o1trace.ml | 28 +++++++++---------- src/lib/o1trace/o1trace.mli | 10 +++---- src/lib/o1trace/plugins.ml | 12 ++++---- src/lib/o1trace/webkit_event/dune | 2 +- .../webkit_event/o1trace_webkit_event.ml | 8 +++--- 9 files changed, 39 insertions(+), 41 deletions(-) rename src/lib/o1trace/{thread.ml => o1thread.ml} (90%) diff --git a/src/lib/o1trace/dune b/src/lib/o1trace/dune index 9adf734b979b..7e56c6d1d322 100644 --- a/src/lib/o1trace/dune +++ b/src/lib/o1trace/dune @@ -19,4 +19,4 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_version ppx_jane ppx_mina))) + (pps ppx_version ppx_jane))) diff --git a/src/lib/o1trace/execution_timer.ml b/src/lib/o1trace/execution_timer.ml index edcf0f2d5549..8ad72b272c79 100644 --- a/src/lib/o1trace/execution_timer.ml +++ b/src/lib/o1trace/execution_timer.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module T = Plugins.Register_plugin @@ -13,7 +13,7 @@ module T = include T -let rec record_elapsed_time (fiber : Thread.Fiber.t) elapsed_time = +let rec record_elapsed_time (fiber : O1thread.Fiber.t) elapsed_time = let state = Plugins.plugin_state (module T) fiber.thread in (state := Time_ns.Span.(!state + elapsed_time)) ; match fiber.parent with diff --git a/src/lib/o1trace/execution_timer.mli b/src/lib/o1trace/execution_timer.mli index bc0022f5ad48..b2214fe79d45 100644 --- a/src/lib/o1trace/execution_timer.mli +++ b/src/lib/o1trace/execution_timer.mli @@ -1,5 +1,5 @@ -open Core_kernel +open Core include Plugins.Plugin_intf -val elapsed_time_of_thread : Thread.t -> Time_ns.Span.t +val elapsed_time_of_thread : O1thread.t -> Time_ns.Span.t diff --git a/src/lib/o1trace/thread.ml b/src/lib/o1trace/o1thread.ml similarity index 90% rename from src/lib/o1trace/thread.ml rename to src/lib/o1trace/o1thread.ml index f830b4bbbbff..0099f4e39f1c 100644 --- a/src/lib/o1trace/thread.ml +++ b/src/lib/o1trace/o1thread.ml @@ -52,8 +52,8 @@ let name { name; _ } = name let load_state thread id = Univ_map.find thread.state id -let set_state thread id value = - thread.state <- Univ_map.set thread.state id value +let set_state thread key data = + thread.state <- Univ_map.set ~key ~data thread.state let iter_threads ~f = Hashtbl.iter threads ~f @@ -79,7 +79,7 @@ module Fiber = struct let rec fiber_key name parent = name :: Option.value_map parent ~default:[] ~f:(fun p -> - fiber_key p.thread.name p.parent ) + fiber_key p.thread.name p.parent ) let register name parent = let key = fiber_key name parent in @@ -94,9 +94,7 @@ module Fiber = struct Option.iter parent ~f:(fun p -> Graph.add_edge graph p.thread.name name) ; fiber - let apply_to_context t ctx = - let ctx = Execution_context.with_tid ctx t.id in - Execution_context.with_local ctx ctx_id (Some t) + let apply_to_context t ctx = Execution_context.with_local ctx ctx_id (Some t) let of_context ctx = Execution_context.find_local ctx ctx_id diff --git a/src/lib/o1trace/o1trace.ml b/src/lib/o1trace/o1trace.ml index ab05b36d0ce8..400528a969c9 100644 --- a/src/lib/o1trace/o1trace.ml +++ b/src/lib/o1trace/o1trace.ml @@ -1,13 +1,13 @@ -open Core_kernel +open Core open Async module Execution_timer = Execution_timer module Plugins = Plugins -module Thread = Thread +module O1thread = O1thread (* TODO: this should probably go somewhere else (mina_cli_entrypoint or coda_run) *) let () = Plugins.enable_plugin (module Execution_timer) -let on_job_enter' (fiber : Thread.Fiber.t) = +let on_job_enter' (fiber : O1thread.Fiber.t) = Plugins.dispatch (fun (module Plugin : Plugins.Plugin_intf) -> Plugin.on_job_enter fiber ) @@ -16,13 +16,13 @@ let on_job_exit' fiber elapsed_time = Plugin.on_job_exit fiber elapsed_time ) let on_job_enter ctx = - Option.iter (Thread.Fiber.of_context ctx) ~f:on_job_enter' + Option.iter (O1thread.Fiber.of_context ctx) ~f:on_job_enter' let on_job_exit ctx elapsed_time = - Option.iter (Thread.Fiber.of_context ctx) ~f:(fun thread -> + Option.iter (O1thread.Fiber.of_context ctx) ~f:(fun thread -> on_job_exit' thread elapsed_time ) -let on_new_fiber (fiber : Thread.Fiber.t) = +let on_new_fiber (fiber : O1thread.Fiber.t) = Plugins.dispatch (fun (module Plugin : Plugins.Plugin_intf) -> Plugin.on_new_fiber fiber ) @@ -33,14 +33,14 @@ let grab_parent_fiber () = let ctx = Scheduler.current_execution_context () in match !current_sync_fiber with | None -> - Execution_context.find_local ctx Thread.Fiber.ctx_id + Execution_context.find_local ctx O1thread.Fiber.ctx_id | Some fiber -> current_sync_fiber := None ; Some fiber (* look through a fiber stack to find a recursive fiber call *) let rec find_recursive_fiber thread_name parent_thread_name - (fiber : Thread.Fiber.t) = + (fiber : O1thread.Fiber.t) = let thread_matches = String.equal fiber.thread.name thread_name in let parent_thread_matches = Option.equal String.equal @@ -76,7 +76,7 @@ let exec_thread ~exec_same_thread ~exec_new_thread name = | Some fiber -> fiber | None -> - let fib = Thread.Fiber.register name parent in + let fib = O1thread.Fiber.register name parent in on_new_fiber fib ; fib in exec_new_thread fiber @@ -87,7 +87,7 @@ let exec_thread ~exec_same_thread ~exec_new_thread name = let thread name f = exec_thread name ~exec_same_thread:f ~exec_new_thread:(fun fiber -> let ctx = Scheduler.current_execution_context () in - let ctx = Thread.Fiber.apply_to_context fiber ctx in + let ctx = O1thread.Fiber.apply_to_context fiber ctx in let ctx = with_o1trace ~name ctx in match Scheduler.within_context ctx f with | Error () -> @@ -118,7 +118,7 @@ let sync_thread name f = result ) let () = - Stdlib.(Async_kernel.Tracing.fns := { on_job_enter; on_job_exit }) ; + Async_kernel.Tracing.set_tracers ~on_job_enter ~on_job_exit ; Scheduler.Expert.run_every_cycle_end (fun () -> Plugins.dispatch (fun (module Plugin : Plugins.Plugin_intf) -> Plugin.on_cycle_end () ) ) @@ -126,7 +126,7 @@ let () = (* let () = Scheduler.Expert.set_on_end_of_cycle (fun () -> - Option.iter (Thread.current_thread ()) ~f:(fun thread -> + Option.iter (O1thread.current_thread ()) ~f:(fun thread -> dispatch_plugins thread (fun (module Plugin) state -> Plugin.on_cycle_end thread.name state)) ; (* this line should probably live inside Async_kernel *) sch.cycle_started <- true) @@ -147,10 +147,10 @@ let%test_module "thread tests" = false let test' f = - Hashtbl.clear Thread.threads ; + Hashtbl.clear O1thread.threads ; Thread_safe.block_on_async_exn (fun () -> let s = Ivar.create () in - f (Ivar.fill s) ; + f (Ivar.fill_exn s) ; let%bind () = Ivar.read s in Writer.(flushed (Lazy.force stdout)) ) diff --git a/src/lib/o1trace/o1trace.mli b/src/lib/o1trace/o1trace.mli index 9cb2cb59c71e..5438c15dcf11 100644 --- a/src/lib/o1trace/o1trace.mli +++ b/src/lib/o1trace/o1trace.mli @@ -1,8 +1,8 @@ -open Core_kernel +open Core open Async -module Thread : sig - type t = Thread.t +module O1thread : sig + type t = O1thread.t val name : t -> string @@ -15,8 +15,8 @@ module Thread : sig val dump_thread_graph : unit -> bytes module Fiber : sig - type t = Thread.Fiber.t = - { id : int; parent : t option; thread : Thread.t; key : string list } + type t = O1thread.Fiber.t = + { id : int; parent : t option; thread : O1thread.t; key : string list } val key : t -> string list end diff --git a/src/lib/o1trace/plugins.ml b/src/lib/o1trace/plugins.ml index f9f4e24650d7..7ccd832d2b53 100644 --- a/src/lib/o1trace/plugins.ml +++ b/src/lib/o1trace/plugins.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* TODO: ensure plugin names are unique (use encapsulated type as proof of functor application) *) @@ -26,11 +26,11 @@ end module type Plugin_intf = sig include Registered_plugin_spec_intf - val on_job_enter : Thread.Fiber.t -> unit + val on_job_enter : O1thread.Fiber.t -> unit - val on_job_exit : Thread.Fiber.t -> Time_ns.Span.t -> unit + val on_job_exit : O1thread.Fiber.t -> Time_ns.Span.t -> unit - val on_new_fiber : Thread.Fiber.t -> unit + val on_new_fiber : O1thread.Fiber.t -> unit val on_cycle_end : unit -> unit end @@ -53,12 +53,12 @@ let plugins : (module Plugin_intf) String.Table.t = String.Table.create () let plugin_state (type a) (module Plugin : Registered_plugin_spec_intf with type state = a) thread = - match Thread.load_state thread Plugin.state_id with + match O1thread.load_state thread Plugin.state_id with | Some state -> state | None -> let state = Plugin.init_state thread.name in - Thread.set_state thread Plugin.state_id state ; + O1thread.set_state thread Plugin.state_id state ; state let enable_plugin (module Plugin : Plugin_intf) = diff --git a/src/lib/o1trace/webkit_event/dune b/src/lib/o1trace/webkit_event/dune index e0ba735a2167..e15b879623a2 100644 --- a/src/lib/o1trace/webkit_event/dune +++ b/src/lib/o1trace/webkit_event/dune @@ -16,4 +16,4 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_version ppx_jane))) + (pps ppx_sexp_conv ppx_version))) diff --git a/src/lib/o1trace/webkit_event/o1trace_webkit_event.ml b/src/lib/o1trace/webkit_event/o1trace_webkit_event.ml index 63f653881162..0454a68903eb 100644 --- a/src/lib/o1trace/webkit_event/o1trace_webkit_event.ml +++ b/src/lib/o1trace/webkit_event/o1trace_webkit_event.ml @@ -49,15 +49,15 @@ module T = struct let most_recent_id = ref 0 - let on_job_enter (fiber : O1trace.Thread.Fiber.t) = + let on_job_enter (fiber : O1trace.O1thread.Fiber.t) = if fiber.id <> !most_recent_id then ( most_recent_id := fiber.id ; emit_event (new_thread_event fiber.id Thread_switch) ) let on_job_exit _fiber _time_elapsed = () - let on_new_fiber (fiber : O1trace.Thread.Fiber.t) = - let fullname = String.concat ~sep:"/" (O1trace.Thread.Fiber.key fiber) in + let on_new_fiber (fiber : O1trace.O1thread.Fiber.t) = + let fullname = String.concat ~sep:"/" (O1trace.O1thread.Fiber.key fiber) in emit_event (new_thread_event ~include_name:fullname fiber.id New_thread) let on_cycle_end () = @@ -71,7 +71,7 @@ let start_tracing wr = else ( current_wr := Some wr ; emit_event (new_event Pid_is) ; - O1trace.Thread.iter_fibers ~f:T.on_new_fiber ; + O1trace.O1thread.iter_fibers ~f:T.on_new_fiber ; O1trace.Plugins.enable_plugin (module T) ) let stop_tracing () = From abc295055dd6f0e96fae890076faf95ba45ca20a Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:39:42 +0800 Subject: [PATCH 35/56] mina metrics: port to 5.2.1 --- src/lib/mina_metrics/mina_metrics.mli | 38 +++++++-------- .../mina_metrics/no_metrics/mina_metrics.ml | 32 +++++-------- .../prometheus_metrics/metric_generators.ml | 23 ++++----- .../prometheus_metrics/mina_metrics.ml | 47 +++++++++---------- 4 files changed, 67 insertions(+), 73 deletions(-) diff --git a/src/lib/mina_metrics/mina_metrics.mli b/src/lib/mina_metrics/mina_metrics.mli index a69f1a68989a..80deef9602ee 100644 --- a/src/lib/mina_metrics/mina_metrics.mli +++ b/src/lib/mina_metrics/mina_metrics.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel val time_offset_sec : float @@ -173,15 +173,15 @@ module Network : sig val received : Counter.t module Validation_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Processing_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Rejection_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end end @@ -195,15 +195,15 @@ module Network : sig val received : Counter.t module Validation_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Processing_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Rejection_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end end @@ -217,15 +217,15 @@ module Network : sig val received : Counter.t module Validation_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Processing_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end module Rejection_time : sig - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit end end @@ -478,7 +478,7 @@ module Transition_frontier : sig val clear : unit -> unit - val initialize : Core_kernel.Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end val recently_finalized_staged_txns : Gauge.t @@ -542,37 +542,37 @@ module Block_latency : sig val clear : unit -> unit - val initialize : Core_kernel.Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end module Gossip_time : sig val v : Gauge.t - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit val clear : unit -> unit - val initialize : Core_kernel.Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end module Inclusion_time : sig val v : Gauge.t - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit val clear : unit -> unit - val initialize : Core_kernel.Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end module Validation_acceptance_time : sig val v : Gauge.t - val update : Time.Span.t -> unit + val update : Time_float.Span.t -> unit val clear : unit -> unit - val initialize : Core_kernel.Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end end @@ -617,4 +617,4 @@ module Archive : sig ?forward_uri:Uri.t -> port:int -> logger:Logger.t -> unit -> t Deferred.t end -val initialize_all : Time.Span.t -> unit +val initialize_all : Time_float.Span.t -> unit diff --git a/src/lib/mina_metrics/no_metrics/mina_metrics.ml b/src/lib/mina_metrics/no_metrics/mina_metrics.ml index d5235e348632..9ace4b248518 100644 --- a/src/lib/mina_metrics/no_metrics/mina_metrics.ml +++ b/src/lib/mina_metrics/no_metrics/mina_metrics.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel let time_offset_sec = 1609459200. @@ -75,17 +75,11 @@ module Process_memory = struct end module Daemon = Make_rss_gauge () - module Prover = Make_rss_gauge () - module Verifier = Make_rss_gauge () - module Snark_worker = Make_rss_gauge () - module Uptime_snark_worker = Make_rss_gauge () - module Vrf_evaluator = Make_rss_gauge () - module Libp2p_helper = Make_rss_gauge () end @@ -162,15 +156,15 @@ module Network = struct let received : Counter.t = () module Validation_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Processing_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Rejection_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end end @@ -184,15 +178,15 @@ module Network = struct let received : Counter.t = () module Validation_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Processing_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Rejection_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end end @@ -206,15 +200,15 @@ module Network = struct let received : Counter.t = () module Validation_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Processing_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end module Rejection_time = struct - let update : Time.Span.t -> unit = Fn.ignore + let update : Time_float.Span.t -> unit = Fn.ignore end end @@ -539,7 +533,7 @@ module Block_latency = struct module Gossip_time = struct let v : Gauge.t = () - let update : Time.Span.t -> unit = fun _ -> () + let update : Time_float.Span.t -> unit = fun _ -> () let clear : unit -> unit = fun _ -> () @@ -549,7 +543,7 @@ module Block_latency = struct module Inclusion_time = struct let v : Gauge.t = () - let update : Time.Span.t -> unit = fun _ -> () + let update : Time_float.Span.t -> unit = fun _ -> () let clear : unit -> unit = fun _ -> () @@ -559,7 +553,7 @@ module Block_latency = struct module Validation_acceptance_time = struct let v : Gauge.t = () - let update : Time.Span.t -> unit = fun _ -> () + let update : Time_float.Span.t -> unit = fun _ -> () let clear : unit -> unit = fun _ -> () diff --git a/src/lib/mina_metrics/prometheus_metrics/metric_generators.ml b/src/lib/mina_metrics/prometheus_metrics/metric_generators.ml index 60b91c5b4fa5..e23d30c27cca 100644 --- a/src/lib/mina_metrics/prometheus_metrics/metric_generators.ml +++ b/src/lib/mina_metrics/prometheus_metrics/metric_generators.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel open Prometheus @@ -13,18 +13,18 @@ end module type Bucketed_average_spec_intf = sig include Metric_spec_intf - val bucket_interval : Time.Span.t -> Time.Span.t + val bucket_interval : Time_float.Span.t -> Time_float.Span.t - val num_buckets : Time.Span.t -> int + val num_buckets : Time_float.Span.t -> int val render_average : (float * int) list -> float end module Intervals = struct - type t = { rolling : Time.Span.t; tick : Time.Span.t } + type t = { rolling : Time_float.Span.t; tick : Time_float.Span.t } let make ~rolling_interval ~tick_interval = - let open Time.Span in + let open Time_float.Span in let ( = ) = Float.equal in let ( mod ) = Float.mod_float in if not (to_ns rolling_interval mod to_ns tick_interval = 0.0) then @@ -37,7 +37,7 @@ end module type Time_average_spec_intf = sig include Metric_spec_intf - val intervals : Time.Span.t -> Intervals.t + val intervals : Time_float.Span.t -> Intervals.t end module type Moving_average_metric_intf = sig @@ -49,7 +49,7 @@ module type Moving_average_metric_intf = sig val v : Gauge.t - val initialize : Time.Span.t -> unit + val initialize : Time_float.Span.t -> unit end module Moving_bucketed_average (Spec : Bucketed_average_spec_intf) : @@ -79,7 +79,7 @@ module Moving_bucketed_average (Spec : Bucketed_average_spec_intf) : let rec tick () = upon (after - ( Time_ns.Span.of_ns @@ Time.Span.to_ns + ( Time_ns.Span.of_ns @@ Time_float.Span.to_ns @@ bucket_interval block_window_duration ) ) (fun () -> let num_buckets = num_buckets block_window_duration in @@ -96,7 +96,7 @@ module Moving_bucketed_average (Spec : Bucketed_average_spec_intf) : end module Moving_time_average (Spec : Time_average_spec_intf) : - Moving_average_metric_intf with type datum := Time.Span.t = struct + Moving_average_metric_intf with type datum := Time_float.Span.t = struct include Moving_bucketed_average (struct include Spec @@ -106,7 +106,8 @@ module Moving_time_average (Spec : Time_average_spec_intf) : let num_buckets block_window_duration = let intervals = Spec.intervals block_window_duration in Float.to_int - (Time.Span.to_ns intervals.rolling /. Time.Span.to_ns intervals.tick) + ( Time_float.Span.to_ns intervals.rolling + /. Time_float.Span.to_ns intervals.tick ) let render_average buckets = let total_sum, count_sum = @@ -117,5 +118,5 @@ module Moving_time_average (Spec : Time_average_spec_intf) : total_sum /. Float.of_int count_sum end) - let update span = update (Time.Span.to_sec span) + let update span = update (Time_float.Span.to_sec span) end diff --git a/src/lib/mina_metrics/prometheus_metrics/mina_metrics.ml b/src/lib/mina_metrics/prometheus_metrics/mina_metrics.ml index 6c41bbb9f676..a30d1f0a7f37 100644 --- a/src/lib/mina_metrics/prometheus_metrics/mina_metrics.ml +++ b/src/lib/mina_metrics/prometheus_metrics/mina_metrics.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* We re-export a constrained subset of prometheus to keep consumers of this module abstract over implementation. @@ -77,7 +77,7 @@ module TextFormat_0_0_4 = struct | None -> (label_names, label_values) | Some (label_name, label_value) -> - let label_value_str = Fmt.strf "%a" output_value label_value in + let label_value_str = Fmt.str "%a" output_value label_value in (label_name :: label_names, label_value_str :: label_values) in Fmt.pf f "%a%s%a %a@." MetricName.pp base ext @@ -123,7 +123,7 @@ module Runtime = struct let help = "A histogram for long async jobs" in Long_job_histogram.v "long_async_job" ~help ~namespace ~subsystem - let start_time = Core.Time.now () + let start_time = Time_float.now () let current_gc = ref (Gc.stat ()) @@ -216,12 +216,15 @@ module Runtime = struct ~help:"Current stack size." let process_cpu_seconds_total = - simple_metric ~metric_type:Counter "process_cpu_seconds_total" Sys.time + simple_metric ~metric_type:Counter "process_cpu_seconds_total" + (fun () -> + let t = Core_unix.times () in + t.tms_utime +. t.tms_stime ) ~help:"Total user and system CPU time spent in seconds." let process_uptime_ms_total = simple_metric ~metric_type:Counter "process_uptime_ms_total" - (fun () -> Time.Span.to_ms (Core.Time.diff (Core.Time.now ()) start_time)) + (fun () -> Time_float.(Span.to_ms (diff (now ()) start_time))) ~help:"Total time the process has been running for in milliseconds." let metrics = @@ -513,11 +516,8 @@ struct include Metric_name_map let add t ~name ~help : Metric.t = - if Metric_name_map.mem t name then Metric_name_map.find_exn t name - else - let metric = Metric.v ~help ~namespace ~subsystem:Metric.subsystem name in - Metric_name_map.add_exn t ~key:name ~data:metric ; - metric + Hashtbl.find_or_add t name ~default:(fun () -> + Metric.v ~help ~namespace ~subsystem:Metric.subsystem name ) end module Network = struct @@ -1396,13 +1396,13 @@ module Transition_frontier = struct end) module TPS_30min = Moving_bucketed_average (struct - let bucket_interval _ = Time.Span.of_min 3.0 + let bucket_interval _ = Time_float.Span.of_min 3.0 let num_buckets _ = 10 let render_average buckets = let total = List.fold buckets ~init:0.0 ~f:(fun acc (n, _) -> acc +. n) in - total /. Time.Span.(of_min 30.0 |> to_sec) + total /. Time_float.Span.(of_min 30.0 |> to_sec) let subsystem = subsystem @@ -1560,8 +1560,8 @@ module Block_latency = struct module Latency_time_spec = struct let intervals block_window_duration = Intervals.make - ~tick_interval:(Time.Span.scale block_window_duration 0.5) - ~rolling_interval:(Time.Span.scale block_window_duration 20.0) + ~tick_interval:(Time_float.Span.scale block_window_duration 0.5) + ~rolling_interval:(Time_float.Span.scale block_window_duration 20.0) end module Gauge_map = Metric_map (struct @@ -1574,7 +1574,7 @@ module Block_latency = struct module Gossip_slots = Moving_bucketed_average (struct let bucket_interval block_window_duration = - Time.Span.scale block_window_duration 0.5 + Time_float.Span.scale block_window_duration 0.5 let num_buckets _ = 40 @@ -1732,7 +1732,7 @@ module Execution_times = struct let tracked_metrics = String.Table.create () let create_metric thread = - let name = O1trace.Thread.name thread in + let name = O1trace.O1thread.name thread in let info : MetricInfo.t = { name = MetricName.v @@ -1750,8 +1750,8 @@ module Execution_times = struct CollectorRegistry.register CollectorRegistry.default info collect let sync_metrics () = - O1trace.Thread.iter_threads ~f:(fun thread -> - let name = O1trace.Thread.name thread in + O1trace.O1thread.iter_threads ~f:(fun thread -> + let name = O1trace.O1thread.name thread in if not (Hashtbl.mem tracked_metrics name) then Hashtbl.add_exn tracked_metrics ~key:name ~data:(create_metric thread) ) @@ -1760,7 +1760,6 @@ end let generic_server ?forward_uri ~port ~logger ~registry () = let open Cohttp in - let open Cohttp_async in let handle_error _ exn = [%log error] ~metadata:[ ("error", `String (Exn.to_string exn)) ] @@ -1774,10 +1773,10 @@ let generic_server ?forward_uri ~port ~logger ~registry () = match forward_uri with | Some uri -> ( Monitor.try_with ~here:[%here] (fun () -> - let%bind resp, body = Client.get uri in + let%bind resp, body = Cohttp_async.Client.get uri in let status = Response.status resp in if Code.is_success (Code.code_of_status status) then - let%map body = Body.to_string body in + let%map body = Cohttp_async.Body.to_string body in Some body else ( [%log error] @@ -1814,11 +1813,11 @@ let generic_server ?forward_uri ~port ~logger ~registry () = let headers = Header.init_with "Content-Type" "text/plain; version=0.0.4" in - Server.respond_string ~status:`OK ~headers body + Cohttp_async.Server.respond_string ~status:`OK ~headers body | _ -> - Server.respond_string ~status:`Bad_request "Bad request" + Cohttp_async.Server.respond_string ~status:`Bad_request "Bad request" in - Server.create ~mode:`TCP ~on_handler_error:(`Call handle_error) + Cohttp_async.Server.create ~mode:`TCP ~on_handler_error:(`Call handle_error) (Async.Tcp.Where_to_listen.of_port port) callback From 091df23b1caf4799acceb05ad3d49a26031353b8 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:40:36 +0800 Subject: [PATCH 36/56] port merkle_list_prover to 5.2.1 --- src/lib/merkle_list_prover/merkle_list_prover.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/merkle_list_prover/merkle_list_prover.ml b/src/lib/merkle_list_prover/merkle_list_prover.ml index 8c0a35e131af..7faad7221269 100644 --- a/src/lib/merkle_list_prover/merkle_list_prover.ml +++ b/src/lib/merkle_list_prover/merkle_list_prover.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module type Inputs_intf = sig type value From bb3b875b875f6b4fd421626252bf4851dd0d9281 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:40:44 +0800 Subject: [PATCH 37/56] port random_oracle_input to 5.2.1 --- .../random_oracle_input.ml | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/lib/random_oracle_input/random_oracle_input.ml b/src/lib/random_oracle_input/random_oracle_input.ml index c517caa62cb6..8da68f34a3d7 100644 --- a/src/lib/random_oracle_input/random_oracle_input.ml +++ b/src/lib/random_oracle_input/random_oracle_input.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Chunked = struct (** The input for a random oracle, formed of full field elements and 'chunks' @@ -194,7 +194,7 @@ module Legacy = struct let run p cs = p cs |> M.bind ~f:(fun (a, cs') -> - match cs' with [] -> M.return a | _ -> M.fail `Expected_eof ) + match cs' with [] -> M.return a | _ -> M.fail `Expected_eof ) let fail why _ = M.fail why @@ -315,16 +315,16 @@ module Legacy = struct let string_of_field xs = List.chunks_of xs ~length:8 |> List.map ~f:(fun xs -> - let rec go i acc = function - | [] -> - acc - | b :: bs -> - go (i + 1) ((acc * 2) + if b then 1 else 0) bs - in - let pad = List.init (8 - List.length xs) ~f:(Fn.const false) in - let combined = xs @ pad in - assert (List.length combined = 8) ; - go 0 0 combined ) + let rec go i acc = function + | [] -> + acc + | b :: bs -> + go (i + 1) ((acc * 2) + if b then 1 else 0) bs + in + let pad = List.init (8 - List.length xs) ~f:(Fn.const false) in + let combined = xs @ pad in + assert (List.length combined = 8) ; + go 0 0 combined ) |> List.map ~f:Char.of_int_exn |> String.of_char_list @@ -401,7 +401,7 @@ module Legacy = struct let field = gen_field ~size_in_bits in Quickcheck.test ~trials:300 Quickcheck.Generator.( - tuple2 (gen_input ~size_in_bits ()) (tuple2 field field)) + tuple2 (gen_input ~size_in_bits ()) (tuple2 field field) ) ~f:(fun ((_, input), (x, y)) -> let middle = [| x; y |] in let expected = @@ -431,14 +431,14 @@ module Legacy = struct ~f:(fun (_, input) -> let serialized = Coding.( - serialize ~string_of_field ~to_bool:Fn.id ~of_bool:Fn.id input) + serialize ~string_of_field ~to_bool:Fn.id ~of_bool:Fn.id input ) in let deserialized = Coding.( deserialize (String.to_list serialized) ~field_of_string:(field_of_string ~size_in_bits) - ~of_bool:Fn.id) + ~of_bool:Fn.id ) in let normalized t = { t with From e0dfad20c40795ea04f1dd3a98ceb9ae03d3792d Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:42:16 +0800 Subject: [PATCH 38/56] port key_cache to 5.2.1 --- src/lib/key_cache/async/key_cache_async.ml | 2 +- src/lib/key_cache/key_cache.ml | 2 +- src/lib/key_cache/key_cache.mli | 2 +- src/lib/key_cache/sync/key_cache_sync.ml | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/lib/key_cache/async/key_cache_async.ml b/src/lib/key_cache/async/key_cache_async.ml index 1d913e735dd3..a2fb842f6126 100644 --- a/src/lib/key_cache/async/key_cache_async.ml +++ b/src/lib/key_cache/async/key_cache_async.ml @@ -56,7 +56,7 @@ let read spec { Disk_storable.to_string; read = r; write = w } k = let write spec { Disk_storable.to_string; read = r; write = w } k v = let%map errs = - Deferred.List.filter_map spec ~f:(fun s -> + Deferred.List.filter_map spec ~how:`Sequential ~f:(fun s -> let res = match s with | Spec.On_disk { directory; should_write } -> diff --git a/src/lib/key_cache/key_cache.ml b/src/lib/key_cache/key_cache.ml index 1491cd665db1..4acd2bf6ba4a 100644 --- a/src/lib/key_cache/key_cache.ml +++ b/src/lib/key_cache/key_cache.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module Spec = struct diff --git a/src/lib/key_cache/key_cache.mli b/src/lib/key_cache/key_cache.mli index 48e75f2e0e6b..8650e0c2ddb3 100644 --- a/src/lib/key_cache/key_cache.mli +++ b/src/lib/key_cache/key_cache.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module Spec : sig diff --git a/src/lib/key_cache/sync/key_cache_sync.ml b/src/lib/key_cache/sync/key_cache_sync.ml index 97139277d8f0..1c6390f2f322 100644 --- a/src/lib/key_cache/sync/key_cache_sync.ml +++ b/src/lib/key_cache/sync/key_cache_sync.ml @@ -6,14 +6,14 @@ let on_disk to_string read write prefix = let path k = prefix ^/ to_string k in let read k = let p = path k in - match Sys.file_exists p with + match Sys_unix.file_exists p with | `No | `Unknown -> Or_error.errorf "file %s does not exist or cannot be read" p | `Yes -> read k ~path:p in let write key v = - match Sys.is_directory prefix with + match Sys_unix.is_directory prefix with | `No | `Unknown -> Or_error.errorf "directory %s does not exist or cannot be read" prefix | `Yes -> @@ -63,7 +63,7 @@ let write spec { Disk_storable.to_string; read = r; write = w } k v = match s with | Spec.On_disk { directory; should_write } -> if should_write then ( - Unix.mkdir_p directory ; + Core_unix.mkdir_p directory ; (on_disk to_string r w directory).write k v ) else Or_error.return () | S3 { bucket_prefix = _; install_path = _ } -> From 87f305b8f4931adf1068ca1f64db7ff44c22e26c Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:42:45 +0800 Subject: [PATCH 39/56] participating_state: port to 5.2.1 --- src/lib/participating_state/participating_state.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/participating_state/participating_state.ml b/src/lib/participating_state/participating_state.ml index b51935b8d969..55a668a06f80 100644 --- a/src/lib/participating_state/participating_state.ml +++ b/src/lib/participating_state/participating_state.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module T = struct From f22e4f5cae104a60d4eb578658e7e2e6c33565b4 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:43:10 +0800 Subject: [PATCH 40/56] bignum bigint: Port to 5.2.1 --- src/lib/bignum_bigint/bignum_bigint.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/bignum_bigint/bignum_bigint.ml b/src/lib/bignum_bigint/bignum_bigint.ml index d5c07844865b..aad684cb9b05 100644 --- a/src/lib/bignum_bigint/bignum_bigint.ml +++ b/src/lib/bignum_bigint/bignum_bigint.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core include Bigint let of_bool (b : bool) : t = if b then one else zero From a7d437ad1339ece4e3b2e4ed2379f0cce58adc30 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:45:11 +0800 Subject: [PATCH 41/56] key_value_database: port to 5.2.1 --- .../key_value_database/key_value_database.ml | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/src/lib/key_value_database/key_value_database.ml b/src/lib/key_value_database/key_value_database.ml index 2abb29381e3d..db2b3ba37d45 100644 --- a/src/lib/key_value_database/key_value_database.ml +++ b/src/lib/key_value_database/key_value_database.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Monad = struct module type S = sig @@ -77,7 +77,8 @@ module Intf = struct end module Make_mock - (Key : Hashable.S) (Value : sig + (Key : Hashable.S) + (Value : sig type t end) : Intf.Mock @@ -88,30 +89,30 @@ module Make_mock type t = Value.t Key.Table.t let to_sexp t ~key_sexp ~value_sexp = - Key.Table.to_alist t + Hashtbl.to_alist t |> List.map ~f:(fun (key, value) -> - [%sexp_of: Sexp.t * Sexp.t] (key_sexp key, value_sexp value) ) + [%sexp_of: Sexp.t * Sexp.t] (key_sexp key, value_sexp value) ) |> [%sexp_of: Sexp.t list] let create _ = Key.Table.create () - let get t ~key = Key.Table.find t key + let get t ~key = Hashtbl.find t key - let get_batch t ~keys = List.map keys ~f:(Key.Table.find t) + let get_batch t ~keys = List.map keys ~f:(Hashtbl.find t) - let set = Key.Table.set + let set = Hashtbl.set - let remove t ~key = Key.Table.remove t key + let remove t ~key = Hashtbl.remove t key let close _ = () let random_key t = - let keys = Key.Table.keys t in + let keys = Hashtbl.keys t in List.random_element keys let set_batch t ?(remove_keys = []) ~update_pairs = List.iter update_pairs ~f:(fun (key, data) -> set t ~key ~data) ; List.iter remove_keys ~f:(fun key -> remove t ~key) - let to_alist = Key.Table.to_alist + let to_alist = Hashtbl.to_alist end From f3d796c35eeb95d41540b69c9bf0b46bd1f3ecf7 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:45:35 +0800 Subject: [PATCH 42/56] hex: port to 5.2.1 --- src/lib/hex/hex.ml | 47 ++++++++++++++++++++++++---------------------- 1 file changed, 25 insertions(+), 22 deletions(-) diff --git a/src/lib/hex/hex.ml b/src/lib/hex/hex.ml index 71d64330ac66..c52a7a0b8728 100644 --- a/src/lib/hex/hex.ml +++ b/src/lib/hex/hex.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Digit = struct (* A number between 0 and 15 *) @@ -166,9 +166,12 @@ let encode ?(reverse = false) t = let byte = i / 2 in Char.to_int t.[if reverse then n - 1 - byte else byte] in - let c = if i mod 2 = 0 then (* hi *) - c lsr 4 else (* lo *) - c in + let c = + if i mod 2 = 0 then (* hi *) + c lsr 4 + else (* lo *) + c + in hex_char_of_int_exn (c land 15) ) let%test_unit "decode" = @@ -186,18 +189,18 @@ module Safe = struct let to_hex (data : string) : string = String.to_list data |> List.map ~f:(fun c -> - let charify u4 = - match u4 with - | x when x <= 9 && x >= 0 -> - Char.(of_int_exn @@ (x + to_int '0')) - | x when x <= 15 && x >= 10 -> - Char.(of_int_exn @@ (x - 10 + to_int 'A')) - | _ -> - failwith "Unexpected u4 has only 4bits of information" - in - let high = charify @@ ((Char.to_int c land 0xF0) lsr 4) in - let lo = charify (Char.to_int c land 0x0F) in - String.of_char_list [ high; lo ] ) + let charify u4 = + match u4 with + | x when x <= 9 && x >= 0 -> + Char.(of_int_exn @@ (x + to_int '0')) + | x when x <= 15 && x >= 10 -> + Char.(of_int_exn @@ (x - 10 + to_int 'A')) + | _ -> + failwith "Unexpected u4 has only 4bits of information" + in + let high = charify @@ ((Char.to_int c land 0xF0) lsr 4) in + let lo = charify (Char.to_int c land 0x0F) in + String.of_char_list [ high; lo ] ) |> String.concat let%test_unit "to_hex sane" = @@ -224,12 +227,12 @@ module Safe = struct in String.to_list hex |> List.chunks_of ~length:2 |> List.fold_result ~init:[] ~f:(fun acc chunk -> - match chunk with - | [ a; b ] when Char.is_alphanum a && Char.is_alphanum b -> - Or_error.return - @@ (Char.((to_u4 a lsl 4) lor to_u4 b |> of_int_exn) :: acc) - | _ -> - Or_error.error_string "invalid hex" ) + match chunk with + | [ a; b ] when Char.is_alphanum a && Char.is_alphanum b -> + Or_error.return + @@ (Char.((to_u4 a lsl 4) lor to_u4 b |> of_int_exn) :: acc) + | _ -> + Or_error.error_string "invalid hex" ) |> Or_error.ok |> Option.map ~f:(Fn.compose String.of_char_list List.rev) From 471d4c23c5ed3f8e5eed0fcdb3fe2888236bbb85 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 15:56:59 +0800 Subject: [PATCH 43/56] parallel: port to 5.2.1 + core v0.17 --- src/lib/parallel/dune | 2 +- src/lib/parallel/parallel.ml | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/lib/parallel/dune b/src/lib/parallel/dune index bfd2740f499c..b71011f40a71 100644 --- a/src/lib/parallel/dune +++ b/src/lib/parallel/dune @@ -7,7 +7,7 @@ async_rpc_kernel async core - rpc_parallel + rpc_parallel.unauthenticated async.async_rpc core_kernel) (preprocess diff --git a/src/lib/parallel/parallel.ml b/src/lib/parallel/parallel.ml index 570073752847..c6c4783b24f4 100644 --- a/src/lib/parallel/parallel.ml +++ b/src/lib/parallel/parallel.ml @@ -1,11 +1,12 @@ open Core open Async +open Rpc_parallel_unauthenticated let initialized = ref false let worker_command_name = "parallel-worker" -let worker_command = Rpc_parallel.Expert.worker_command +let worker_command = Expert.worker_command let init_master () = if not !initialized then ( @@ -14,7 +15,7 @@ let init_master () = ~send_every:(Time_ns.Span.of_sec 10.) ~timeout:(Time_ns.Span.of_min 15.) () in - Rpc_parallel.Expert.start_master_server_exn - ~rpc_handshake_timeout:(Time.Span.of_min 10.) ~rpc_heartbeat_config - ~worker_command_args:[ worker_command_name ] () ; + Expert.start_master_server_exn + ~rpc_handshake_timeout:(Time_float.Span.of_min 10.) + ~rpc_heartbeat_config ~worker_command_args:[ worker_command_name ] () ; initialized := true ) From 771fac481fb394cd77bbaf126a90647a185d2c1a Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 16:13:14 +0800 Subject: [PATCH 44/56] snarky_group_map: port to 5.2.1 --- src/lib/snarky_group_map/checked_map.ml | 5 +++-- src/lib/snarky_group_map/checked_map.mli | 5 +++-- src/lib/snarky_group_map/snarky_group_map.ml | 2 +- src/lib/snarky_group_map/snarky_group_map.mli | 4 +++- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/lib/snarky_group_map/checked_map.ml b/src/lib/snarky_group_map/checked_map.ml index 52dfa1a4fc26..9bc72a8b69ef 100644 --- a/src/lib/snarky_group_map/checked_map.ml +++ b/src/lib/snarky_group_map/checked_map.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Aux (Impl : Snarky_backendless.Snark_intf.Run) = struct open Impl @@ -57,7 +57,8 @@ let wrap (type f v) , Field.((x1_is_first * y1) + (x2_is_first * y2) + (x3_is_first * y3)) ) ) module Make - (M : Snarky_backendless.Snark_intf.Run) (P : sig + (M : Snarky_backendless.Snark_intf.Run) + (P : sig val params : M.field Group_map.Params.t end) = struct diff --git a/src/lib/snarky_group_map/checked_map.mli b/src/lib/snarky_group_map/checked_map.mli index d8d548c6174e..a66f85993fbb 100644 --- a/src/lib/snarky_group_map/checked_map.mli +++ b/src/lib/snarky_group_map/checked_map.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core val wrap : (module Snarky_backendless.Snark_intf.Run @@ -9,7 +9,8 @@ val wrap : -> ('input -> 'v * 'v) Staged.t module Make - (M : Snarky_backendless.Snark_intf.Run) (Params : sig + (M : Snarky_backendless.Snark_intf.Run) + (Params : sig val params : M.field Group_map.Params.t end) : sig val to_group : M.Field.t -> M.Field.t * M.Field.t diff --git a/src/lib/snarky_group_map/snarky_group_map.ml b/src/lib/snarky_group_map/snarky_group_map.ml index 95f6ad88e32c..1d83f76eb1e2 100644 --- a/src/lib/snarky_group_map/snarky_group_map.ml +++ b/src/lib/snarky_group_map/snarky_group_map.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Params = Group_map.Params let to_group (type t) diff --git a/src/lib/snarky_group_map/snarky_group_map.mli b/src/lib/snarky_group_map/snarky_group_map.mli index 6fb95ce428e0..3bfea474dfd4 100644 --- a/src/lib/snarky_group_map/snarky_group_map.mli +++ b/src/lib/snarky_group_map/snarky_group_map.mli @@ -1,3 +1,5 @@ +open Core + module Params : sig type 'f t = 'f Group_map.Params.t @@ -20,7 +22,7 @@ module Checked : sig (module Snark_intf.Run with type field = 'f and type field_var = 'v) -> potential_xs:('input -> 'v * 'v * 'v) -> y_squared:(x:'v -> 'v) - -> ('input -> 'v * 'v) Core_kernel.Staged.t + -> ('input -> 'v * 'v) Staged.t val to_group : (module Snark_intf.Run with type field = 'f and type field_var = 'v) From dd3d517f8606c632846cd2fa656b9f494e3c429a Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 16:14:28 +0800 Subject: [PATCH 45/56] concurrency > interruptible: port to 5.2.1 --- .../interruptible/interruptible.ml | 2 +- .../interruptible/interruptible.mli | 2 +- .../interruptible/tests/test_interruptible.ml | 42 +++++++++---------- 3 files changed, 23 insertions(+), 23 deletions(-) diff --git a/src/lib/concurrency/interruptible/interruptible.ml b/src/lib/concurrency/interruptible/interruptible.ml index 1aebcb00c8c5..9a230d6671db 100644 --- a/src/lib/concurrency/interruptible/interruptible.ml +++ b/src/lib/concurrency/interruptible/interruptible.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module T = struct diff --git a/src/lib/concurrency/interruptible/interruptible.mli b/src/lib/concurrency/interruptible/interruptible.mli index cae901f90426..40e43fc99843 100644 --- a/src/lib/concurrency/interruptible/interruptible.mli +++ b/src/lib/concurrency/interruptible/interruptible.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel (** The type of interruptible computations. diff --git a/src/lib/concurrency/interruptible/tests/test_interruptible.ml b/src/lib/concurrency/interruptible/tests/test_interruptible.ml index 480f6830ae0b..319def17ce05 100644 --- a/src/lib/concurrency/interruptible/tests/test_interruptible.ml +++ b/src/lib/concurrency/interruptible/tests/test_interruptible.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel open Interruptible @@ -13,14 +13,14 @@ let test_monad_gets_interrupted () = let ivar = Ivar.create () in don't_wait_for (let open Let_syntax in - let%bind () = lift Deferred.unit (Ivar.read ivar) in - let%bind () = uninterruptible (wait 100.) in - incr r ; - let%map () = uninterruptible (wait 100.) in - incr r) ; + let%bind () = lift Deferred.unit (Ivar.read ivar) in + let%bind () = uninterruptible (wait 100.) in + incr r ; + let%map () = uninterruptible (wait 100.) in + incr r ) ; let open Deferred.Let_syntax in let%bind () = wait 130. in - Ivar.fill ivar () ; + Ivar.fill_exn ivar () ; let%map () = wait 100. in Alcotest.(check int) "Only first operation ran before interruption" 1 !r ) @@ -37,11 +37,11 @@ let test_monad_gets_interrupted_within_nested_binds () = in don't_wait_for (let open Let_syntax in - let%bind () = lift Deferred.unit (Ivar.read ivar) in - go ()) ; + let%bind () = lift Deferred.unit (Ivar.read ivar) in + go () ) ; let open Deferred.Let_syntax in let%bind () = wait 130. in - Ivar.fill ivar () ; + Ivar.fill_exn ivar () ; let%map () = wait 100. in Alcotest.(check int) "Only first operation ran in nested bind" 1 !r ) @@ -58,11 +58,11 @@ let test_interruptions_still_run_finally_blocks () = in don't_wait_for (let open Let_syntax in - let%bind () = lift Deferred.unit (Ivar.read ivar) in - finally (go ()) ~f:(fun () -> incr r)) ; + let%bind () = lift Deferred.unit (Ivar.read ivar) in + finally (go ()) ~f:(fun () -> incr r) ) ; let open Deferred.Let_syntax in let%bind () = wait 130. in - Ivar.fill ivar () ; + Ivar.fill_exn ivar () ; let%map () = wait 100. in Alcotest.(check int) "One operation ran plus finally block" 2 !r ) @@ -83,19 +83,19 @@ let test_interruptions_branches_do_not_cancel_each_other () = let start = uninterruptible Deferred.unit in don't_wait_for (let open Let_syntax in - let%bind () = start in - let%bind () = lift Deferred.unit (Ivar.read ivar_r) in - go r) ; + let%bind () = start in + let%bind () = lift Deferred.unit (Ivar.read ivar_r) in + go r ) ; don't_wait_for (let open Let_syntax in - let%bind () = start in - let%bind () = lift Deferred.unit (Ivar.read ivar_s) in - go s) ; + let%bind () = start in + let%bind () = lift Deferred.unit (Ivar.read ivar_s) in + go s ) ; let open Deferred.Let_syntax in let%bind () = wait 130. in - Ivar.fill ivar_r () ; + Ivar.fill_exn ivar_r () ; let%bind () = wait 100. in - Ivar.fill ivar_s () ; + Ivar.fill_exn ivar_s () ; let%map () = wait 100. in Alcotest.(check int) "First branch ran once" 1 !r ; Alcotest.(check int) "Second branch ran twice" 2 !s ) From 596a75a5a1801a6070117a823d1152bfae68071b Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 16:15:15 +0800 Subject: [PATCH 46/56] concurrency > promise: port to 5.2.1 --- src/lib/concurrency/promise/js/promise.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/concurrency/promise/js/promise.ml b/src/lib/concurrency/promise/js/promise.ml index cafe669d45ea..b6d1bf20863e 100644 --- a/src/lib/concurrency/promise/js/promise.ml +++ b/src/lib/concurrency/promise/js/promise.ml @@ -26,7 +26,7 @@ external create : (('a -> unit) -> unit) -> 'a t = "deferred_create" let to_deferred promise = let module Ivar = Async_kernel.Ivar in let ivar = Ivar.create () in - upon_exn promise (fun x -> Ivar.fill ivar x) ; + upon_exn promise (fun x -> Ivar.fill_exn ivar x) ; Ivar.read ivar include Base.Monad.Make (struct From 2f2050ad707f3f4e21a011ca0bf69cb8514101d8 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 16:22:47 +0800 Subject: [PATCH 47/56] concurrency > pipe_lib: port to 5.2.1 --- .../concurrency/pipe_lib/broadcast_pipe.ml | 23 +++++---- .../pipe_lib/choosable_synchronous_pipe.ml | 4 +- src/lib/concurrency/pipe_lib/dune | 9 +++- src/lib/concurrency/pipe_lib/linear_pipe.ml | 16 +++--- src/lib/concurrency/pipe_lib/linear_pipe.mli | 2 +- src/lib/concurrency/pipe_lib/strict_pipe.ml | 49 ++++++++++--------- .../pipe_lib/swappable_strict_pipe.ml | 8 +-- .../test/choosable_synchronous_pipe_test.ml | 2 +- .../test/swappable_strict_pipe_test.ml | 4 +- 9 files changed, 65 insertions(+), 52 deletions(-) diff --git a/src/lib/concurrency/pipe_lib/broadcast_pipe.ml b/src/lib/concurrency/pipe_lib/broadcast_pipe.ml index e4634a9fe88e..6ce2e9efe254 100644 --- a/src/lib/concurrency/pipe_lib/broadcast_pipe.ml +++ b/src/lib/concurrency/pipe_lib/broadcast_pipe.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel type 'a t = @@ -27,7 +27,7 @@ let create a = don't_wait_for (Pipe.iter ~flushed:(Consumer consumer) root_r ~f:(fun v -> downstream_flushed_v := Ivar.create () ; - let inner_pipes = Int.Table.data t.pipes in + let inner_pipes = Hashtbl.data t.pipes in let%bind () = Deferred.List.iter ~how:`Parallel inner_pipes ~f:(fun p -> Pipe.write p v ) @@ -39,7 +39,7 @@ let create a = in if Ivar.is_full !downstream_flushed_v then [%log' error (Logger.create ())] "Ivar.fill bug is here!" ; - Ivar.fill !downstream_flushed_v () ; + Ivar.fill_exn !downstream_flushed_v () ; Deferred.unit ) ) ; (t, t) @@ -67,10 +67,10 @@ module Reader = struct let r, w = Pipe.create () in Pipe.write_without_pushback w (peek t) ; let reader_id = fresh_reader_id t in - Int.Table.add_exn t.pipes ~key:reader_id ~data:w ; + Hashtbl.add_exn t.pipes ~key:reader_id ~data:w ; let d = let%map b = f r in - Int.Table.remove t.pipes reader_id ; + Hashtbl.remove t.pipes reader_id ; b in d ) @@ -123,8 +123,8 @@ module Writer = struct let close t = guard_already_closed ~context:"Writer.close" t (fun () -> Pipe.close t.root_pipe ; - Int.Table.iter t.pipes ~f:(fun w -> Pipe.close w) ; - Int.Table.clear t.pipes ) + Hashtbl.iter t.pipes ~f:(fun w -> Pipe.close w) ; + Hashtbl.clear t.pipes ) end let map t ~f = @@ -192,16 +192,15 @@ let%test_module _ = let%test "Writing is synchronous" = Run_in_thread.block_on_async_exn (fun () -> - Core_kernel.Backtrace.elide := false ; + Backtrace.elide := false ; let pipe_r, pipe_w = create () in let counts1, counts2 = (zero_counts (), zero_counts ()) in let setup_reader counts = don't_wait_for @@ Reader.iter pipe_r ~f:(fun () -> - counts.immediate_iterations <- - counts.immediate_iterations + 1 ; - let%map () = after @@ Time_ns.Span.of_sec 1. in - counts.deferred_iterations <- counts.deferred_iterations + 1 ) + counts.immediate_iterations <- counts.immediate_iterations + 1 ; + let%map () = after @@ Time_ns.Span.of_sec 1. in + counts.deferred_iterations <- counts.deferred_iterations + 1 ) in setup_reader counts1 ; (* The reader doesn't run until we yield. *) diff --git a/src/lib/concurrency/pipe_lib/choosable_synchronous_pipe.ml b/src/lib/concurrency/pipe_lib/choosable_synchronous_pipe.ml index 7871a0da4230..7e7fd0081718 100644 --- a/src/lib/concurrency/pipe_lib/choosable_synchronous_pipe.ml +++ b/src/lib/concurrency/pipe_lib/choosable_synchronous_pipe.ml @@ -1,5 +1,5 @@ +open Core open Async_kernel -open Core_kernel (** The same type is used to represent both reader and writer. @@ -19,7 +19,7 @@ exception Pipe_closed exception Pipe_handle_used let fill_inner_ivar inner_ivar value = - try Ivar.fill inner_ivar value + try Ivar.fill_exn inner_ivar value with _ -> ( match Ivar.value_exn inner_ivar with | `Eof -> diff --git a/src/lib/concurrency/pipe_lib/dune b/src/lib/concurrency/pipe_lib/dune index c2491c90ffba..c2b3a73e2313 100644 --- a/src/lib/concurrency/pipe_lib/dune +++ b/src/lib/concurrency/pipe_lib/dune @@ -16,4 +16,11 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_mina ppx_version ppx_jane ppx_deriving.make))) + (pps + ppx_assert + ppx_inline_test + ppx_let + ppx_mina + ppx_sexp_conv + ppx_version + ppx_deriving.make))) diff --git a/src/lib/concurrency/pipe_lib/linear_pipe.ml b/src/lib/concurrency/pipe_lib/linear_pipe.ml index 2836495380c0..3391e92f11fb 100644 --- a/src/lib/concurrency/pipe_lib/linear_pipe.ml +++ b/src/lib/concurrency/pipe_lib/linear_pipe.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module Writer = Pipe.Writer @@ -25,8 +25,8 @@ let create_reader ~close_on_exception f = let write w x = ( if Pipe.is_closed w then - let logger = Logger.create () in - [%log warn] "writing to closed linear pipe" ~metadata:[] ) ; + let logger = Logger.create () in + [%log warn] "writing to closed linear pipe" ~metadata:[] ) ; Pipe.write w x let write_if_open = Pipe.write_if_open @@ -134,7 +134,7 @@ let merge_unordered rs = List.iter rs ~f:(fun reader -> don't_wait_for (iter reader ~f:(fun x -> Pipe.write merged_writer x)) ) ; don't_wait_for - (let%map () = Deferred.List.iter rs ~f:closed in + (let%map () = Deferred.List.iter rs ~f:closed ~how:`Sequential in Pipe.close merged_writer ) ; merged_reader @@ -147,11 +147,13 @@ let fork reader n = let readers = List.map pipes ~f:(fun (r, _) -> r) in don't_wait_for (iter reader ~f:(fun x -> - Deferred.List.iter writers ~f:(fun writer -> + Deferred.List.iter writers + ~f:(fun writer -> if not (Pipe.is_closed writer) then Pipe.write writer x - else return () ) ) ) ; + else return () ) + ~how:`Sequential ) ) ; don't_wait_for - (let%map () = Deferred.List.iter readers ~f:closed in + (let%map () = Deferred.List.iter readers ~f:closed ~how:`Sequential in close_read reader ) ; readers diff --git a/src/lib/concurrency/pipe_lib/linear_pipe.mli b/src/lib/concurrency/pipe_lib/linear_pipe.mli index 2eadaf2f90b6..fe4067b756ed 100644 --- a/src/lib/concurrency/pipe_lib/linear_pipe.mli +++ b/src/lib/concurrency/pipe_lib/linear_pipe.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel module Writer : sig diff --git a/src/lib/concurrency/pipe_lib/strict_pipe.ml b/src/lib/concurrency/pipe_lib/strict_pipe.ml index 3e8511354bac..07f65e402752 100644 --- a/src/lib/concurrency/pipe_lib/strict_pipe.ml +++ b/src/lib/concurrency/pipe_lib/strict_pipe.ml @@ -1,5 +1,5 @@ +open Core open Async_kernel -open Core_kernel exception Overflow of string @@ -94,7 +94,9 @@ module Reader0 = struct return (`Eof b) | `Ok a -> ( (* The async scheduler could yield here *) - match%bind f b a with + match%bind + f b a + with | `Stop x -> return (`Terminated x) | `Continue b' -> @@ -147,7 +149,7 @@ module Reader0 = struct Deferred.choose (List.map readers ~f:(fun r -> Deferred.choice (Pipe.values_available r.reader) - (fun _ -> ()) ) ) + (fun _ -> () ) ) ) in List.find readers ~f:not_empty in @@ -184,11 +186,15 @@ module Reader0 = struct * should still get the behavior we want. *) don't_wait_for (Pipe.iter reader.reader ~f:(fun x -> - Deferred.List.iter writers ~f:(fun writer -> + Deferred.List.iter writers + ~f:(fun writer -> if not (Pipe.is_closed writer) then Pipe.write writer x - else return () ) ) ) ; + else return () ) + ~how:`Sequential ) ) ; don't_wait_for - (let%map () = Deferred.List.iter readers ~f:Pipe.closed in + (let%map () = + Deferred.List.iter readers ~f:Pipe.closed ~how:`Sequential + in Pipe.close_read reader.reader ) ; let strict_readers = List.map readers ~f:(wrap_reader ?name:reader.name) @@ -231,8 +237,7 @@ module Writer = struct (* TODO: See #1281 *) let to_linear_pipe { writer = pipe; _ } = pipe - let handle_buffered_write : - type type_ return. + let handle_buffered_write : type type_ return. ('t, type_, return) t -> 't -> capacity:int @@ -248,14 +253,14 @@ module Writer = struct let write : type type_ return. ('t, type_, return) t -> 't -> return = fun writer data -> ( if Pipe.is_closed writer.writer then - let logger = Logger.create () in - [%log warn] "writing to closed pipe $name" - ~metadata: - [ ( "name" - , `String - (Sexplib.Sexp.to_string ([%sexp_of: string option] writer.name)) - ) - ] ) ; + let logger = Logger.create () in + [%log warn] "writing to closed pipe $name" + ~metadata: + [ ( "name" + , `String + (Sexplib.Sexp.to_string + ([%sexp_of: string option] writer.name) ) ) + ] ) ; match writer.type_ with | Synchronous -> Pipe.write writer.writer data @@ -391,8 +396,8 @@ let%test_module "Strict_pipe.close" = assert (Writer.is_closed input_writer) ; assert (Reader.is_closed output_reader) - let%test_unit "'close' would close the downstream pipes linked by \ - 'filter_map'" = + let%test_unit + "'close' would close the downstream pipes linked by 'filter_map'" = let input_reader, input_writer = create Synchronous in assert (not (Writer.is_closed input_writer)) ; let output_reader = @@ -414,8 +419,8 @@ let%test_module "Strict_pipe.close" = assert (Reader.is_closed output_reader1) ; assert (Reader.is_closed output_reader2) - let%test_unit "'close' would close the downstream pipes linked by \ - 'partition_map3'" = + let%test_unit + "'close' would close the downstream pipes linked by 'partition_map3'" = let input_reader, input_writer = create Synchronous in assert (not (Writer.is_closed input_writer)) ; let output_reader1, output_reader2, output_reader3 = @@ -430,8 +435,8 @@ let%test_module "Strict_pipe.close" = assert (Reader.is_closed output_reader2) ; assert (Reader.is_closed output_reader3) - let%test_unit "'close' would close the downstream pipes linked by \ - 'transfer'" = + let%test_unit + "'close' would close the downstream pipes linked by 'transfer'" = let input_reader, input_writer = create Synchronous and _, output_writer = create Synchronous in assert (not (Writer.is_closed input_writer)) ; diff --git a/src/lib/concurrency/pipe_lib/swappable_strict_pipe.ml b/src/lib/concurrency/pipe_lib/swappable_strict_pipe.ml index d3775738bc60..d8a5b04f1fad 100644 --- a/src/lib/concurrency/pipe_lib/swappable_strict_pipe.ml +++ b/src/lib/concurrency/pipe_lib/swappable_strict_pipe.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel type 'data short_lived_pipe_t = 'data Choosable_synchronous_pipe.writer_t @@ -60,7 +60,7 @@ let terminate state = Option.iter (Ivar.peek next_short_lived_pipe) ~f:(fun (writer, processed_signal) -> Choosable_synchronous_pipe.close writer ; - Ivar.fill processed_signal () ) ; + Ivar.fill_exn processed_signal () ) ; `Finished () (** Returns a choice that terminates the pipe when the termination signal is filled. @@ -77,7 +77,7 @@ let handle_next_short_lived_pipe state (new_sink, processed_signal) = (* TODO when rewriting to Ocaml 5.x, consider using an R/W mutex to protect the mutable field. *) t.next_short_lived_pipe <- Ivar.create () ; - Ivar.fill processed_signal () ; + Ivar.fill_exn processed_signal () ; Option.iter ~f:Choosable_synchronous_pipe.close state.short_lived_sink ; `Repeat { state with short_lived_sink = Some new_sink } @@ -267,7 +267,7 @@ let swap_reader (Swappable t) : _ Choosable_synchronous_pipe.reader_t Deferred.t Choosable_synchronous_pipe.create () in let processed_signal = Ivar.create () in - Ivar.fill t.next_short_lived_pipe (short_lived_writer, processed_signal) ; + Ivar.fill_exn t.next_short_lived_pipe (short_lived_writer, processed_signal) ; let%map () = Ivar.read processed_signal in short_lived_reader diff --git a/src/lib/concurrency/pipe_lib/test/choosable_synchronous_pipe_test.ml b/src/lib/concurrency/pipe_lib/test/choosable_synchronous_pipe_test.ml index 685e91d0241f..0b02780bc600 100644 --- a/src/lib/concurrency/pipe_lib/test/choosable_synchronous_pipe_test.ml +++ b/src/lib/concurrency/pipe_lib/test/choosable_synchronous_pipe_test.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel open Pipe_lib.Choosable_synchronous_pipe diff --git a/src/lib/concurrency/pipe_lib/test/swappable_strict_pipe_test.ml b/src/lib/concurrency/pipe_lib/test/swappable_strict_pipe_test.ml index 122958fef151..b84b5412d624 100644 --- a/src/lib/concurrency/pipe_lib/test/swappable_strict_pipe_test.ml +++ b/src/lib/concurrency/pipe_lib/test/swappable_strict_pipe_test.ml @@ -1,5 +1,5 @@ +open Core open Async_kernel -open Core_kernel let read_all_values ~expected ?pipe iterator = let counter = ref 0 in @@ -25,7 +25,7 @@ let create_buffered_swappable capacity = let read_all_values_or_timeout ?pipe ~expected iterator = let read_all_values = read_all_values iterator ~expected ?pipe in Deferred.choose - [ Deferred.choice read_all_values ident + [ Deferred.choice read_all_values Fn.id ; Deferred.choice (after (Time_ns.Span.of_sec 1.5)) (fun () -> failwith "Swappable strict pipe hangs, timeout!") From 472554b127d812aeb5925e90650dc61f9051c175 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:26:45 +0800 Subject: [PATCH 48/56] port ppx-version to OCaml 5.2.1 + Core.v0.17.0 --- src/lib/ppx_version/bin_io_unversioned.ml | 4 +- src/lib/ppx_version/lint_primitive_uses.ml | 2 +- src/lib/ppx_version/lint_version_syntax.ml | 11 +-- src/lib/ppx_version/runtime/dune | 2 +- src/lib/ppx_version/runtime/shapes.ml | 10 +- .../bad_version_syntax_bin_io_in_functor.ml | 2 +- .../test/bad_version_syntax_extension.ml | 6 +- .../bad_version_syntax_missing_versioned.ml | 2 +- .../bad_version_syntax_multiple_errors.ml | 3 +- .../test/bad_versioned_in_functor.ml | 2 +- .../test/bad_versioned_in_nested_functor.ml | 2 +- src/lib/ppx_version/test/dune | 38 +++---- .../ppx_version/test/good_version_syntax.ml | 11 ++- .../test/versioned_bad_arrow_type.ml | 2 +- .../test/versioned_bad_contained_types.ml | 2 +- .../test/versioned_bad_module_name.ml | 2 +- .../ppx_version/test/versioned_bad_option.ml | 2 +- .../test/versioned_bad_unnumbered.ml | 2 +- src/lib/ppx_version/test/versioned_good.ml | 18 +++- .../versioned_module_bad_missing_to_latest.ml | 2 +- .../test/versioned_module_bad_missing_type.ml | 2 +- .../test/versioned_module_bad_stable_name.ml | 2 +- .../test/versioned_module_bad_version_name.ml | 2 +- .../versioned_module_bad_version_order.ml | 2 +- .../ppx_version/test/versioned_module_good.ml | 68 ++++++------- .../ppx_version/test/versioned_sig_good.ml | 2 +- .../ppx_version/test/versioned_sig_good.mli | 2 +- src/lib/ppx_version/versioned_module.ml | 98 ++++++++----------- src/lib/ppx_version/versioned_type.ml | 7 +- src/lib/ppx_version/versioned_util.ml | 8 +- 30 files changed, 156 insertions(+), 162 deletions(-) diff --git a/src/lib/ppx_version/bin_io_unversioned.ml b/src/lib/ppx_version/bin_io_unversioned.ml index 5fbdc1b2dc1a..f0d8dd988d9e 100644 --- a/src/lib/ppx_version/bin_io_unversioned.ml +++ b/src/lib/ppx_version/bin_io_unversioned.ml @@ -10,7 +10,7 @@ we used [@@deriving bin_io] directly. *) -open Core_kernel +open Core open Ppxlib open Versioned_util @@ -53,7 +53,7 @@ let bin_io_gens : (* Ppxlib.Deriving.Deriver.T x -> x *) |> (fun r -> field r extension_constructor_argument_idx) (* Ppxlib.Deriving.Deriver.Actual_deriver x -> x *) - |> fun r -> field r constructor_argument_idx) + |> fun r -> field r constructor_argument_idx ) in let name = (* Ppxlib.Deriving.Deriver.Actual_deriver.t, 0th field is name *) diff --git a/src/lib/ppx_version/lint_primitive_uses.ml b/src/lib/ppx_version/lint_primitive_uses.ml index 67d2c910e958..8fd31196b9bf 100644 --- a/src/lib/ppx_version/lint_primitive_uses.ml +++ b/src/lib/ppx_version/lint_primitive_uses.ml @@ -1,4 +1,4 @@ -open! Core_kernel +open Core open Ppxlib let error which loc = diff --git a/src/lib/ppx_version/lint_version_syntax.ml b/src/lib/ppx_version/lint_version_syntax.ml index c133debc65f3..11f513d0fd80 100644 --- a/src/lib/ppx_version/lint_version_syntax.ml +++ b/src/lib/ppx_version/lint_version_syntax.ml @@ -1,6 +1,6 @@ (* lint_version_syntax.ml -- static enforcement of syntactic items relating to proper versioning *) -open Core_kernel +open Core open Ppxlib open Versioned_util @@ -11,7 +11,7 @@ let errors_as_warnings_ref = ref false let make_deriving_validator ~pred err_msg type_decl = let derivers = Ast_pattern.( - attribute ~name:(string "deriving") ~payload:(single_expr_payload __)) + attribute ~name:(string "deriving") ~payload:(single_expr_payload __) ) in match List.find_map type_decl.ptype_attributes ~f:(fun attr -> @@ -117,9 +117,8 @@ let is_stable_latest_inc_decl inc_decl = let is_jane_street_prefix prefix = match Longident.flatten_exn prefix with - (* N.B.: Uuid is in core_kernel library, but not in Core_kernel module *) - | core :: _ - when List.mem [ "Core_kernel"; "Core"; "Uuid" ] core ~equal:String.equal -> + (* N.B.: Uuid is in Core library, but not in Core module *) + | core :: _ when List.mem [ "Core"; "Uuid" ] core ~equal:String.equal -> true | _ -> false @@ -475,6 +474,6 @@ let lint_impl str = let () = Driver.add_arg "-lint-version-syntax-warnings" - (Caml.Arg.Set errors_as_warnings_ref) + (Stdlib.Arg.Set errors_as_warnings_ref) ~doc:" Version syntax errors as warnings" ; Ppxlib.Driver.register_transformation name ~lint_impl diff --git a/src/lib/ppx_version/runtime/dune b/src/lib/ppx_version/runtime/dune index 61310daecd82..6de4856736d7 100644 --- a/src/lib/ppx_version/runtime/dune +++ b/src/lib/ppx_version/runtime/dune @@ -1,4 +1,4 @@ (library (name ppx_version_runtime) (public_name ppx_version.runtime) - (libraries base core_kernel sexplib0 bin_prot bin_prot.shape)) + (libraries base core sexplib0 bin_prot bin_prot.shape)) diff --git a/src/lib/ppx_version/runtime/shapes.ml b/src/lib/ppx_version/runtime/shapes.ml index 3a4bc17a3b62..bb83356d89e9 100644 --- a/src/lib/ppx_version/runtime/shapes.ml +++ b/src/lib/ppx_version/runtime/shapes.ml @@ -1,13 +1,13 @@ (* shapes.ml -- registry of Bin_prot shapes *) -open Core_kernel -module Shape_tbl = Hashtbl.Make (Base.String) +open Core +module Shape_tbl = Hashtbl.Make (String) let shape_tbl : (Bin_prot.Shape.t * string) Shape_tbl.t = Shape_tbl.create () -let find path_to_type = Shape_tbl.find shape_tbl path_to_type +let find path_to_type = Hashtbl.find shape_tbl path_to_type -let iteri ~f = Shape_tbl.iteri shape_tbl ~f +let iteri ~f = Hashtbl.iteri shape_tbl ~f let equal_shapes shape1 shape2 = let canonical1 = Bin_prot.Shape.eval shape1 in @@ -15,7 +15,7 @@ let equal_shapes shape1 shape2 = Bin_prot.Shape.Canonical.compare canonical1 canonical2 = 0 let register path_to_type (shape : Bin_prot.Shape.t) (ty_decl : string) = - match Shape_tbl.add shape_tbl ~key:path_to_type ~data:(shape, ty_decl) with + match Hashtbl.add shape_tbl ~key:path_to_type ~data:(shape, ty_decl) with | `Ok -> () | `Duplicate -> ( diff --git a/src/lib/ppx_version/test/bad_version_syntax_bin_io_in_functor.ml b/src/lib/ppx_version/test/bad_version_syntax_bin_io_in_functor.ml index 94fa22cc1ca8..03682a1e2503 100644 --- a/src/lib/ppx_version/test/bad_version_syntax_bin_io_in_functor.ml +++ b/src/lib/ppx_version/test/bad_version_syntax_bin_io_in_functor.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* deriving bin_io in functor body *) diff --git a/src/lib/ppx_version/test/bad_version_syntax_extension.ml b/src/lib/ppx_version/test/bad_version_syntax_extension.ml index 65594366a64a..58fc527b54d4 100644 --- a/src/lib/ppx_version/test/bad_version_syntax_extension.ml +++ b/src/lib/ppx_version/test/bad_version_syntax_extension.ml @@ -1,8 +1,8 @@ -open Core_kernel +open Core (* an extension that's not a test module *) let%not_a_test_module "bad bin_io only" = - ( module struct + (module struct type t = string [@@deriving bin_io] - end ) + end) diff --git a/src/lib/ppx_version/test/bad_version_syntax_missing_versioned.ml b/src/lib/ppx_version/test/bad_version_syntax_missing_versioned.ml index d24ffc7aa920..d9eff664e16d 100644 --- a/src/lib/ppx_version/test/bad_version_syntax_missing_versioned.ml +++ b/src/lib/ppx_version/test/bad_version_syntax_missing_versioned.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* deriving bin_io, version, but not wrapped in %%versioned *) diff --git a/src/lib/ppx_version/test/bad_version_syntax_multiple_errors.ml b/src/lib/ppx_version/test/bad_version_syntax_multiple_errors.ml index f118b795feb6..5c74329f9038 100644 --- a/src/lib/ppx_version/test/bad_version_syntax_multiple_errors.ml +++ b/src/lib/ppx_version/test/bad_version_syntax_multiple_errors.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Foo = struct module Bar = struct @@ -6,7 +6,6 @@ module Foo = struct end type t = string [@@deriving bin_io] - type t' = string [@@deriving bin_io] module Quux = struct diff --git a/src/lib/ppx_version/test/bad_versioned_in_functor.ml b/src/lib/ppx_version/test/bad_versioned_in_functor.ml index c6ba576b3a79..e01bfe7de78a 100644 --- a/src/lib/ppx_version/test/bad_versioned_in_functor.ml +++ b/src/lib/ppx_version/test/bad_versioned_in_functor.ml @@ -1,6 +1,6 @@ (* versioned in functor body *) -open Core_kernel +open Core module Functor (X : sig end) = struct [%%versioned diff --git a/src/lib/ppx_version/test/bad_versioned_in_nested_functor.ml b/src/lib/ppx_version/test/bad_versioned_in_nested_functor.ml index 12a7addc37dd..38d083e7098b 100644 --- a/src/lib/ppx_version/test/bad_versioned_in_nested_functor.ml +++ b/src/lib/ppx_version/test/bad_versioned_in_nested_functor.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* deriving bin_io in nested functor body *) diff --git a/src/lib/ppx_version/test/dune b/src/lib/ppx_version/test/dune index adb0638ac956..d90d2e4746b2 100644 --- a/src/lib/ppx_version/test/dune +++ b/src/lib/ppx_version/test/dune @@ -8,27 +8,27 @@ (library (name good_version_syntax) (preprocess (pps ppx_jane ppx_version ppx_deriving_yojson)) - (libraries core_kernel bin_prot.shape ppx_version.runtime) + (libraries core bin_prot.shape ppx_version.runtime) (modules good_version_syntax)) ;; versioning (library (name versioned_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_good)) ;; module versioning (executable (name versioned_module_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime mina_stdlib) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime mina_stdlib) (modules versioned_module_good)) (executable (name versioned_sig_good) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_sig_good)) ;;; should fail @@ -38,25 +38,25 @@ (library (name bad_version_syntax_missing_versioned) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_version_syntax_missing_versioned)) (library (name bad_versioned_in_functor) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_versioned_in_functor)) (library (name bad_versioned_in_nested_functor) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_versioned_in_nested_functor)) (library (name bad_version_syntax_multiple_errors) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules bad_version_syntax_multiple_errors)) ;; versioning @@ -64,66 +64,66 @@ (library (name versioned_bad_module_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_module_name)) (library (name versioned_bad_version_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_version_name)) (library (name versioned_bad_type_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_type_name)) (library (name versioned_bad_option) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_option)) (library (name versioned_bad_contained_types) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_contained_types)) (library (name versioned_bad_arrow_type) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_bad_arrow_type)) ;; module versioning (library (name versioned_module_bad_stable_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_stable_name)) (library (name versioned_module_bad_version_name) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_version_name)) (library (name versioned_module_bad_missing_type) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_missing_type)) (library (name versioned_module_bad_version_order) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_version_order)) (library (name versioned_module_bad_missing_to_latest) (preprocess (pps ppx_jane ppx_deriving_yojson ppx_version)) - (libraries core_kernel bin_prot.shape sexplib0 ppx_version.runtime) + (libraries core bin_prot.shape sexplib0 ppx_version.runtime) (modules versioned_module_bad_missing_to_latest)) diff --git a/src/lib/ppx_version/test/good_version_syntax.ml b/src/lib/ppx_version/test/good_version_syntax.ml index 075e9dbb1ec8..be95168641f4 100644 --- a/src/lib/ppx_version/test/good_version_syntax.ml +++ b/src/lib/ppx_version/test/good_version_syntax.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* (generated) deriving version and bin_io both appear; OK outside functor body *) @@ -13,12 +13,17 @@ module M1 = struct end] end +module IntV1 = struct + include Int.Stable.V1 + + let __versioned__ = () +end + (* version with an argument *) module M = struct module V1 = struct module T = struct - type query = Core_kernel.Int.Stable.V1.t - [@@deriving bin_io, version { rpc }] + type query = IntV1.t [@@deriving bin_io, version { rpc }] end end end diff --git a/src/lib/ppx_version/test/versioned_bad_arrow_type.ml b/src/lib/ppx_version/test/versioned_bad_arrow_type.ml index f4604cdde22e..ac383cbaf190 100644 --- a/src/lib/ppx_version/test/versioned_bad_arrow_type.ml +++ b/src/lib/ppx_version/test/versioned_bad_arrow_type.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Foo = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_bad_contained_types.ml b/src/lib/ppx_version/test/versioned_bad_contained_types.ml index 730ec45e60cc..791614df67b2 100644 --- a/src/lib/ppx_version/test/versioned_bad_contained_types.ml +++ b/src/lib/ppx_version/test/versioned_bad_contained_types.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Foo = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_bad_module_name.ml b/src/lib/ppx_version/test/versioned_bad_module_name.ml index 6df41413d081..ae78322f01e4 100644 --- a/src/lib/ppx_version/test/versioned_bad_module_name.ml +++ b/src/lib/ppx_version/test/versioned_bad_module_name.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Foo = struct module Bar = struct diff --git a/src/lib/ppx_version/test/versioned_bad_option.ml b/src/lib/ppx_version/test/versioned_bad_option.ml index f7caa76fdeee..bbfb7ebddad3 100644 --- a/src/lib/ppx_version/test/versioned_bad_option.ml +++ b/src/lib/ppx_version/test/versioned_bad_option.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Foo = struct module Bar = struct diff --git a/src/lib/ppx_version/test/versioned_bad_unnumbered.ml b/src/lib/ppx_version/test/versioned_bad_unnumbered.ml index 5b5d3e317a84..cae49e7d35db 100644 --- a/src/lib/ppx_version/test/versioned_bad_unnumbered.ml +++ b/src/lib/ppx_version/test/versioned_bad_unnumbered.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Make (M : sig type t = Int.t [@@deriving version { unnumbered }] diff --git a/src/lib/ppx_version/test/versioned_good.ml b/src/lib/ppx_version/test/versioned_good.ml index 3fe0a8e5ed18..e573d787a5e5 100644 --- a/src/lib/ppx_version/test/versioned_good.ml +++ b/src/lib/ppx_version/test/versioned_good.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* a signature *) module type Some_intf = sig @@ -185,24 +185,36 @@ module M11 = struct end] end +module QueueV1 = struct + include Queue.Stable.V1 + + let __versioned__ = () +end + (* Jane Street trustlisting *) module M12 = struct [%%versioned module Stable = struct module V1 = struct - type t = int Core_kernel.Queue.Stable.V1.t + type t = int QueueV1.t let to_latest = Fn.id end end] end +module TimeSpanV1 = struct + include Time.Stable.Span.V1 + + let __versioned__ = () +end + (* Jane Street special case *) module M13 = struct [%%versioned module Stable = struct module V1 = struct - type t = Core_kernel.Time.Stable.Span.V1.t [@@deriving bin_io, version] + type t = TimeSpanV1 [@@deriving bin_io, version] let to_latest = Fn.id end diff --git a/src/lib/ppx_version/test/versioned_module_bad_missing_to_latest.ml b/src/lib/ppx_version/test/versioned_module_bad_missing_to_latest.ml index 9b60366f561b..494f32f9bd5a 100644 --- a/src/lib/ppx_version/test/versioned_module_bad_missing_to_latest.ml +++ b/src/lib/ppx_version/test/versioned_module_bad_missing_to_latest.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Type = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_module_bad_missing_type.ml b/src/lib/ppx_version/test/versioned_module_bad_missing_type.ml index 18d21d23e53f..cf04cdf8b5aa 100644 --- a/src/lib/ppx_version/test/versioned_module_bad_missing_type.ml +++ b/src/lib/ppx_version/test/versioned_module_bad_missing_type.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Type = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_module_bad_stable_name.ml b/src/lib/ppx_version/test/versioned_module_bad_stable_name.ml index e7118fcb89bc..5aa71b865be2 100644 --- a/src/lib/ppx_version/test/versioned_module_bad_stable_name.ml +++ b/src/lib/ppx_version/test/versioned_module_bad_stable_name.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Type = struct [%%versioned module Bad = struct end] diff --git a/src/lib/ppx_version/test/versioned_module_bad_version_name.ml b/src/lib/ppx_version/test/versioned_module_bad_version_name.ml index 31c3e69cf84d..7fdcd1e81ba5 100644 --- a/src/lib/ppx_version/test/versioned_module_bad_version_name.ml +++ b/src/lib/ppx_version/test/versioned_module_bad_version_name.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Type = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_module_bad_version_order.ml b/src/lib/ppx_version/test/versioned_module_bad_version_order.ml index 995b70cfda08..2f29572dea3e 100644 --- a/src/lib/ppx_version/test/versioned_module_bad_version_order.ml +++ b/src/lib/ppx_version/test/versioned_module_bad_version_order.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Type = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_module_good.ml b/src/lib/ppx_version/test/versioned_module_good.ml index 210b68ef1aa7..05b228625108 100644 --- a/src/lib/ppx_version/test/versioned_module_good.ml +++ b/src/lib/ppx_version/test/versioned_module_good.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* unused type *) [@@@warning "-34"] @@ -35,33 +35,31 @@ let () = let x = 15 in let buf = Bigstring.create 10 in (* Test writing given version. *) - ignore (M1.Stable.V3.With_all_version_tags.bin_write_t buf ~pos:0 x : int) ; + ignore (M1.Stable.V3.With_all_version_tags.bin_write_t buf ~pos:0 x : int); (* Test that reads are compatible with [With_version]. *) let y : M1.Stable.V3.With_all_version_tags.t_tagged = M1.Stable.V3.With_all_version_tags.bin_read_t_tagged buf ~pos_ref:(ref 0) in - assert (y.version = 3) ; - assert (y.t = x) ; + assert (y.version = 3); + assert (y.t = x); (* Test that what was read is what was written. *) let z = M1.Stable.V3.With_all_version_tags.bin_read_t buf ~pos_ref:(ref 0) in - assert (z = x) ; + assert (z = x); (* Test that trying to read the wrong version results in an assertion failure. *) - ( try - ignore - ( M1.Stable.V2.With_all_version_tags.bin_read_t buf ~pos_ref:(ref 0) - : int ) ; - assert false - with Failure _ -> () ) ; + (try + ignore + (M1.Stable.V2.With_all_version_tags.bin_read_t buf ~pos_ref:(ref 0) + : int); + assert false + with Failure _ -> ()); (* Test that [bin_read_all_tagged_to_latest] finds and uses the right deserialisation. *) match M1.Stable.bin_read_all_tagged_to_latest buf ~pos_ref:(ref 0) with - | Ok a -> - assert (a = x) - | Error _ -> - assert false + | Ok a -> assert (a = x) + | Error _ -> assert false module M2 = struct [%%versioned @@ -112,15 +110,13 @@ end let () = let x : M3.Stable.V3.t = { a = false; b = 15 } in let buf = Bigstring.create 20 in - ignore (M3.Stable.V3.With_top_version_tag.bin_write_t buf ~pos:0 x : int) ; + ignore (M3.Stable.V3.With_top_version_tag.bin_write_t buf ~pos:0 x : int); let y = M3.Stable.V3.With_top_version_tag.bin_read_t buf ~pos_ref:(ref 0) in - assert (M3.Stable.V3.equal x y) ; + assert (M3.Stable.V3.equal x y); let z = match M3.Stable.bin_read_top_tagged_to_latest buf ~pos_ref:(ref 0) with - | Ok n -> - n - | Error _ -> - assert false + | Ok n -> n + | Error _ -> assert false in assert (M3.Stable.V3.equal x z) @@ -131,7 +127,11 @@ module M4 = struct module V2 = struct [@@@with_all_version_tags] - type t = { a : int; b : Mina_stdlib.Bounded_types.String.Tagged.Stable.V1.t } [@@deriving equal] + type t = { + a : int; + b : Mina_stdlib.Bounded_types.String.Tagged.Stable.V1.t; + } + [@@deriving equal] let to_latest = Fn.id end @@ -139,7 +139,10 @@ module M4 = struct module V1 = struct [@@@with_all_version_tags] - type t = { a : Mina_stdlib.Bounded_types.String.Tagged.Stable.V1.t; b : int } + type t = { + a : Mina_stdlib.Bounded_types.String.Tagged.Stable.V1.t; + b : int; + } let to_latest ({ a; b } : t) : Latest.t = { a = b; b = a } end @@ -149,15 +152,13 @@ end let () = let x : M4.Stable.V2.t = { a = 42; b = "hello" } in let buf = Bigstring.create 20 in - ignore (M4.Stable.V2.With_all_version_tags.bin_write_t buf ~pos:0 x : int) ; + ignore (M4.Stable.V2.With_all_version_tags.bin_write_t buf ~pos:0 x : int); let y = M4.Stable.V2.With_all_version_tags.bin_read_t buf ~pos_ref:(ref 0) in - assert (M4.Stable.V2.equal x y) ; + assert (M4.Stable.V2.equal x y); let z = match M4.Stable.bin_read_all_tagged_to_latest buf ~pos_ref:(ref 0) with - | Ok n -> - n - | Error _ -> - assert false + | Ok n -> n + | Error _ -> assert false in assert (M4.Stable.V2.equal x z) @@ -188,11 +189,10 @@ module M6 = struct type nonrec t = t let to_binable = Fn.id - let of_binable = Fn.id end - include Binable.Of_binable_without_uuid (Core_kernel.Bool.Stable.V1) (Arg) + include Binable.Of_binable_without_uuid (Core.Bool.Stable.V1) (Arg) end end] end @@ -205,13 +205,9 @@ module M7 = struct type t = int let some = 1 - let other = 2 - let things = 3 - let (_ : int * int * int) = (some, other, things) - let to_latest = Fn.id module X = struct @@ -233,7 +229,7 @@ module M7 = struct (X) : sig type y = t - end ) + end) end end] diff --git a/src/lib/ppx_version/test/versioned_sig_good.ml b/src/lib/ppx_version/test/versioned_sig_good.ml index 2832dda470c0..906c23a08c5d 100644 --- a/src/lib/ppx_version/test/versioned_sig_good.ml +++ b/src/lib/ppx_version/test/versioned_sig_good.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Good = struct [%%versioned diff --git a/src/lib/ppx_version/test/versioned_sig_good.mli b/src/lib/ppx_version/test/versioned_sig_good.mli index 91f28060fb1b..24be333f9b35 100644 --- a/src/lib/ppx_version/test/versioned_sig_good.mli +++ b/src/lib/ppx_version/test/versioned_sig_good.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Good : sig [%%versioned: diff --git a/src/lib/ppx_version/versioned_module.ml b/src/lib/ppx_version/versioned_module.ml index a47a16c39f05..7718aae67f8b 100644 --- a/src/lib/ppx_version/versioned_module.ml +++ b/src/lib/ppx_version/versioned_module.ml @@ -1,6 +1,6 @@ (* versioned_module.ml -- modules with versioned types *) -open Core_kernel +open Core open Ppxlib open Versioned_util @@ -195,7 +195,7 @@ let rec add_deriving ~loc ~version_option attributes : attributes = | attr :: attributes -> ( let idents = Ast_pattern.( - attribute ~name:(string "deriving") ~payload:(single_expr_payload __)) + attribute ~name:(string "deriving") ~payload:(single_expr_payload __) ) in match parse_opt idents loc attr (fun l -> Some l) with | None -> @@ -603,7 +603,7 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag let mk_field fld e = Ast_builder.( pexp_field e - (Located.mk (Ldot (Ldot (Lident "Bin_prot", "Type_class"), fld)))) + (Located.mk (Ldot (Ldot (Lident "Bin_prot", "Type_class"), fld))) ) in let open Ast_builder in let yojson_tag_shadows = @@ -620,7 +620,7 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag if n = [%e eint version] then of_yojson data_json else Ppx_deriving_yojson_runtime.Result.Error - (Core_kernel.sprintf "In JSON, expected version %d, got %d" + (sprintf "In JSON, expected version %d, got %d" [%e eint version] n ) | _ -> Ppx_deriving_yojson_runtime.Result.Error @@ -679,12 +679,9 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag [%e apply_args [%expr bin_read_t_tagged]] buf ~pos_ref in (* sanity check *) - if - not - (Core_kernel.Int.equal read_version [%e eint version]) - then + if not (Int.equal read_version [%e eint version]) then failwith - (Core_kernel.sprintf + (sprintf "bin_read_t: version read %d does not match \ expected version %d" read_version [%e eint version] ) ; @@ -700,12 +697,9 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag buf ~pos_ref i in (* sanity check *) - if - not - (Core_kernel.Int.equal read_version [%e eint version]) - then + if not (Int.equal read_version [%e eint version]) then failwith - (Core_kernel.sprintf + (sprintf "__bin_read_t__: version read %d does not match \ expected version %d" read_version version ) ; @@ -939,7 +933,7 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag [%str let (_ : _) = let path = - Core_kernel.sprintf "%s:%s.%s" __FILE__ __FUNCTION__ + sprintf "%s:%s.%s" __FILE__ __FUNCTION__ [%e estring ty_decl.ptype_name.txt] in Ppx_version_runtime.Shapes.register path bin_shape_t @@ -955,7 +949,7 @@ let version_type ~version_option ~all_version_tagged ~top_version_tag (empty_params, [ t ], extra_stris) | Pstr_module ( { pmb_expr = { pmod_desc = Pmod_structure (stri :: str); _ } as pmod; _ } - as pmb ) -> + as pmb ) -> ( empty_params , [ { stri with pstr_desc = @@ -999,7 +993,7 @@ let convert_module_stri ~version_option ~top_version_tag ~json_version_tag last_version modl_stri = let module_pattern = Ast_pattern.( - pstr_module (module_binding ~name:(some __') ~expr:(pmod_structure __'))) + pstr_module (module_binding ~name:(some __') ~expr:(pmod_structure __')) ) in let loc = modl_stri.pstr_loc in let name, str = @@ -1080,9 +1074,9 @@ let convert_modbody ~loc ~version_option body = let _, rev_str, type_stri, top_tag_convs, all_tag_convs, json_tag_convs = List.fold ~init:(None, [], None, [], [], []) body_no_attrs ~f:(fun - (version, rev_str, type_stri, top_taggeds, all_taggeds, json_taggeds) - stri - -> + (version, rev_str, type_stri, top_taggeds, all_taggeds, json_taggeds) + stri + -> let version, stri, should_convert, current_type_stri, is_all_tagged = convert_module_stri ~version_option ~top_version_tag ~json_version_tag version stri @@ -1159,10 +1153,7 @@ let convert_modbody ~loc ~version_option body = values do not convert to [Latest.t]. *) let (top_tag_versions : - ( int - * ( Core_kernel.Bigstring.t - -> pos_ref:int ref - -> Latest.t ) ) + (int * (Bigstring.t -> pos_ref:int ref -> Latest.t)) array ) = [%e let open Ast_builder in @@ -1233,10 +1224,7 @@ let convert_modbody ~loc ~version_option body = values do not convert to [Latest.t]. *) let (all_tag_versions : - ( int - * ( Core_kernel.Bigstring.t - -> pos_ref:int ref - -> Latest.t ) ) + (int * (Bigstring.t -> pos_ref:int ref -> Latest.t)) array ) = [%e let open Ast_builder in @@ -1304,9 +1292,7 @@ let convert_modbody ~loc ~version_option body = let json_tag_versions = [%stri let (json_tag_versions : - ( int - * (Yojson.Safe.t -> Latest.t Core_kernel.Or_error.t) ) - array ) = + (int * (Yojson.Safe.t -> Latest.t Or_error.t)) array ) = [%e let open Ast_builder in pexp_array @@ -1351,7 +1337,7 @@ let convert_modbody ~loc ~version_option body = [%stri (** deserializes JSON to the latest module version's type *) let of_yojson_to_latest (json : Yojson.Safe.t) : - Latest.t Core_kernel.Or_error.t = + Latest.t Or_error.t = match json with | `Assoc [ ("version", `Int version); ("data", _) ] -> ( match @@ -1425,14 +1411,12 @@ let convert_rpc_version (stri : structure_item) = [%str let (_ : _) = let query_path = - Core_kernel.sprintf "%s:%s.%s" __FILE__ __FUNCTION__ - [%e estring "query"] + sprintf "%s:%s.%s" __FILE__ __FUNCTION__ [%e estring "query"] in Ppx_version_runtime.Shapes.register query_path bin_shape_query [%e estring query_ty_decl_str] ; let response_path = - Core_kernel.sprintf "%s:%s.%s" __FILE__ __FUNCTION__ - [%e estring "response"] + sprintf "%s:%s.%s" __FILE__ __FUNCTION__ [%e estring "response"] in Ppx_version_runtime.Shapes.register response_path bin_shape_response [%e estring response_ty_decl_str]] @@ -1460,16 +1444,16 @@ let convert_rpc_version (stri : structure_item) = match pmb_expr with | { pmod_desc = Pmod_structure - (( { pstr_desc = - Pstr_module - ( { pmb_name = { txt = Some "T"; _ } - ; pmb_expr = - { pmod_desc = Pmod_structure str_items; _ } as - inner_mod_expr - ; _ - } as inner_mod_binding ) - ; _ - } as inner_str_item ) + ( ( { pstr_desc = + Pstr_module + ( { pmb_name = { txt = Some "T"; _ } + ; pmb_expr = + { pmod_desc = Pmod_structure str_items; _ } as + inner_mod_expr + ; _ + } as inner_mod_binding ) + ; _ + } as inner_str_item ) :: other_mods ) ; _ } as mod_expr -> @@ -1801,7 +1785,7 @@ let version_module_decl ~loc ~path:_ modname signature = if json_version_tag then [ [%sigi: val of_yojson_to_latest : - Yojson.Safe.t -> Latest.t Core_kernel.Or_error.t] + Yojson.Safe.t -> Latest.t Or_error.t] ] else [] in @@ -1811,7 +1795,7 @@ let version_module_decl ~loc ~path:_ modname signature = val bin_read_top_tagged_to_latest : Bin_prot.Common.buf -> pos_ref:int ref - -> Latest.t Core_kernel.Or_error.t] + -> Latest.t Or_error.t] ] else [] in @@ -1821,7 +1805,7 @@ let version_module_decl ~loc ~path:_ modname signature = val bin_read_all_tagged_to_latest : Bin_prot.Common.buf -> pos_ref:int ref - -> Latest.t Core_kernel.Or_error.t] + -> Latest.t Or_error.t] ] else [] in @@ -1860,34 +1844,34 @@ let () = pstr ( pstr_module (module_binding ~name:(some __') ~expr:(pmod_structure __')) - ^:: nil )) + ^:: nil ) ) in let module_extension = Extension.( declare "versioned" Context.structure_item module_ast_pattern - (version_module ~version_option:No_version_option)) + (version_module ~version_option:No_version_option) ) in let module_extension_binable = Extension.( declare "versioned_binable" Context.structure_item module_ast_pattern - (version_module ~version_option:Binable)) + (version_module ~version_option:Binable) ) in let module_extension_rpc = Extension.( declare "versioned_rpc" Context.structure_item module_ast_pattern - version_rpc_module) + version_rpc_module ) in let module_decl_ast_pattern = Ast_pattern.( psig ( psig_module (module_declaration ~name:(some __') ~type_:(pmty_signature __')) - ^:: nil )) + ^:: nil ) ) in let module_decl_extension = Extension.( declare "versioned" Context.signature_item module_decl_ast_pattern - version_module_decl) + version_module_decl ) in let module_rule = Context_free.Rule.extension module_extension in let module_rule_binable = @@ -1900,10 +1884,10 @@ let () = in Driver.register_transformation "ppx_version/versioned_module" ~rules ; Ppxlib.Driver.add_arg "--no-toplevel-latest-type" - (Caml.Arg.Unit (fun () -> no_toplevel_latest_type := true)) + (Stdlib.Arg.Unit (fun () -> no_toplevel_latest_type := true)) ~doc:"Disable the toplevel type t declaration for versioned type modules" ; Ppxlib.Driver.add_arg "--toplevel-latest-type" - (Caml.Arg.Bool (fun b -> no_toplevel_latest_type := not b)) + (Stdlib.Arg.Bool (fun b -> no_toplevel_latest_type := not b)) ~doc: "Enable or disable the toplevel type t declaration for versioned type \ modules" diff --git a/src/lib/ppx_version/versioned_type.ml b/src/lib/ppx_version/versioned_type.ml index 3808c43d30c0..6ce72bebb301 100644 --- a/src/lib/ppx_version/versioned_type.ml +++ b/src/lib/ppx_version/versioned_type.ml @@ -1,6 +1,6 @@ (* versioned_types.ml -- deriver for versioned types *) -open Core_kernel +open Core open Ppxlib open Versioned_util @@ -105,7 +105,7 @@ let ocaml_builtin_types = let ocaml_builtin_type_constructors = [ "list"; "array"; "option"; "ref" ] -(* true iff module_path is of form M. ... .Stable.Vn, where M is Core or Core_kernel, and n is integer *) +(* true iff module_path is of form M. ... .Stable.Vn, where M is Core, and n is integer *) let is_jane_street_stable_module module_path = let hd_elt = List.hd_exn module_path in List.mem jane_street_modules hd_elt ~equal:String.equal @@ -163,7 +163,8 @@ let rec generate_core_type_version_decls type_name core_type = else if List.is_empty core_types && List.mem ocaml_builtin_types id ~equal:String.equal - then (* no versioning to worry about *) + then + (* no versioning to worry about *) [] else if List.mem ocaml_builtin_type_constructors id ~equal:String.equal diff --git a/src/lib/ppx_version/versioned_util.ml b/src/lib/ppx_version/versioned_util.ml index 06f2701afab2..c51507b1859b 100644 --- a/src/lib/ppx_version/versioned_util.ml +++ b/src/lib/ppx_version/versioned_util.ml @@ -1,6 +1,6 @@ (* version_util.ml -- utility functions for versioning *) -open Core_kernel +open Core open Ppxlib let parse_opt = Ast_pattern.parse ~on_error:(fun () -> None) @@ -61,16 +61,14 @@ let validate_module_version module_version loc = let version_of_versioned_module_name name = String.sub name ~pos:1 ~len:(String.length name - 1) |> int_of_string -(* modules in core and core_kernel library which are not in Core, Core_kernel modules +(* modules in core library which are not in Core modules see https://ocaml.janestreet.com/ocaml-core/latest/doc/core/index.html - https://ocaml.janestreet.com/ocaml-core/latest/doc/core_kernel/index.html add to this list as needed; but more items slows things down *) let jane_street_library_modules = [ "Uuid" ] -let jane_street_modules = - [ "Core"; "Core_kernel" ] @ jane_street_library_modules +let jane_street_modules = [ "Core" ] @ jane_street_library_modules From ffc13504574170230d95803b419ee91bd0733b44 Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 22:32:49 +0800 Subject: [PATCH 49/56] port mina-stdlib to 5.2.1 --- src/app/best_tip_merger/dune | 1 - src/lib/crypto/plonkish_prelude/dune | 1 - src/lib/mina_stdlib/bigstring.ml | 2 +- src/lib/mina_stdlib/bigstring.mli | 6 ++-- src/lib/mina_stdlib/bounded_types.ml | 18 +++++------ src/lib/mina_stdlib/deferred.ml | 6 ++-- src/lib/mina_stdlib/deferred.mli | 2 +- src/lib/mina_stdlib/direction.ml | 2 +- src/lib/mina_stdlib/dune | 9 +++--- src/lib/mina_stdlib/empty_hashes.ml | 22 +++++++------- src/lib/mina_stdlib/gadt.ml | 17 ++++++----- src/lib/mina_stdlib/gadt.mli | 6 ++-- src/lib/mina_stdlib/generic_set.mli | 1 + src/lib/mina_stdlib/graph_algorithms.ml | 14 ++++----- src/lib/mina_stdlib/list.ml | 14 ++++----- src/lib/mina_stdlib/list.mli | 2 +- src/lib/mina_stdlib/map_set.ml | 5 ++-- src/lib/mina_stdlib/map_set.mli | 5 +++- src/lib/mina_stdlib/nat.ml | 2 +- src/lib/mina_stdlib/nonempty_list.ml | 2 +- src/lib/mina_stdlib/result.ml | 2 +- src/lib/mina_stdlib/result.mli | 2 +- src/lib/mina_stdlib/rose_tree.ml | 2 +- src/lib/mina_stdlib/rose_tree.mli | 2 +- src/lib/mina_stdlib/state_or_error.ml | 2 +- src/lib/mina_stdlib/state_or_error_intf.ml | 2 +- .../tests/test_graph_algorithms.ml | 2 +- src/lib/mina_stdlib/tests/test_time.ml | 30 +++++++++---------- src/lib/mina_stdlib/time.ml | 10 +++---- src/lib/mina_stdlib/truth.ml | 2 -- src/lib/mina_stdlib/unix_timestamp.ml | 2 +- 31 files changed, 100 insertions(+), 95 deletions(-) diff --git a/src/app/best_tip_merger/dune b/src/app/best_tip_merger/dune index d97df795aa3f..35d637d19369 100644 --- a/src/app/best_tip_merger/dune +++ b/src/app/best_tip_merger/dune @@ -42,6 +42,5 @@ ppx_mina ppx_deriving.show ppx_deriving_yojson - ppx_jane ppx_version ppx_compare))) diff --git a/src/lib/crypto/plonkish_prelude/dune b/src/lib/crypto/plonkish_prelude/dune index 737332cfcbff..64d076a56dda 100644 --- a/src/lib/crypto/plonkish_prelude/dune +++ b/src/lib/crypto/plonkish_prelude/dune @@ -18,7 +18,6 @@ h_list.ppx ppx_deriving.std ppx_deriving_yojson - ppx_jane ppx_mina ppx_version)) (modules_without_implementation sigs poly_types) diff --git a/src/lib/mina_stdlib/bigstring.ml b/src/lib/mina_stdlib/bigstring.ml index 365a7d3abad5..31d10f58b902 100644 --- a/src/lib/mina_stdlib/bigstring.ml +++ b/src/lib/mina_stdlib/bigstring.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* add functions to library module Bigstring so we can derive hash for the type t below *) diff --git a/src/lib/mina_stdlib/bigstring.mli b/src/lib/mina_stdlib/bigstring.mli index c00117c9593e..1f1f24fe494b 100644 --- a/src/lib/mina_stdlib/bigstring.mli +++ b/src/lib/mina_stdlib/bigstring.mli @@ -1,7 +1,9 @@ +open Core + [%%versioned: module Stable : sig module V1 : sig - type t = Core_kernel.Bigstring.Stable.V1.t [@@deriving sexp, compare] + type t = Bigstring.Stable.V1.t [@@deriving sexp, compare] include Binable.S with type t := t @@ -17,7 +19,7 @@ val get : t -> int -> char val length : t -> int -val create : ?max_mem_waiting_gc:Core_kernel__Byte_units0.t -> int -> t +val create : int -> t val to_string : ?pos:int -> ?len:int -> t -> string diff --git a/src/lib/mina_stdlib/bounded_types.ml b/src/lib/mina_stdlib/bounded_types.ml index d4b9fabb0363..8b6bb86d4c2b 100644 --- a/src/lib/mina_stdlib/bounded_types.ml +++ b/src/lib/mina_stdlib/bounded_types.ml @@ -1,5 +1,5 @@ -open Core_kernel -open Core_kernel.Hash.Builtin +open Core +open Hash.Builtin module N16 = struct let max_array_len = 16 @@ -21,7 +21,7 @@ struct let hash_fold_t = hash_fold_array_frozen - [%%define_locally Core_kernel.Array.(compare, equal)] + [%%define_locally Array.(compare, equal)] let to_latest s = s @@ -66,7 +66,7 @@ module String = struct let to_latest s = s - [%%define_locally Core_kernel.String.(compare, equal)] + [%%define_locally String.(compare, equal)] let hash = hash_string @@ -141,20 +141,18 @@ end module Wrapped_error = struct module Stable = struct module V1 = struct - type t = Core_kernel.Error.Stable.V2.t [@@deriving sexp] + type t = Error.Stable.V2.t [@@deriving sexp] let __versioned__ = () - let to_latest = Core_kernel.Fn.id + let to_latest = Fn.id include String.Of_stringable (struct type nonrec t = t - let to_string (s : t) = - Core_kernel.Error.sexp_of_t s |> Core_kernel.Sexp.to_string_mach + let to_string (s : t) = Error.sexp_of_t s |> Sexp.to_string_mach - let of_string s = - Core_kernel.Error.t_of_sexp (Core_kernel.Sexp.of_string s) + let of_string s = Error.t_of_sexp (Sexp.of_string s) end) end end diff --git a/src/lib/mina_stdlib/deferred.ml b/src/lib/mina_stdlib/deferred.ml index 4ce824dd2edf..c4737ce42458 100644 --- a/src/lib/mina_stdlib/deferred.ml +++ b/src/lib/mina_stdlib/deferred.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel include ( @@ -34,7 +34,7 @@ module Result = struct open Deferred.Result.Let_syntax let fold ls ~init ~f = - Core_kernel.List.fold ls ~init:(return init) ~f:(fun acc x -> + Core.List.fold ls ~init:(return init) ~f:(fun acc x -> let%bind acc' = acc in f acc' x ) @@ -42,7 +42,7 @@ module Result = struct fold ls ~init:[] ~f:(fun acc x -> let%map x' = f x in x' :: acc ) - >>| Core_kernel.List.rev + >>| Core.List.rev let iter ls ~f = fold ls ~init:() ~f:(fun () -> f) end diff --git a/src/lib/mina_stdlib/deferred.mli b/src/lib/mina_stdlib/deferred.mli index 2c31f04c893e..d07325787b3a 100644 --- a/src/lib/mina_stdlib/deferred.mli +++ b/src/lib/mina_stdlib/deferred.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Async_kernel include module type of Deferred with module Result := Deferred.Result diff --git a/src/lib/mina_stdlib/direction.ml b/src/lib/mina_stdlib/direction.ml index 5421ab40f2d6..3986add96d02 100644 --- a/src/lib/mina_stdlib/direction.ml +++ b/src/lib/mina_stdlib/direction.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type t = Left | Right [@@deriving sexp, equal] diff --git a/src/lib/mina_stdlib/dune b/src/lib/mina_stdlib/dune index 4403e73d6fd6..1197ff2000b6 100644 --- a/src/lib/mina_stdlib/dune +++ b/src/lib/mina_stdlib/dune @@ -5,9 +5,7 @@ (flags -verbose -show-counts)) (modules_without_implementation generic_set sigs) (flags - (:standard -w a -warn-error +a) - -open - Core_kernel) + (:standard -w a -warn-error +a)) (libraries ; opam libraries async_kernel @@ -17,6 +15,7 @@ result sexplib0 stdlib + core ; local libraries ppx_version.runtime) (instrumentation @@ -26,8 +25,10 @@ ppx_compare ppx_deriving.std ppx_deriving_yojson + ppx_hash ppx_inline_test - ppx_jane + ppx_let + ppx_sexp_conv ppx_mina ppx_version)) (synopsis "Mina standard library")) diff --git a/src/lib/mina_stdlib/empty_hashes.ml b/src/lib/mina_stdlib/empty_hashes.ml index 810e7a040043..b17fcab52861 100644 --- a/src/lib/mina_stdlib/empty_hashes.ml +++ b/src/lib/mina_stdlib/empty_hashes.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module type Hash_intf = sig type t @@ -14,10 +14,10 @@ let cache hash_mod ~init_hash depth = let last_hash = ref init_hash in Immutable_array.of_array @@ Array.init (depth + 1) ~f:(fun i -> - if Int.equal i 0 then !last_hash - else ( - last_hash := merge_hash hash_mod (i - 1) !last_hash ; - !last_hash ) ) + if Int.equal i 0 then !last_hash + else ( + last_hash := merge_hash hash_mod (i - 1) !last_hash ; + !last_hash ) ) let extensible_cache hash_mod ~init_hash = let empty_hashes = ref [| init_hash |] in @@ -26,10 +26,10 @@ let extensible_cache hash_mod ~init_hash = let height = Array.length prev - 1 in let deficit = i - height in ( if deficit > 0 then - let last_hash = ref (Array.last prev) in - empty_hashes := - Array.append prev - (Array.init deficit ~f:(fun i -> - last_hash := merge_hash hash_mod (i + height) !last_hash ; - !last_hash ) ) ) ; + let last_hash = ref (Array.last prev) in + empty_hashes := + Array.append prev + (Array.init deficit ~f:(fun i -> + last_hash := merge_hash hash_mod (i + height) !last_hash ; + !last_hash ) ) ) ; !empty_hashes.(i) diff --git a/src/lib/mina_stdlib/gadt.ml b/src/lib/mina_stdlib/gadt.ml index 8ef95c95dc37..1a2af9430a6a 100644 --- a/src/lib/mina_stdlib/gadt.ml +++ b/src/lib/mina_stdlib/gadt.ml @@ -1,3 +1,5 @@ +open Core + module Peano = struct type zero = unit @@ -68,8 +70,8 @@ module Vect = struct let rec map : type n. f:('a -> 'b) -> ('a, n) t -> ('b, n) t = fun ~f ls -> match ls with [] -> [] | h :: t -> f h :: map ~f t - let rec map2 : - type n. f:('a -> 'b -> 'c) -> ('a, n) t -> ('b, n) t -> ('c, n) t = + let rec map2 : type n. + f:('a -> 'b -> 'c) -> ('a, n) t -> ('b, n) t -> ('c, n) t = fun ~f ls_a ls_b -> match (ls_a, ls_b) with | [], [] -> @@ -81,9 +83,8 @@ module Vect = struct fun ~init ~f ls -> match ls with [] -> init | h :: t -> fold ~init:(f init h) ~f t - let rec fold_map : - type n. init:'b -> f:('b -> 'a -> 'b * 'c) -> ('a, n) t -> 'b * ('c, n) t - = + let rec fold_map : type n. + init:'b -> f:('b -> 'a -> 'b * 'c) -> ('a, n) t -> 'b * ('c, n) t = fun ~init ~f ls -> match ls with | [] -> @@ -94,11 +95,11 @@ module Vect = struct (init'', h' :: t') module Quickcheck_generator = struct - open Core_kernel.Quickcheck + open Quickcheck open Generator.Let_syntax - let rec map : - type n. f:('a -> 'b Generator.t) -> ('a, n) t -> ('b, n) t Generator.t = + let rec map : type n. + f:('a -> 'b Generator.t) -> ('a, n) t -> ('b, n) t Generator.t = fun ~f ls -> match ls with | [] -> diff --git a/src/lib/mina_stdlib/gadt.mli b/src/lib/mina_stdlib/gadt.mli index 6fb158374e47..2871f94bbb49 100644 --- a/src/lib/mina_stdlib/gadt.mli +++ b/src/lib/mina_stdlib/gadt.mli @@ -1,3 +1,5 @@ +open Core + module Peano : sig type zero = unit @@ -68,8 +70,8 @@ module Vect : sig module Quickcheck_generator : sig val map : - f:('a -> 'b Core_kernel.Quickcheck.Generator.t) + f:('a -> 'b Quickcheck.Generator.t) -> ('a, 'n) t - -> ('b, 'n) t Core_kernel.Quickcheck.Generator.t + -> ('b, 'n) t Quickcheck.Generator.t end end diff --git a/src/lib/mina_stdlib/generic_set.mli b/src/lib/mina_stdlib/generic_set.mli index 978eddc453f2..db6f0df474fd 100644 --- a/src/lib/mina_stdlib/generic_set.mli +++ b/src/lib/mina_stdlib/generic_set.mli @@ -1,3 +1,4 @@ +open Core (** General interface of a Set *) module type S0 = sig type el diff --git a/src/lib/mina_stdlib/graph_algorithms.ml b/src/lib/mina_stdlib/graph_algorithms.ml index 040d3cb2170e..bb31ed197484 100644 --- a/src/lib/mina_stdlib/graph_algorithms.ml +++ b/src/lib/mina_stdlib/graph_algorithms.ml @@ -1,5 +1,5 @@ module Nat = Nat -open Core_kernel +open Core type 'a adjacency_list = ('a * 'a list) list @@ -60,12 +60,12 @@ module Make (V : Comparable.S) = struct let rec connectivity (g : G.t) : Nat.t = lazy ( if not (connected g) then Z - else - S - ( lazy - (Nat.min - (List.map (Map.keys g) ~f:(fun v -> - connectivity (remove_vertex g v) ) ) ) ) ) + else + S + ( lazy + (Nat.min + (List.map (Map.keys g) ~f:(fun v -> + connectivity (remove_vertex g v) ) ) ) ) ) end let connectivity (type a) (module V : Comparable.S with type t = a) diff --git a/src/lib/mina_stdlib/list.ml b/src/lib/mina_stdlib/list.ml index bb43094cbf98..8640c63d757c 100644 --- a/src/lib/mina_stdlib/list.ml +++ b/src/lib/mina_stdlib/list.ml @@ -1,20 +1,20 @@ -open Core_kernel +open Core include List module Length = struct type 'a t = ('a list, int) Sigs.predicate2 - let equal l len = Caml.List.compare_length_with l len = 0 + let equal l len = Stdlib.List.compare_length_with l len = 0 - let unequal l len = Caml.List.compare_length_with l len <> 0 + let unequal l len = Stdlib.List.compare_length_with l len <> 0 - let gte l len = Caml.List.compare_length_with l len >= 0 + let gte l len = Stdlib.List.compare_length_with l len >= 0 - let gt l len = Caml.List.compare_length_with l len > 0 + let gt l len = Stdlib.List.compare_length_with l len > 0 - let lte l len = Caml.List.compare_length_with l len <= 0 + let lte l len = Stdlib.List.compare_length_with l len <= 0 - let lt l len = Caml.List.compare_length_with l len < 0 + let lt l len = Stdlib.List.compare_length_with l len < 0 module Compare = struct let ( = ) = equal diff --git a/src/lib/mina_stdlib/list.mli b/src/lib/mina_stdlib/list.mli index c2091eab1ceb..0febb3a1310b 100644 --- a/src/lib/mina_stdlib/list.mli +++ b/src/lib/mina_stdlib/list.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core include module type of List diff --git a/src/lib/mina_stdlib/map_set.ml b/src/lib/mina_stdlib/map_set.ml index e834a7669ffe..af446d4c1fa3 100644 --- a/src/lib/mina_stdlib/map_set.ml +++ b/src/lib/mina_stdlib/map_set.ml @@ -1,6 +1,6 @@ (** Utilities for dealing with "multimaps" or mapsets. *) -open Core_kernel +open Core (* TODO consider using a lighter interface than Comparable.S *) module Make (Key : Comparable.S) (Set : Generic_set.S0) = struct @@ -25,7 +25,8 @@ module Make (Key : Comparable.S) (Set : Generic_set.S0) = struct end module Make_with_sexp_of - (Key : Comparable.S) (Set : sig + (Key : Comparable.S) + (Set : sig include Generic_set.S0 val sexp_of_t : t -> Sexp.t diff --git a/src/lib/mina_stdlib/map_set.mli b/src/lib/mina_stdlib/map_set.mli index 3a33e9c57156..765127b18760 100644 --- a/src/lib/mina_stdlib/map_set.mli +++ b/src/lib/mina_stdlib/map_set.mli @@ -1,3 +1,5 @@ +open Core + module Make (Key : Comparable.S) (Set : Generic_set.S0) : sig type t = Set.t Key.Map.t [@@deriving equal] @@ -7,7 +9,8 @@ module Make (Key : Comparable.S) (Set : Generic_set.S0) : sig end module Make_with_sexp_of - (Key : Comparable.S) (Set : sig + (Key : Comparable.S) + (Set : sig include Generic_set.S0 val sexp_of_t : t -> Sexp.t diff --git a/src/lib/mina_stdlib/nat.ml b/src/lib/mina_stdlib/nat.ml index 9751f196fde6..6b721e9e9ea1 100644 --- a/src/lib/mina_stdlib/nat.ml +++ b/src/lib/mina_stdlib/nat.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type tt = Z | S of t diff --git a/src/lib/mina_stdlib/nonempty_list.ml b/src/lib/mina_stdlib/nonempty_list.ml index 7ce5f8dc1fd6..1e0f26c06d05 100644 --- a/src/lib/mina_stdlib/nonempty_list.ml +++ b/src/lib/mina_stdlib/nonempty_list.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (* A non-empty list is a tuple of the head and the rest (as a list) *) [%%versioned diff --git a/src/lib/mina_stdlib/result.ml b/src/lib/mina_stdlib/result.ml index 37dbdc10746c..c0ab6d36dcd3 100644 --- a/src/lib/mina_stdlib/result.ml +++ b/src/lib/mina_stdlib/result.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core include Result open Let_syntax diff --git a/src/lib/mina_stdlib/result.mli b/src/lib/mina_stdlib/result.mli index 63a15c00c5f7..d35fa4cddbeb 100644 --- a/src/lib/mina_stdlib/result.mli +++ b/src/lib/mina_stdlib/result.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core include module type of Result diff --git a/src/lib/mina_stdlib/rose_tree.ml b/src/lib/mina_stdlib/rose_tree.ml index ec35391ac414..a944a10960b6 100644 --- a/src/lib/mina_stdlib/rose_tree.ml +++ b/src/lib/mina_stdlib/rose_tree.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type 'a t = T of 'a * 'a t list diff --git a/src/lib/mina_stdlib/rose_tree.mli b/src/lib/mina_stdlib/rose_tree.mli index a26369154835..4d5f9db2efd8 100644 --- a/src/lib/mina_stdlib/rose_tree.mli +++ b/src/lib/mina_stdlib/rose_tree.mli @@ -5,7 +5,7 @@ * @see Wikipedia Article *) -open Core_kernel +open Core open Async_kernel type 'a t = T of 'a * 'a t list [@@deriving yojson] diff --git a/src/lib/mina_stdlib/state_or_error.ml b/src/lib/mina_stdlib/state_or_error.ml index 197aa6bd7805..6f9af826074b 100644 --- a/src/lib/mina_stdlib/state_or_error.ml +++ b/src/lib/mina_stdlib/state_or_error.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Make3 (State : State_or_error_intf.State_intf2) : State_or_error_intf.S3 with type ('a, 'b) state = ('a, 'b) State.t = struct diff --git a/src/lib/mina_stdlib/state_or_error_intf.ml b/src/lib/mina_stdlib/state_or_error_intf.ml index c94b2969506e..b0530ed68538 100644 --- a/src/lib/mina_stdlib/state_or_error_intf.ml +++ b/src/lib/mina_stdlib/state_or_error_intf.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (*State monad with or_error (a monad of type (state -> (a * state) Or_error.t)) *) module type State_intf = sig diff --git a/src/lib/mina_stdlib/tests/test_graph_algorithms.ml b/src/lib/mina_stdlib/tests/test_graph_algorithms.ml index ea8c8225af40..627e5042b44b 100644 --- a/src/lib/mina_stdlib/tests/test_graph_algorithms.ml +++ b/src/lib/mina_stdlib/tests/test_graph_algorithms.ml @@ -5,7 +5,7 @@ Subject: Graph algorithms tests *) -open Core_kernel +open Core let test_tree_connectivity () = (* diff --git a/src/lib/mina_stdlib/tests/test_time.ml b/src/lib/mina_stdlib/tests/test_time.ml index 57553e21cf90..9e4f1393275f 100644 --- a/src/lib/mina_stdlib/tests/test_time.ml +++ b/src/lib/mina_stdlib/tests/test_time.ml @@ -5,95 +5,95 @@ Subject: Test JSON roundtrip for Time.Span.Stable.V1 *) -open Core_kernel +open Core module SpanV1 = Mina_stdlib.Time.Span.Stable.V1 (* Test that basic JSON serialization roundtrip works *) let test_basic_json_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 42.0 in + let span = Time_float.Span.of_sec 42.0 in let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Roundtrip equality" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test zero span roundtrip *) let test_zero_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 0.0 in + let span = Time_float.Span.of_sec 0.0 in let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Zero span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test positive span roundtrip *) let test_positive_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 86400.0 in + let span = Time_float.Span.of_sec 86400.0 in (* One day *) let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Positive span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test negative span roundtrip *) let test_negative_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec (-3600.0) in + let span = Time_float.Span.of_sec (-3600.0) in (* Negative one hour *) let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Negative span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test fraction span roundtrip *) let test_fraction_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 0.001 in + let span = Time_float.Span.of_sec 0.001 in (* 1 millisecond *) let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Fraction span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test very small span roundtrip *) let test_very_small_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 1e-6 in + let span = Time_float.Span.of_sec 1e-6 in (* 1 microsecond *) let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Very small span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) (* Test large span roundtrip *) let test_large_span_roundtrip () = - let span = Core_kernel.Time.Span.of_sec 31536000.0 in + let span = Time_float.Span.of_sec 31536000.0 in (* 1 year *) let json = SpanV1.to_yojson span in match SpanV1.of_yojson json with | Ok decoded -> Alcotest.(check bool) "Large span roundtrip" true - (Core_kernel.Time.Span.equal span decoded) + (Time_float.Span.equal span decoded) | Error msg -> Alcotest.fail ("JSON parsing failed: " ^ msg) diff --git a/src/lib/mina_stdlib/time.ml b/src/lib/mina_stdlib/time.ml index 41b3f640a930..12f51a26ecdb 100644 --- a/src/lib/mina_stdlib/time.ml +++ b/src/lib/mina_stdlib/time.ml @@ -1,15 +1,15 @@ -open Core_kernel -include Core_kernel.Time +open Core +include Core.Time module Span = struct [%%versioned module Stable = struct module V1 = struct (* NOTE: - `Core_kernel.Time.Stable.Span.V3.t` tracks time in seconds in an IEEE754 + `Core.Time.Stable.Span.V3.t` tracks time in seconds in an IEEE754 64bit float. Hence conversion to/from float poses no precision lost. *) - type t = Core_kernel.Time.Stable.Span.V3.t [@@deriving sexp] + type t = Core.Time.Stable.Span.V3.t [@@deriving sexp] let to_yojson_hum span = `String (Printf.sprintf "%f seconds" (Time.Span.to_sec span)) @@ -28,5 +28,5 @@ module Span = struct [%%define_locally Stable.Latest.(to_yojson_hum, to_yojson, of_yojson)] - include Core_kernel.Time.Span + include Core.Time.Span end diff --git a/src/lib/mina_stdlib/truth.ml b/src/lib/mina_stdlib/truth.ml index 46f72851f3ce..a15c213e2645 100644 --- a/src/lib/mina_stdlib/truth.ml +++ b/src/lib/mina_stdlib/truth.ml @@ -1,5 +1,3 @@ -include Core_kernel - module True = struct type t = True end diff --git a/src/lib/mina_stdlib/unix_timestamp.ml b/src/lib/mina_stdlib/unix_timestamp.ml index 347297de457c..969c23965af1 100644 --- a/src/lib/mina_stdlib/unix_timestamp.ml +++ b/src/lib/mina_stdlib/unix_timestamp.ml @@ -1 +1 @@ -include Core_kernel.Int64 +include Core.Int64 From a9d0a39f71e06245febb29a1e26765d6615fed47 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 17:16:33 +0800 Subject: [PATCH 50/56] port network_peer -> 5.2.1 --- src/lib/network_peer/dune | 2 +- src/lib/network_peer/envelope.ml | 18 ++++++++--------- src/lib/network_peer/envelope.mli | 4 ++-- src/lib/network_peer/peer.ml | 32 +++++++++++++++++-------------- 4 files changed, 30 insertions(+), 26 deletions(-) diff --git a/src/lib/network_peer/dune b/src/lib/network_peer/dune index b9018b013fbf..66a6cc4ff19c 100644 --- a/src/lib/network_peer/dune +++ b/src/lib/network_peer/dune @@ -18,4 +18,4 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_compare ppx_mina ppx_version ppx_jane ppx_deriving_yojson))) + (pps ppx_compare ppx_let ppx_fields_conv ppx_hash ppx_mina ppx_sexp_conv ppx_version ppx_deriving_yojson))) diff --git a/src/lib/network_peer/envelope.ml b/src/lib/network_peer/envelope.ml index dd80ec3e3944..fea1f829920a 100644 --- a/src/lib/network_peer/envelope.ml +++ b/src/lib/network_peer/envelope.ml @@ -38,7 +38,7 @@ module Sender = struct Quickcheck.Generator.( variant2 (list_with_length 4 (Int.gen_incl 0 255)) - (list_with_length 8 (Int.gen_incl 0 65535))) + (list_with_length 8 (Int.gen_incl 0 65535)) ) with | `A octets -> String.concat ~sep:"." (List.map ~f:Int.to_string octets) @@ -46,7 +46,7 @@ module Sender = struct String.concat ~sep:":" (List.map ~f:(Printf.sprintf "%x") segments) in let remote = - let inet = Unix.Inet_addr.of_string ip in + let inet = Core_unix.Inet_addr.of_string ip in let%bind peer_id = String.gen_nonempty in let%map libp2p_port = Int.gen_uniform_incl 1025 49151 in Peer.create inet ~peer_id ~libp2p_port @@ -59,18 +59,18 @@ module Sender = struct end module Incoming = struct - let time_to_yojson tm = `String (Time.to_string tm) + let time_to_yojson tm = `String (Time_float_unix.to_string_utc tm) let time_of_yojson = function | `String s -> - Ok (Time.of_string s) + Ok (Time_float_unix.of_string_with_utc_offset s) | _ -> Error "time_of_yojson: Expected string" type 'a t = { data : 'a ; sender : Sender.t - ; received_at : Time.t + ; received_at : Time_float_unix.t [@to_yojson time_to_yojson] [@of_yojson time_of_yojson] } [@@deriving equal, sexp, yojson, compare] @@ -82,11 +82,11 @@ module Incoming = struct let received_at t = t.received_at let wrap ~data ~sender = - let received_at = Time.now () in + let received_at = Time_float_unix.now () in { data; sender; received_at } let wrap_peer ~data ~sender = - let received_at = Time.now () in + let received_at = Time_float_unix.now () in { data; sender = Sender.of_peer sender; received_at } let map ~f t = { t with data = f t.data } @@ -97,7 +97,7 @@ module Incoming = struct { t with data } let local data = - let received_at = Time.now () in + let received_at = Time_float_unix.now () in let sender = Sender.Local in { data; sender; received_at } @@ -112,6 +112,6 @@ module Incoming = struct let open Quickcheck.Generator.Let_syntax in let%bind data = gen_a in let%map sender = Sender.gen in - let received_at = Time.now () in + let received_at = Time_float_unix.now () in { data; sender; received_at } end diff --git a/src/lib/network_peer/envelope.mli b/src/lib/network_peer/envelope.mli index 95c20548447a..3364a74b4ad4 100644 --- a/src/lib/network_peer/envelope.mli +++ b/src/lib/network_peer/envelope.mli @@ -7,14 +7,14 @@ module Sender : sig end module Incoming : sig - type 'a t = { data : 'a; sender : Sender.t; received_at : Time.t } + type 'a t = { data : 'a; sender : Sender.t; received_at : Time_float.t } [@@deriving equal, sexp, yojson, compare] val sender : 'a t -> Sender.t val data : 'a t -> 'a - val received_at : 'a t -> Time.t + val received_at : 'a t -> Time_float.t val wrap : data:'a -> sender:Sender.t -> 'a t diff --git a/src/lib/network_peer/peer.ml b/src/lib/network_peer/peer.ml index c1634472f9da..f3d2393bd507 100644 --- a/src/lib/network_peer/peer.ml +++ b/src/lib/network_peer/peer.ml @@ -1,6 +1,7 @@ (* peer.ml -- peer with libp2p port and peer id *) open Core +open Core_unix (** A libp2p PeerID is more or less a hash of a public key. *) module Id = struct @@ -25,23 +26,27 @@ module Inet_addr = struct [%%versioned_binable module Stable = struct module V1 = struct - type t = Unix.Inet_addr.t [@@deriving sexp, compare, hash] + type t = Inet_addr.t [@@deriving sexp, compare, hash] let to_latest = Fn.id let of_yojson = function | `String s -> - Ok (Unix.Inet_addr.of_string s) + Ok (Inet_addr.of_string s) | _ -> Error "expected string" - let to_yojson ip_addr = `String (Unix.Inet_addr.to_string ip_addr) + let to_yojson ip_addr = `String (Inet_addr.to_string ip_addr) include Mina_stdlib.Bounded_types.String.Of_stringable (struct type nonrec t = t - [%%define_locally Unix.Inet_addr.(to_string, of_string)] + [%%define_locally Inet_addr.(to_string, of_string)] end) + + let to_string = Inet_addr.to_string + + let of_string = Inet_addr.of_string end end] @@ -72,7 +77,7 @@ module Stable = struct let to_yojson { host; peer_id; libp2p_port } = `Assoc - [ ("host", `String (Unix.Inet_addr.to_string host)) + [ ("host", Inet_addr.to_yojson host) ; ("peer_id", `String peer_id) ; ("libp2p_port", `Int libp2p_port) ] @@ -93,7 +98,7 @@ module Stable = struct let%map libp2p_port = List.Assoc.find ls "libp2p_port" ~equal:String.equal >>= lift_int in - let host = Unix.Inet_addr.of_string host_str in + let host = Core_unix.Inet_addr.of_string host_str in { host; peer_id; libp2p_port } ) | _ -> Error "expected object" @@ -101,7 +106,7 @@ module Stable = struct end] type t = Stable.Latest.t = - { host : Unix.Inet_addr.Blocking_sexp.t; libp2p_port : int; peer_id : string } + { host : Inet_addr.t; libp2p_port : int; peer_id : string } [@@deriving compare, sexp] [%%define_locally Stable.Latest.(of_yojson, to_yojson)] @@ -113,19 +118,18 @@ let create host ~libp2p_port ~peer_id = { host; libp2p_port; peer_id } let to_discovery_host_and_port t = Host_and_port.create - ~host:(Unix.Inet_addr.to_string t.host) + ~host:(Core_unix.Inet_addr.to_string t.host) ~port:t.libp2p_port let to_string { host; libp2p_port; peer_id } = - sprintf - !"[host : %s, libp2p_port : %s, peer_id : %s]" - (Unix.Inet_addr.to_string host) + sprintf "[host : %s, libp2p_port : %s, peer_id : %s]" + (Inet_addr.Stable.Latest.to_string host) (Int.to_string libp2p_port) peer_id let to_multiaddr_string { host; libp2p_port; peer_id } = sprintf "/ip4/%s/tcp/%d/p2p/%s" - (Unix.Inet_addr.to_string host) + (Inet_addr.Stable.Latest.to_string host) libp2p_port peer_id let pretty_list peers = String.concat ~sep:"," @@ List.map peers ~f:to_string @@ -165,13 +169,13 @@ let ip { host; _ } = host let to_display { host; libp2p_port; peer_id } = Display. - { host = Unix.Inet_addr.to_string host + { host = Inet_addr.Stable.Latest.to_string host ; libp2p_port ; peer_id = Id.to_string peer_id } let of_display { Display.host; libp2p_port; peer_id } = - { host = Unix.Inet_addr.of_string host + { host = Inet_addr.Stable.Latest.of_string host ; libp2p_port ; peer_id = Id.unsafe_of_string peer_id } From 979a55cd0e7be00238304a83dc7155fe3e0a47cf Mon Sep 17 00:00:00 2001 From: glyh Date: Sat, 29 Nov 2025 21:38:36 +0800 Subject: [PATCH 51/56] patch lib/logproc_lib for 5.2.1 --- src/lib/logproc_lib/dune | 4 ++-- src/lib/logproc_lib/filter.ml | 9 ++++++--- src/lib/logproc_lib/interpolator.ml | 8 ++++---- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/src/lib/logproc_lib/dune b/src/lib/logproc_lib/dune index e6ee38b1a06c..c28fa4f3c449 100644 --- a/src/lib/logproc_lib/dune +++ b/src/lib/logproc_lib/dune @@ -29,8 +29,8 @@ ;; opam libraries yojson angstrom - ;; local libraries - ) + core) + (instrumentation (backend bisect_ppx)) (preprocess diff --git a/src/lib/logproc_lib/filter.ml b/src/lib/logproc_lib/filter.ml index 1ac4ef06b60e..60378376bfc5 100644 --- a/src/lib/logproc_lib/filter.ml +++ b/src/lib/logproc_lib/filter.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Ast = struct type value = Bool of bool | String of string | Int of int @@ -210,7 +210,10 @@ module Parser = struct >>| String.concat ~sep:"" in char '/' *> commit *> inner - <* commit >>| (* TODO: handle gracefully *) Re2.create_exn + <* commit + >>| + (* TODO: handle gracefully *) + Re2.create_exn in lift2 (fun value f -> f value) @@ -310,7 +313,7 @@ module Interpreter = struct |> Option.value ~default:false | Cmp_neq (x, y) -> Option.map2 (interpret_value_exp json x) (interpret_value_exp json y) - ~f:(fun json1 json2 -> not (Yojson.Safe.equal json1 json2)) + ~f:(fun json1 json2 -> not (Yojson.Safe.equal json1 json2) ) |> Option.value ~default:false | Cmp_in (x, y) -> Option.map2 (interpret_value_exp json x) (interpret_value_exp json y) diff --git a/src/lib/logproc_lib/interpolator.ml b/src/lib/logproc_lib/interpolator.ml index 528fd86441ca..03735001ba2f 100644 --- a/src/lib/logproc_lib/interpolator.ml +++ b/src/lib/logproc_lib/interpolator.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core type mode = Hidden | Inline | After @@ -54,7 +54,7 @@ let render ~max_interpolation_length ~format_json metadata items = Ok (msg_acc ^ str, extra_acc) | `Interpolate id -> let%map json = - String.Map.find metadata id + Map.find metadata id |> Result.of_option ~error:(sprintf "bad interpolation for %s" id) in let str = format_json json in @@ -68,7 +68,7 @@ let interpolate { mode; max_interpolation_length; pretty_print } msg metadata = let open Result.Let_syntax in let format_json = if pretty_print then Yojson.Safe.pretty_to_string - else Yojson.Safe.to_string ?buf:None ?len:None + else Yojson.Safe.to_string ?buf:None ?len:None ?suf:None in match mode with | Hidden -> @@ -79,5 +79,5 @@ let interpolate { mode; max_interpolation_length; pretty_print } msg metadata = | After -> Ok ( msg - , List.map (String.Map.to_alist metadata) ~f:(fun (k, v) -> + , List.map (Map.to_alist metadata) ~f:(fun (k, v) -> (k, format_json v) ) ) From 2b3f54ae55d4e099e2b18fba470ec4b04280d5c4 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 17:24:57 +0800 Subject: [PATCH 52/56] port perf_histograms to 5.2.1 --- src/lib/perf_histograms/histogram.ml | 34 +++++++++++---------- src/lib/perf_histograms/perf_histograms.mli | 6 ++-- src/lib/perf_histograms/perf_histograms0.ml | 9 +++--- src/lib/perf_histograms/rpc.ml | 13 ++++---- 4 files changed, 32 insertions(+), 30 deletions(-) diff --git a/src/lib/perf_histograms/histogram.ml b/src/lib/perf_histograms/histogram.ml index b59593b23887..629c581ecf83 100644 --- a/src/lib/perf_histograms/histogram.ml +++ b/src/lib/perf_histograms/histogram.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** Loosely modelled on https://chromium.googlesource.com/chromium/src/+/HEAD/tools/metrics/histograms/README.md *) @@ -71,15 +71,15 @@ end module Exp_time_spans = Make (struct (** Note: All time spans are represented in JSON as floating point millis *) - type t = Time.Span.t [@@deriving bin_io_unversioned] + type t = Time_float.Span.t [@@deriving bin_io_unversioned] - let to_yojson t = `Float (Time.Span.to_ms t) + let to_yojson t = `Float (Time_float.Span.to_ms t) let of_yojson t = let open Ppx_deriving_yojson_runtime in match t with | `Float ms -> - Result.Ok (Time.Span.of_ms ms) + Result.Ok (Time_float.Span.of_ms ms) | _ -> Result.Error "Not a floating point milliseconds value" @@ -92,8 +92,8 @@ module Exp_time_spans = Make (struct (* See http://mathworld.wolfram.com/LeastSquaresFittingLogarithmic.html *) let fit min max buckets = - let x0, y0 = (Time.Span.to_ms min, Float.zero) in - let x1, y1 = (Time.Span.to_ms max, Float.of_int buckets) in + let x0, y0 = (Time_float.Span.to_ms min, Float.zero) in + let x1, y1 = (Time_float.Span.to_ms max, Float.of_int buckets) in let n = 2.0 in let sum f = f (x0, y0) +. f (x1, y1) in let b = @@ -126,8 +126,8 @@ module Exp_time_spans = Make (struct in (a, b) - let create ?(min = Time.Span.of_sec 1.) ?(max = Time.Span.of_min 10.) - ?(buckets = 50) () = + let create ?(min = Time_float.Span.of_sec 1.) + ?(max = Time_float.Span.of_min 10.) ?(buckets = 50) () = let a, b = fit min max buckets in { a; b; buckets } end @@ -138,10 +138,10 @@ module Exp_time_spans = Make (struct let y = Float.of_int y in Float.exp ((y /. b) -. (a /. b)) in - (Time.Span.of_ms (f_1 i), Time.Span.of_ms (f_1 (i + 1))) + (Time_float.Span.of_ms (f_1 i), Time_float.Span.of_ms (f_1 (i + 1))) let bucket ~params:{ Params.a; b; buckets } span = - let x = Time.Span.to_ms span in + let x = Time_float.Span.to_ms span in if Float.( <= ) x 0.0 then `Underflow else (* y = a + b log(x) *) @@ -154,19 +154,21 @@ end) let%test_unit "reports properly with overflows and underflows and table hits" = let open Exp_time_spans in let tbl = - create ~buckets:50 ~min:(Time.Span.of_ms 1.) ~max:(Time.Span.of_day 1.) () + create ~buckets:50 ~min:(Time_float.Span.of_ms 1.) + ~max:(Time_float.Span.of_day 1.) + () in let r = report tbl in assert (r.Pretty.underflow = 0) ; assert (r.Pretty.overflow = 0) ; (* underflow *) - add tbl (Time.Span.of_us 100.) ; + add tbl (Time_float.Span.of_us 100.) ; (* in the table *) - add tbl (Time.Span.of_ms 100.) ; - add tbl (Time.Span.of_sec 100.) ; - add tbl (Time.Span.of_day 0.5) ; + add tbl (Time_float.Span.of_ms 100.) ; + add tbl (Time_float.Span.of_sec 100.) ; + add tbl (Time_float.Span.of_day 0.5) ; (* overflow *) - add tbl (Time.Span.of_day 2.) ; + add tbl (Time_float.Span.of_day 2.) ; let r = report tbl in assert (List.sum ~f:Fn.id (module Int) r.Pretty.values = 3) ; assert (r.Pretty.underflow = 1) ; diff --git a/src/lib/perf_histograms/perf_histograms.mli b/src/lib/perf_histograms/perf_histograms.mli index 578644b68dd8..a3e9b5f4dd1c 100644 --- a/src/lib/perf_histograms/perf_histograms.mli +++ b/src/lib/perf_histograms/perf_histograms.mli @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Rpc : sig module Plain : sig @@ -18,14 +18,14 @@ end module Report : sig type t = { values : int list - ; intervals : (Time.Span.t * Time.Span.t) list + ; intervals : (Time_float.Span.t * Time_float.Span.t) list ; underflow : int ; overflow : int } [@@deriving yojson, bin_io, fields] end -val add_span : name:string -> Time.Span.t -> unit +val add_span : name:string -> Time_float.Span.t -> unit val report : name:string -> Report.t option diff --git a/src/lib/perf_histograms/perf_histograms0.ml b/src/lib/perf_histograms/perf_histograms0.ml index 24682f05549a..0e18dd3d108b 100644 --- a/src/lib/perf_histograms/perf_histograms0.ml +++ b/src/lib/perf_histograms/perf_histograms0.ml @@ -1,18 +1,17 @@ -open Core_kernel +open Core (* For now, we'll just support Exp_time_spans histogram *) let t : Histogram.Exp_time_spans.t String.Table.t = String.Table.create () let add_span ~name s = let hist = - String.Table.find_or_add t name ~default:Histogram.Exp_time_spans.create + Hashtbl.find_or_add t name ~default:Histogram.Exp_time_spans.create in Histogram.Exp_time_spans.add hist s let report ~name = - String.Table.find_and_call t name + Hashtbl.find_and_call t name ~if_found:(fun tbl -> Some (Histogram.Exp_time_spans.report tbl)) ~if_not_found:(fun _ -> None) -let wipe () = - String.Table.iter t ~f:(fun tbl -> Histogram.Exp_time_spans.clear tbl) +let wipe () = Hashtbl.iter t ~f:(fun tbl -> Histogram.Exp_time_spans.clear tbl) diff --git a/src/lib/perf_histograms/rpc.ml b/src/lib/perf_histograms/rpc.ml index 66cb0bf084a1..a666e65cae02 100644 --- a/src/lib/perf_histograms/rpc.ml +++ b/src/lib/perf_histograms/rpc.ml @@ -5,25 +5,26 @@ let decorate_dispatch ~name (dispatch : ('q, 'r) Intf.dispatch) : ('q, 'r) Intf.dispatch = fun conn q -> let open Deferred.Or_error.Let_syntax in - let start = Time.now () in + let start = Time_float.now () in let%map r = dispatch conn q in - let span = Time.diff (Time.now ()) start in + let span = Time_float.diff (Time_float.now ()) start in Perf_histograms0.add_span ~name:(sprintf "rpc_dispatch_%s" name) span ; Mina_metrics.( Network.Rpc_latency_histogram.observe Network.rpc_latency_ms_summary - (Time.Span.to_ms span)) ; - Mina_metrics.(Gauge.set (Network.rpc_latency_ms ~name) (Time.Span.to_ms span)) ; + (Time_float.Span.to_ms span) ) ; + Mina_metrics.( + Gauge.set (Network.rpc_latency_ms ~name) (Time_float.Span.to_ms span) ) ; r let decorate_impl ~name (impl : ('q, 'r, 'state) Intf.impl) : ('q, 'r, 'state) Intf.impl = fun state ~version q -> let open Deferred.Let_syntax in - let start = Time.now () in + let start = Time_float.now () in let%map r = impl state ~version q in Perf_histograms0.add_span ~name:(sprintf "rpc_impl_%s" name) - (Time.diff (Time.now ()) start) ; + (Time_float.diff (Time_float.now ()) start) ; r module Plain = struct From b3986548ead1d422fc3d16d192006587794080a6 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 17:27:23 +0800 Subject: [PATCH 53/56] port allocation funtor to 5.2.1 --- src/lib/allocation_functor/intf.ml | 2 +- src/lib/allocation_functor/make.ml | 2 +- src/lib/allocation_functor/table.ml | 34 +++++++++++++++-------------- 3 files changed, 20 insertions(+), 18 deletions(-) diff --git a/src/lib/allocation_functor/intf.ml b/src/lib/allocation_functor/intf.ml index e719b38489ae..a4b61a4e0a55 100644 --- a/src/lib/allocation_functor/intf.ml +++ b/src/lib/allocation_functor/intf.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Partial = struct module type Bin_io_intf = Binable.S diff --git a/src/lib/allocation_functor/make.ml b/src/lib/allocation_functor/make.ml index ba9e54f097d8..34f38607132f 100644 --- a/src/lib/allocation_functor/make.ml +++ b/src/lib/allocation_functor/make.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Partial = struct module Bin_io (M : Intf.Input.Bin_io_intf) : diff --git a/src/lib/allocation_functor/table.ml b/src/lib/allocation_functor/table.ml index 20ad8ee0fd9a..a218cb750f62 100644 --- a/src/lib/allocation_functor/table.ml +++ b/src/lib/allocation_functor/table.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core (** immutable, serializable statistics derived from allocation data *) module Allocation_statistics = struct @@ -33,7 +33,7 @@ module Allocation_data = struct (* indexed queue data structure would be more effecient here, but keeping this simple for now *) type t = - { allocation_times : (allocation_id * Time.t) Queue.t + { allocation_times : (allocation_id * Time_float.t) Queue.t ; mutable next_allocation_id : allocation_id } @@ -44,7 +44,7 @@ module Allocation_data = struct let register_allocation data = let id = data.next_allocation_id in - Queue.enqueue data.allocation_times (id, Time.now ()) ; + Queue.enqueue data.allocation_times (id, Time_float.now ()) ; data.next_allocation_id <- data.next_allocation_id + 1 ; id @@ -53,9 +53,11 @@ module Allocation_data = struct Queue.filter_inplace data.allocation_times ~f:(fun (id', _) -> id = id') let compute_statistics { allocation_times; _ } = - let now = Time.now () in + let now = Time_float.now () in let count = Queue.length allocation_times in - let lifetime_ms_of_time time = Time.Span.to_ms (Time.diff now time) in + let lifetime_ms_of_time time = + Time_float.Span.to_ms (Time_float.diff now time) + in let get_lifetime_ms i = lifetime_ms_of_time (snd @@ Queue.get allocation_times i) in @@ -109,13 +111,13 @@ module Allocation_data = struct (* time_offsets passed in here should be ordered monotonically (to match real world behavior) *) let run_test time_offsets expected_quartiles = - let now = Time.now () in + let now = Time_float.now () in (* ids do not need to be unique in this test *) let data = { allocation_times = Queue.of_list @@ List.map (List.rev time_offsets) ~f:(fun offset -> - (0, Time.sub now (Time.Span.of_ms offset)) ) + (0, Time_float.sub now (Time_float.Span.of_ms offset)) ) ; next_allocation_id = 0 } in @@ -164,33 +166,33 @@ let table = String.Table.create () let capture object_id = let open Allocation_info in - let info_opt = String.Table.find table object_id in + let info_opt = Hashtbl.find table object_id in let data_opt = Option.map info_opt ~f:(fun { data; _ } -> data) in let data = Lazy.( force @@ Option.value_map data_opt ~default:(lazy (Allocation_data.create ())) - ~f:Lazy.return) + ~f:Lazy.return ) in let allocation_id = Allocation_data.register_allocation data in let statistics = Allocation_data.compute_statistics data in - String.Table.set table ~key:object_id ~data:{ data; statistics } ; + Hashtbl.set table ~key:object_id ~data:{ data; statistics } ; Allocation_statistics.write_metrics statistics object_id ; Mina_metrics.( - Counter.inc_one (Object_lifetime_statistics.allocated_count ~name:object_id)) ; + Counter.inc_one (Object_lifetime_statistics.allocated_count ~name:object_id) ) ; allocation_id (* release is currently O(n), where n = number of active allocations for this object type; this can be improved by implementing indexed queues (with decent random delete computational complexity) in ocaml *) let release ~object_id ~allocation_id = let open Allocation_info in - let info = String.Table.find_exn table object_id in + let info = Hashtbl.find_exn table object_id in Allocation_data.unregister_allocation info.data allocation_id ; let statistics = Allocation_data.compute_statistics info.data in - String.Table.set table ~key:object_id ~data:{ info with statistics } ; + Hashtbl.set table ~key:object_id ~data:{ info with statistics } ; Allocation_statistics.write_metrics statistics object_id ; Mina_metrics.( - Counter.inc_one (Object_lifetime_statistics.collected_count ~name:object_id)) + Counter.inc_one (Object_lifetime_statistics.collected_count ~name:object_id) ) let attach_finalizer object_id obj = let allocation_id = capture object_id in @@ -200,8 +202,8 @@ let attach_finalizer object_id obj = let dump () = let open Allocation_info in let entries = - String.Table.to_alist table + Hashtbl.to_alist table |> List.Assoc.map ~f:(fun { statistics; _ } -> - Allocation_statistics.to_yojson statistics ) + Allocation_statistics.to_yojson statistics ) in `Assoc entries From f9c9b265dafef4e46806eb99fe0a8f65a606098e Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 17:28:16 +0800 Subject: [PATCH 54/56] port fields_derivers to 5.2.1 --- .../fields_derivers_json.ml | 55 ++++++++++--------- 1 file changed, 28 insertions(+), 27 deletions(-) diff --git a/src/lib/fields_derivers_json/fields_derivers_json.ml b/src/lib/fields_derivers_json/fields_derivers_json.ml index f822ea8d6142..5418fb5d39bc 100644 --- a/src/lib/fields_derivers_json/fields_derivers_json.ml +++ b/src/lib/fields_derivers_json/fields_derivers_json.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core open Fieldslib module To_yojson = struct @@ -30,12 +30,12 @@ module To_yojson = struct let rest = !(acc#to_json_accumulator) in acc#to_json_accumulator := ( if annotations.skip || !(t_field#skip) then None - else - ( Option.value annotations.name - ~default:(Fields_derivers.name_under_to_camel field) - , fun x -> !(t_field#to_json) (!(t_field#contramap) (Field.get field x)) - ) - |> Option.return ) + else + ( Option.value annotations.name + ~default:(Fields_derivers.name_under_to_camel field) + , fun x -> + !(t_field#to_json) (!(t_field#contramap) (Field.get field x)) ) + |> Option.return ) :: rest ; ((fun _ -> failwith "Unused"), acc) @@ -119,24 +119,25 @@ module Of_yojson = struct let map = !(finished_obj#of_json_creator) in !(t_field#map) ( if annotations.skip || !(t_field#skip) then - match skip_data with - | Some x -> - x - | None -> - failwith - "If you are skipping a field in of_json but intend on building \ - this field, you must provide skip_data to add_field!" - else - !(t_field#of_json) - (let name = - Option.value annotations.name - ~default:(Fields_derivers.name_under_to_camel field) - in - match Map.find map name with - | None -> - raise (Field_not_found name) - | Some x -> - x ) ) + match skip_data with + | Some x -> + x + | None -> + failwith + "If you are skipping a field in of_json but intend on \ + building this field, you must provide skip_data to \ + add_field!" + else + !(t_field#of_json) + (let name = + Option.value annotations.name + ~default:(Fields_derivers.name_under_to_camel field) + in + match Map.find map name with + | None -> + raise (Field_not_found name) + | Some x -> + x ) ) in (creator, acc_obj) @@ -285,8 +286,8 @@ let%test_module "Test" = let full_derivers = both_json @@ o () - let%test_unit "folding creates a yojson object we expect (modulo camel \ - casing)" = + let%test_unit + "folding creates a yojson object we expect (modulo camel casing)" = [%test_eq: string] (Yojson_version.to_yojson Yojson_version.v |> Yojson.Safe.to_string) (!(full_derivers#to_json) v |> Yojson.Safe.to_string) From 9d7e64fbeba04351ab3d7bd29156996ac140d552 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 16:53:54 +0800 Subject: [PATCH 55/56] port blake2 to 5.2.1 --- src/lib/blake2/blake2.ml | 2 +- src/lib/blake2/dune | 3 ++- src/lib/blake2/intf.ml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/lib/blake2/blake2.ml b/src/lib/blake2/blake2.ml index baec7b1edd80..5294bb6f88e7 100644 --- a/src/lib/blake2/blake2.ml +++ b/src/lib/blake2/blake2.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module Make () = struct let digest_size_in_bits = 256 diff --git a/src/lib/blake2/dune b/src/lib/blake2/dune index 6cf82d603159..11efa65ff32c 100644 --- a/src/lib/blake2/dune +++ b/src/lib/blake2/dune @@ -4,7 +4,7 @@ (instrumentation (backend bisect_ppx)) (preprocess - (pps ppx_compare ppx_deriving_yojson ppx_jane ppx_mina ppx_version)) + (pps ppx_assert ppx_compare ppx_deriving_yojson ppx_hash ppx_inline_test ppx_mina ppx_sexp_conv ppx_version)) (inline_tests (flags -verbose -show-counts)) (libraries @@ -12,6 +12,7 @@ base.base_internalhash_types bigarray-compat bin_prot.shape + core_kernel; TODO: figure out why we still need core_kernel here digestif ppx_inline_test.config sexplib0 diff --git a/src/lib/blake2/intf.ml b/src/lib/blake2/intf.ml index 47bb54fa05b7..b21fe5494c4b 100644 --- a/src/lib/blake2/intf.ml +++ b/src/lib/blake2/intf.ml @@ -1,4 +1,4 @@ -open Core_kernel +open Core module type S = sig val digest_size_in_bits : int From 88648e1eb84760b209cac36aa72eaa88d5a641a3 Mon Sep 17 00:00:00 2001 From: glyh Date: Mon, 1 Dec 2025 17:49:52 +0800 Subject: [PATCH 56/56] port plonkish prelude to 5.2.1 --- src/lib/crypto/plonkish_prelude/dune | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lib/crypto/plonkish_prelude/dune b/src/lib/crypto/plonkish_prelude/dune index 64d076a56dda..389c569b0e3d 100644 --- a/src/lib/crypto/plonkish_prelude/dune +++ b/src/lib/crypto/plonkish_prelude/dune @@ -16,9 +16,12 @@ (preprocess (pps h_list.ppx + ppx_compare ppx_deriving.std ppx_deriving_yojson + ppx_hash ppx_mina + ppx_sexp_conv ppx_version)) (modules_without_implementation sigs poly_types) (instrumentation