jean-airoldie / zeromq-src-rs

Source code and logic to build ZeroMQ from source
MIT License
11 stars 15 forks source link

Re-release latest release with `vendor` code #23

Closed skeet70 closed 1 year ago

skeet70 commented 1 year ago

The 0.2.3+4.3.4 release is only 10kb (vs 900kb in the past) and builds have started failing because they're missing vendor files. I think something went wrong in the recent release process that resulted in the vendor submodule not being packaged. It seems like 0.2.3+4.3.4 should be yanked/deprecated and 0.2.4+4.3.4 released with all the required files.

@jean-airoldie

andrewdavidmackenzie commented 1 year ago

Thanks @skeet70 for this issue. I have given up trying workarounds and will just track this waiting for a fix.

jean-airoldie commented 1 year ago

Weird issue, normally cargo builds do a git clone --recursive command.

jean-airoldie commented 1 year ago

Very weird since the CI didn't error and the tests ran correctly. Anyway I published a new release which is 911kb and yanked the previous version. Unsure what happened.

jean-airoldie commented 1 year ago

Alright so it seems that this issue was caused by a weird interaction between cargo and git submodules that wasn't detected (https://github.com/rust-lang/cargo/issues/8635) combined with the fact that the tests didn't link to the testcrate module unless the --workspace flag was provided. I've fixed the later issue, and maybe cargo will fix the former eventually.

Feel free to close the issue if release 0.2.4 fixed your issue.

skeet70 commented 1 year ago

It did solve the issue as I was able to reproduce it. I'll close, if it's still not solved for @andrewdavidmackenzie they can re-open it.

skeet70 commented 1 year ago

Another fix (that I was working on in my fork but bailing on for now) would be to make a GH action do the release on a tag to the repo, so it'd only run after CI (when tagged) and would include the submodule checkout in its checkout action. As long as that action was used for releases, this problem won't happen again.

jean-airoldie commented 1 year ago

That would work but the problem is that you have to give your access token to github to publish which is a security liability.

At the end of the day, this is all a byproduct of sub modules being poorly implemented by git. Hardcoding a manual repo clone wouldn't lead to these issues.