Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aws-s3 needs bounds on base #27312

Merged
merged 4 commits into from
Jan 28, 2025
Merged

aws-s3 needs bounds on base #27312

merged 4 commits into from
Jan 28, 2025

Conversation

mseri
Copy link
Member

@mseri mseri commented Jan 23, 2025

Fails with

#=== ERROR while compiling aws-s3.4.8.0 =======================================#
# context              2.4.0~alpha1~dev | linux/x86_64 | ocaml-base-compiler.5.3.0 | file:///home/opam/opam-repository
# path                 ~/.opam/5.3/.opam-switch/build/aws-s3.4.8.0
# command              ~/.opam/opam-init/hooks/sandbox.sh build dune build -p aws-s3 -j 31
# exit-code            1
# env-file             ~/.opam/log/aws-s3-7-a24906.env
# output-file          ~/.opam/log/aws-s3-7-a24906.out
### output ###
# (cd _build/default && /home/opam/.opam/5.3/bin/ocamlc.opt -w -40 -g -bin-annot -bin-annot-occurrences -I aws-s3/.aws_s3.objs/byte -I /home/opam/.opam/5.3/lib/angstrom -I /home/opam/.opam/5.3/lib/base -I /home/opam/.opam/5.3/lib/base/base_internalhash_types -I /home/opam/.opam/5.3/lib/base/shadow_stdlib -I /home/opam/.opam/5.3/lib/base64 -I /home/opam/.opam/5.3/lib/bigstringaf -I /home/opam/.opam/5.3/lib/digestif -I /home/opam/.opam/5.3/lib/digestif/c -I /home/opam/.opam/5.3/lib/eqaf -I /home/opam/.opam/5.3/lib/ezxmlm -I /home/opam/.opam/5.3/lib/inifiles -I /home/opam/.opam/5.3/lib/jane-street-headers -I /home/opam/.opam/5.3/lib/ocaml/str -I /home/opam/.opam/5.3/lib/ocaml/unix -I /home/opam/.opam/5.3/lib/ocaml_intrinsics_kernel -I /home/opam/.opam/5.3/lib/pcre -I /home/opam/.opam/5.3/lib/ppx_compare/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_enumerate/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_expect/config -I /home/opam/.opam/5.3/lib/ppx_expect/config_types -I /home/opam/.opam/5.3/lib/ppx_expect/make_corrected_file -I /home/opam/.opam/5.3/lib/ppx_expect/runtime -I /home/opam/.opam/5.3/lib/ppx_hash/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_here/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_inline_test/config -I /home/opam/.opam/5.3/lib/ppx_inline_test/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/driver -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/runtime -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_json -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_xmlm -I /home/opam/.opam/5.3/lib/ppx_sexp_conv/runtime-lib -I /home/opam/.opam/5.3/lib/ppxlib/print_diff -I /home/opam/.opam/5.3/lib/ptime -I /home/opam/.opam/5.3/lib/seq -I /home/opam/.opam/5.3/lib/sexplib0 -I /home/opam/.opam/5.3/lib/stdio -I /home/opam/.opam/5.3/lib/stringext -I /home/opam/.opam/5.3/lib/time_now -I /home/opam/.opam/5.3/lib/uri -I /home/opam/.opam/5.3/lib/xmlm -I /home/opam/.opam/5.3/lib/yojson -intf-suffix .ml -no-alias-deps -open Aws_s3__ -o aws-s3/.aws_s3.objs/byte/aws_s3__S3.cmo -c -impl aws-s3/s3.pp.ml)
# File "aws-s3/s3.ml", line 414, characters 59-77:
# 414 |       let headers = [ "Content-MD5", Base64.encode_string (Caml.Digest.string request) ] in
#                                                                  ^^^^^^^^^^^^^^^^^^
# Error: Unbound module "Caml"
# (cd _build/default && /home/opam/.opam/5.3/bin/ocamlopt.opt -w -40 -g -I aws-s3/.aws_s3.objs/byte -I aws-s3/.aws_s3.objs/native -I /home/opam/.opam/5.3/lib/angstrom -I /home/opam/.opam/5.3/lib/base -I /home/opam/.opam/5.3/lib/base/base_internalhash_types -I /home/opam/.opam/5.3/lib/base/shadow_stdlib -I /home/opam/.opam/5.3/lib/base64 -I /home/opam/.opam/5.3/lib/bigstringaf -I /home/opam/.opam/5.3/lib/digestif -I /home/opam/.opam/5.3/lib/digestif/c -I /home/opam/.opam/5.3/lib/eqaf -I /home/opam/.opam/5.3/lib/ezxmlm -I /home/opam/.opam/5.3/lib/inifiles -I /home/opam/.opam/5.3/lib/jane-street-headers -I /home/opam/.opam/5.3/lib/ocaml/str -I /home/opam/.opam/5.3/lib/ocaml/unix -I /home/opam/.opam/5.3/lib/ocaml_intrinsics_kernel -I /home/opam/.opam/5.3/lib/pcre -I /home/opam/.opam/5.3/lib/ppx_compare/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_enumerate/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_expect/config -I /home/opam/.opam/5.3/lib/ppx_expect/config_types -I /home/opam/.opam/5.3/lib/ppx_expect/make_corrected_file -I /home/opam/.opam/5.3/lib/ppx_expect/runtime -I /home/opam/.opam/5.3/lib/ppx_hash/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_here/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_inline_test/config -I /home/opam/.opam/5.3/lib/ppx_inline_test/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/driver -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/runtime -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_json -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_xmlm -I /home/opam/.opam/5.3/lib/ppx_sexp_conv/runtime-lib -I /home/opam/.opam/5.3/lib/ppxlib/print_diff -I /home/opam/.opam/5.3/lib/ptime -I /home/opam/.opam/5.3/lib/seq -I /home/opam/.opam/5.3/lib/sexplib0 -I /home/opam/.opam/5.3/lib/stdio -I /home/opam/.opam/5.3/lib/stringext -I /home/opam/.opam/5.3/lib/time_now -I /home/opam/.opam/5.3/lib/uri -I /home/opam/.opam/5.3/lib/xmlm -I /home/opam/.opam/5.3/lib/yojson -intf-suffix .ml -no-alias-deps -open Aws_s3__ -o aws-s3/.aws_s3.objs/native/aws_s3__Credentials.cmx -c -impl aws-s3/credentials.pp.ml)
# File "_none_", line 1:
# Warning 58 [no-cmx-file]: no cmx file was found in path for module Inifiles, and its interface was not compiled with -opaque
# (cd _build/default && /home/opam/.opam/5.3/bin/ocamlopt.opt -w -40 -g -I aws-s3/.aws_s3.objs/byte -I aws-s3/.aws_s3.objs/native -I /home/opam/.opam/5.3/lib/angstrom -I /home/opam/.opam/5.3/lib/base -I /home/opam/.opam/5.3/lib/base/base_internalhash_types -I /home/opam/.opam/5.3/lib/base/shadow_stdlib -I /home/opam/.opam/5.3/lib/base64 -I /home/opam/.opam/5.3/lib/bigstringaf -I /home/opam/.opam/5.3/lib/digestif -I /home/opam/.opam/5.3/lib/digestif/c -I /home/opam/.opam/5.3/lib/eqaf -I /home/opam/.opam/5.3/lib/ezxmlm -I /home/opam/.opam/5.3/lib/inifiles -I /home/opam/.opam/5.3/lib/jane-street-headers -I /home/opam/.opam/5.3/lib/ocaml/str -I /home/opam/.opam/5.3/lib/ocaml/unix -I /home/opam/.opam/5.3/lib/ocaml_intrinsics_kernel -I /home/opam/.opam/5.3/lib/pcre -I /home/opam/.opam/5.3/lib/ppx_compare/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_enumerate/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_expect/config -I /home/opam/.opam/5.3/lib/ppx_expect/config_types -I /home/opam/.opam/5.3/lib/ppx_expect/make_corrected_file -I /home/opam/.opam/5.3/lib/ppx_expect/runtime -I /home/opam/.opam/5.3/lib/ppx_hash/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_here/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_inline_test/config -I /home/opam/.opam/5.3/lib/ppx_inline_test/runtime-lib -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/driver -I /home/opam/.opam/5.3/lib/ppx_protocol_conv/runtime -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_json -I /home/opam/.opam/5.3/lib/ppx_protocol_conv_xmlm -I /home/opam/.opam/5.3/lib/ppx_sexp_conv/runtime-lib -I /home/opam/.opam/5.3/lib/ppxlib/print_diff -I /home/opam/.opam/5.3/lib/ptime -I /home/opam/.opam/5.3/lib/seq -I /home/opam/.opam/5.3/lib/sexplib0 -I /home/opam/.opam/5.3/lib/stdio -I /home/opam/.opam/5.3/lib/stringext -I /home/opam/.opam/5.3/lib/time_now -I /home/opam/.opam/5.3/lib/uri -I /home/opam/.opam/5.3/lib/xmlm -I /home/opam/.opam/5.3/lib/yojson -intf-suffix .ml -no-alias-deps -open Aws_s3__ -o aws-s3/.aws_s3.objs/native/aws_s3__S3.cmx -c -impl aws-s3/s3.pp.ml)
# File "aws-s3/s3.ml", line 414, characters 59-77:
# 414 |       let headers = [ "Content-MD5", Base64.encode_string (Caml.Digest.string request) ] in
#                                                                  ^^^^^^^^^^^^^^^^^^
# Error: Unbound module "Caml"

Seen on #27300

Signed-off-by: Marcello Seri <[email protected]>
@@ -19,6 +19,7 @@ depends: [
"ptime"
"uri"
"ezxmlm" {>= "1.1.0"}
"base" {>= "v0.16.0"}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure why this is needed. Aws-s3 ought not to depend directly on base (or at least that's the intention).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May have been my mistake

Copy link
Contributor

@andersfugmann andersfugmann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this - I was just about to make a PR with (almost) the same changes!

@andersfugmann
Copy link
Contributor

Going through the failures on CI, the packages
4.4.0, 4.4.1, 4.5.0 and 4.5.1 also needs

  • uri {> "1.3.1"} to resolve This expression has type (string * 'a list) list
  • ocaml {> "4.08.0"} to resolve Unbound module Result

I've created a PR against mseri/aws-s3 to solve this.

aws-s3 needs bounds on ocaml and uri
Copy link
Contributor

@shonfeder shonfeder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The only CI failures left are either lints not relevant for a a bounds update or solver timeouts on older opam version.

Thanks for the fixes here!

@shonfeder shonfeder merged commit 38019ca into ocaml:master Jan 28, 2025
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants