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

ppx_cstruct testsuite broken under OCaml 4.08 #263

Closed
gasche opened this issue Jul 10, 2019 · 3 comments
Closed

ppx_cstruct testsuite broken under OCaml 4.08 #263

gasche opened this issue Jul 10, 2019 · 3 comments
Assignees

Comments

@gasche
Copy link
Contributor

gasche commented Jul 10, 2019

The ppx_cstruct testsuite is broken under OCaml 4.08.0. See

ocaml/opam-repository#14464
https://ci.ocaml.org/log/saved/docker-run-568738f3749bf66f881cf36d58071286/a1d58c3c528c836550875fd71cad87479128b5a4
gasche/opam-repository@1e216a1

Quoting the commit message from gasche/opam-repository@1e216a1

With 4.08 the compiler prints errors differently by default,
which appears to break expect-style tests that are checking for errors.

This should probably be fixed at the upstream level of dune (probably
by calling the compiler with the '-error-style short' option in
tests), so in the future (if "fixed" versions of dune are released)
the (ocaml:version < 4.08) constraint on tests should be replaced by
(dune:version >= fixed-version) to re-enable testing.

It may be enough to enable -error-style short or OCAML_ERROR_STYLE=short from the dune fields of the ppx_cstruct test, but I wonder if a dune-level fix would be possible.

@gasche
Copy link
Contributor Author

gasche commented Jul 10, 2019

(I'm not sure I have a good enough handle of the package-level vs. dune-level issue to report an issue on the Dune bugtracker right now. People that are more familiar with the mirage test setup, please feel free to give an opinion on what's the best fix and, if "upstream" is the answer, open an issue there yourself.)

@emillon emillon self-assigned this Jul 10, 2019
@emillon
Copy link
Contributor

emillon commented Jul 10, 2019

Thanks for the report. That looked fragile indeed. Adding first class support to this in dune looks reasonable, I'll bring that up.

@avsm
Copy link
Member

avsm commented Nov 25, 2019

Sadly, it turns out that 4.09 has also further changed the error format, so simply setting CAML_ERROR_STYLE isn't fully sufficient. ocaml/opam-repository#15381

(the short error style does work for 4.08 and below)

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

No branches or pull requests

3 participants