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

Feat: ARM64 Linux/MacOS Pact Ruby Standalone #445

Merged
merged 18 commits into from
Jul 6, 2023

Conversation

YOU54F
Copy link
Member

@YOU54F YOU54F commented May 2, 2023

Changes to traveling ruby to support additional platforms

Details of changes made to travelling ruby

PR's to Travelling ruby to update the supported archs

Which means we can now support

OS Ruby Architecture Supported
OSX 3.2.2 x86_64
OSX 3.3.2 aarch64 (arm)
Linux 3.2.2 x86_64
Linux 3.2.2 aarch64 (arm)
Windows 3.2.2 x86_64
Windows 3.2.2 x86
Windows 3.2.2 aarch64 (via x86 emulation)

Details of changes made to pact-ruby-standalone

Details of changes made to pact-js

These have been consumed in the pact-js project, and tested cross platform

In order to test ARM64 on MacOS, and Linux, I have utilised cirrus-ci, which is free for open-source usage (within reasonable limits)

OS Standalone Version Architecture Tested
OSX v2.0.1 x86_64 GitHub Actions
OSX v2.0.1 aarch64 (arm) Cirrus CI
Linux v2.0.1 x86_64 GitHub Actions
Linux v2.0.1 aarch64 (arm) Cirrus-CI
Windows v2.0.1 x86_64 GitHub Actions
Windows v2.0.1 aarch64 (via x86 emulation) Untested in CI, tested on my local machine
Windows v2.0.1 x86 Not relevant for pact-js-core as FFI lib not provided

Related Issues

User facing notes

  • macOS arm64 (m1/m2) users will no require require installing rosetta
    • If a user wishes to run in a rosetta enabled shell or session, they will need the appropriate x64 node version (see .cirrus.yml for an example of how one can install x64 versions with nvs, but pact-js-core will determine this and use the appropriate FFI library, and now ruby standalone.

Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2.
- [Release notes](https://github.com/json5/json5/releases)
- [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md)
- [Commits](json5/json5@v1.0.1...v1.0.2)

---
updated-dependencies:
- dependency-name: json5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
@TimothyJones
Copy link
Contributor

Same review comments as on #444. I'm not sure what else is different on this one, but I'm happy to review it once #444 is merged.

Also, same comment as before about the commit messages -

fix: linux needs libyaml-dev / ensure x64 for macos intel

^ This will end up in the release notes, but that message isn't very suitable.

It would mean that this needs to be squash merged with an appropriate message, but then you'd lose the nice individual commits you've got here.

(you may be interested in release please, which lets you override the commit messages after a merge - although it also requires squash merges to do this)

@YOU54F
Copy link
Member Author

YOU54F commented May 3, 2023

Additional changes in this introduce

  • the new pact ruby standalone with ruby 3.2.2
  • support for arm64 on linux (demonstrable as failing in the previous pr)
  • arm64 on macOS (demonstrable as being run without rosetta and working)

CI runs to prove it all works, only thing worthy of note of reviewing is the standalone test, which probably warrants a refactor as the linux/macos tests were already in need of DRY, and adding the additional arches is just too many extra lines of code.

fix: linux needs libyaml-dev / ensure x64 for macos intel

Yeah hmm, so the jist is, a linux user will require libyaml-dev installed on their linux distro to use the pact-ruby-standalone on arm64 hardware, probably because I missed something in the big build system update, or just because they need it. You never see it in the GH build systems, as their build runner images are already full of extra development things, it should have probably been ci(fix)

not entirely sure of the best way to communicate that to end users

@YOU54F
Copy link
Member Author

YOU54F commented May 3, 2023

I'm quite happy just doing a soft reset on my commits and then just layering them with nice commit messages in steps, it's what I tend to do, after experimenting in ci, and having spurious commit messages with my handy sendit alias hehe

@YOU54F
Copy link
Member Author

YOU54F commented May 5, 2023

Hey!

It has been identified that there are a couple of issues noted in the new 2.x version of the pact-ruby-standalone, therefore I am switching this PR to a draft

pact-foundation/pact-ruby-standalone#101 (comment)

@YOU54F YOU54F marked this pull request as ready for review May 18, 2023 22:50
YOU54F and others added 2 commits June 7, 2023 18:11
…rade-to-pact-ruby-standalone-2-0-2

fix: update standalone to 2.0.2
@mefellows
Copy link
Member

I think the issues with the standalone are fixed now?

@YOU54F
Copy link
Member Author

YOU54F commented Jul 3, 2023

I think the issues with the standalone are fixed now?

Yep, sorted in 2.0.2, will update the PR :)

@YOU54F
Copy link
Member Author

YOU54F commented Jul 3, 2023

ohhhhh it was merged already

#449

@mefellows mefellows merged commit f8542fc into pact-foundation:master Jul 6, 2023
22 checks passed
@YOU54F YOU54F linked an issue Jul 6, 2023 that may be closed by this pull request
2 tasks
@YOU54F YOU54F deleted the master-pf-2.0.0-standalone branch June 26, 2024 01:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants