aantron / bisect_ppx

Code coverage for OCaml and ReScript
http://aantron.github.io/bisect_ppx/demo/
MIT License
302 stars 60 forks source link

test run again with ocamlformat 0.16.0? #441

Open yuzibo opened 3 months ago

yuzibo commented 3 months ago

Hi,

I was packaging the bisect-ppx into Debian. But now the ocamlformat was just uploaded there also some days ago, Unfortunately there is only 0.26.2 since. So it seems there is no chance to run test when building, right?

aantron commented 3 months ago

Hi! Thank you!

I use prebuilt ocamlformat binaries in Bisect's own CI. I don't know if that could work for testing.

The reason for the specific ocamlformat version is that Bisect needs to normalize its test output across multiple OCaml compiler versions' AST to source dump outputs, so we can run the tests on all those versions, and I just use whatever version of ocamlformat that I found does that correctly. Perhaps I can look into using a more recent version, also, but the result would likely still be pinning ocamlformat to a specific version anyway, as otherwise there is a risk of having to frequently update the tests with ocamlformat profiles, expected outputs, etc.

aantron commented 3 months ago

Work for testing in Debian, that is. Can you package a local prebuilt binary of ocamlformat?

yuzibo commented 3 months ago

Hi,

Thank you also.:)

The reason for the specific ocamlformat version is that Bisect needs to normalize its test output across multiple OCaml compiler versions' AST to source dump outputs, so we can run the tests on all those versions, and I just use whatever version of ocamlformat that I found does that correctly. Perhaps I can look into using a more recent version, also, but the result would likely still be pinning ocamlformat to a specific version anyway, as otherwise there is a risk of having to frequently update the tests with ocamlformat profiles, expected outputs, etc.

Understand it. Please notice this issue is just to ask for confirmation and please keep your development workflow.

Work for testing in Debian, that is. Can you package a local prebuilt binary of ocamlformat?

Hmm, I can but there is no help to run tests for bisect-ppx on Debian. The Debian packaging env will fetch all build dependences or tests requirement from Debian official arhives. We can not put one prebuilt binary like ocamlformat into packaging. As we can see here, although ocamlformat has been packaged into Debian, but it's version > 0.26.2 at least.

As I did for bisect-ppx Debian package, I was skipping the test when building and this is okay for Debian. Because I noticed ocamlformat has been packaged recently, so I think I can try to run test for bisect-ppx. So, you know.:)

aantron commented 3 months ago

Understood, thank you!

yuzibo commented 3 months ago

Perhaps I can look into using a more recent version, also, but the result would likely still be pinning ocamlformat to a specific version anyway

If this is okay for you also, it would be great to upgrade ocamlformat to 0.26.2 for bisect-ppx then I can versioned it on Debian side. But I can imagine maybe there is lots work that needs to be done.:)

aantron commented 3 months ago

I can look into it eventually, but eventually again Debian will update ocamlformat to yet another version, and it seems unreasonable long-term to upgrade ocamlformat in this repo for Debian specifically.

aantron commented 3 months ago

As there are other distros, other considerations, etc. It might be best to just continue skipping the tests, unfortunately.

yuzibo commented 3 months ago

I can look into it eventually, but eventually again Debian will update ocamlformat to yet another version, and it seems unreasonable long-term to upgrade ocamlformat in this repo for Debian specifically.

Ah, this could be fixed like below sometime:

debhelper-compat (= 13),

to one specifically version ocamlformat.

As there are other distros, other considerations, etc. It might be best to just continue skipping the tests, unfortunately.

Yeah, I think so too.:)

Please feel free to close the issue.

aantron commented 3 months ago

Ah, this could be fixed like below sometime:

debhelper-compat (= 13),

to one specifically version ocamlformat.

Let's leave this open then. I will eventually look into upgrading to 0.26.2, since that version, as I understand it, is and will be available in Debian.