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

ostruct will be dropped from stdlib in Ruby 3.5.0 #173

Open
mefellows opened this issue Oct 9, 2024 · 5 comments · Fixed by #175
Open

ostruct will be dropped from stdlib in Ruby 3.5.0 #173

mefellows opened this issue Oct 9, 2024 · 5 comments · Fixed by #175
Labels
enhancement Indicates new feature requests good first issue Indicates a good issue for first-time contributors help wanted Indicates that a maintainer wants help on an issue or pull request smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear

Comments

@mefellows
Copy link
Member

In the latest version of the CLI, the following warning is presented:

<path>/pact/lib/ruby/lib/ruby/3.3.0/json/common.rb:3: warning: ostruct was loaded from the standard library, but will no longer be part of the default gems starting from Ruby 3.5.0.

In general, fixing this should be a matter of making it an explicit dependency, albeit this might just be a matter of updating downstream dependencies.

Example PRs for other projects:

@mefellows mefellows added enhancement Indicates new feature requests help wanted Indicates that a maintainer wants help on an issue or pull request good first issue Indicates a good issue for first-time contributors smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear labels Oct 9, 2024
Copy link

github-actions bot commented Oct 9, 2024

🤖 Great news! We've labeled this issue as smartbear-supported and created a tracking ticket in PactFlow's Jira (PACT-2605). We'll keep work public and post updates here. Meanwhile, feel free to check out our docs. Thanks for your patience!

@YOU54F
Copy link
Member

YOU54F commented Oct 23, 2024

For a bit of history

ruby/json#579

We are using json 2.7.1 (it is part of the standard lib for ruby 3.3.5 which we are using in traveling ruby)

When we move to ruby 3.4.x on release, we can bump the json gem in traveling ruby to 2.7.2 (currently locked in the pact-ruby-standalone repo, so we use std gems, and can build windows packages, as traveling ruby doesn't support building native extensions for windows)

https://github.com/pact-foundation/pact-ruby-standalone/blob/6a912648f56129188e00de2e4c331f636d31cc5b/packaging/Gemfile#L10-L14

https://stdgems.org/3.4.0/

json 2.7.2 makes the requirement on ostruct optional, but ostruct itself is required in a few of our projects explicitly so makes sense to add it.

@YOU54F
Copy link
Member

YOU54F commented Oct 23, 2024

@YOU54F
Copy link
Member

YOU54F commented Oct 23, 2024

we've got one more on windows, this time for fiddle. I've formatted for readability

[15:22:32.551] DEBUG (1620): 

pact-cli@16.0.1: 
D:/a/pact-js-cli/pact-js-cli/
@pact-foundation/pact-cli-windows-x64/standalone/windows-x64-2.4.15/
pact/lib/ruby/lib/ruby/3.3.0/win32/registry.rb:2: 


warning: fiddle was loaded from the standard library, 
but will no longer be part of the default gems starting from Ruby 3.5.0.

Looks to be related to ruby/fiddle#145

replicated in windows builds

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Indicates new feature requests good first issue Indicates a good issue for first-time contributors help wanted Indicates that a maintainer wants help on an issue or pull request smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants