Skip to content

Prefer Traces.trace. #124

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

Merged
merged 1 commit into from
Jun 19, 2023
Merged

Prefer Traces.trace. #124

merged 1 commit into from
Jun 19, 2023

Conversation

ioquatix
Copy link
Member

@ioquatix ioquatix commented Jun 19, 2023

The traces gem was updated with a "easier to use" interface, Traces.trace. This also prepares us to avoid clobbering Protocol::HTTP::Methods#trace.

Types of Changes

  • Maintenance.

Contribution

@ioquatix ioquatix merged commit 014a553 into main Jun 19, 2023
@ioquatix ioquatix deleted the update-traces branch June 19, 2023 05:50
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
spec.add_dependency "protocol-http", "~> 0.24.0"
spec.add_dependency "protocol-http1", "~> 0.15.0"
spec.add_dependency "protocol-http2", "~> 0.15.0"
spec.add_dependency "traces", ">= 0.8.0"
spec.add_dependency "traces", ">= 0.10.0"
Copy link

@dentarg dentarg Jun 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding this dependency now mean async-http needs at least Ruby 2.7 to run but that is not reflected in the gemspec. https://github.com/socketry/traces/pull/8/files#r1237988182

Noticed this because Sinatra CI failed on Ruby 2.6: https://github.com/sinatra/sinatra/actions/runs/5263567184/jobs/9631906714#step:5:15

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah thanks for the report. I have a general policy of not supporting EOL Rubies. However, we can probably drop 2.7 as a requirement for traces in the next release because we won't need to use ... any more. Hopefully I'll be able to do the next release in about a week.

Copy link

@dentarg dentarg Jun 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good, I've worked around the problem in Sinatra CI but I imagine it could be more difficult to do that in other projects (applications).

Just curious, should you be specifying the mimimum supported Ruby version in the gemspec for your gems? Then users of old Ruby versions can just keep using old versions of the gems (bundler should just pick the correct version for them).

Copy link
Member Author

@ioquatix ioquatix Jun 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I usually try to do so, I'll probably need to automate it, I automate a lot of maintenance but don't always remember to fix the minimum version because it's not automated. I can describe the policy (drop EOL ruby), automate it, and then it should be easier. https://github.com/ioquatix/bake-modernize is my automation tool.

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

Successfully merging this pull request may close these issues.

2 participants