Skip to content

Commit

Permalink
Replace sentry-ruby-core with sentry-ruby as integration dependency (#…
Browse files Browse the repository at this point in the history
…1825)

* Replace sentry-ruby-core with sentry-ruby as integration dependency

sentry-ruby-core was created for loosing version requirement on faraday.
It's the actual code container and sentry-ruby just wraps around it with
a version requirement. But since faraday is now dropped, this extra
structure is not needed anymore.

The plan is to make sentry-ruby the gem that holds the logic and point
integrations to it. And sentry-ruby-core will just depend on sentry-ruby
and does nothing for backward compatibility.

* Update changelog
  • Loading branch information
st0012 committed May 25, 2022
1 parent 8ac77e8 commit 1a0b244
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .scripts/batch_release.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def update_version_file(gem_name, version)
def update_gemspec_dependency(gem_name, version)
file_name = "#{gem_name}/#{gem_name}.gemspec"
text = File.read(file_name)
new_contents = text.gsub(/spec.add_dependency "sentry-ruby-core", ".+"/, "spec.add_dependency \"sentry-ruby-core\", \"~> #{version}\"")
new_contents = text.gsub(/spec.add_dependency "sentry-ruby", ".+"/, "spec.add_dependency \"sentry-ruby\", \"~> #{version}\"")
File.open(file_name, "w") {|file| file.puts new_contents }
end

Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
### Refactoring

- Move envelope item processing/trimming logic to the Item class [#1824](https://github.com/getsentry/sentry-ruby/pull/1824)
- Replace sentry-ruby-core with sentry-ruby as integration dependency [#1825](https://github.com/getsentry/sentry-ruby/pull/1825)

## 5.3.1

Expand Down
2 changes: 1 addition & 1 deletion sentry-delayed_job/sentry-delayed_job.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.add_dependency "sentry-ruby-core", "~> 5.3.1"
spec.add_dependency "sentry-ruby", "~> 5.3.1"
spec.add_dependency "delayed_job", ">= 4.0"
end
2 changes: 1 addition & 1 deletion sentry-rails/sentry-rails.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ Gem::Specification.new do |spec|
spec.require_paths = ["lib"]

spec.add_dependency "railties", ">= 5.0"
spec.add_dependency "sentry-ruby-core", "~> 5.3.1"
spec.add_dependency "sentry-ruby", "~> 5.3.1"
end
2 changes: 1 addition & 1 deletion sentry-resque/sentry-resque.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.add_dependency "sentry-ruby-core", "~> 5.3.1"
spec.add_dependency "sentry-ruby", "~> 5.3.1"
spec.add_dependency "resque", ">= 1.24"
end
1 change: 0 additions & 1 deletion sentry-ruby/Gemfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
source "https://rubygems.org"
git_source(:github) { |name| "https://github.com/#{name}.git" }

gem "sentry-ruby-core", path: "./"
gem "sentry-ruby", path: "./"

gem "rack" unless ENV["WITHOUT_RACK"] == "1"
Expand Down
5 changes: 1 addition & 4 deletions sentry-ruby/sentry-ruby-core.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ Gem::Specification.new do |spec|
spec.metadata["source_code_uri"] = spec.homepage
spec.metadata["changelog_uri"] = "#{spec.homepage}/blob/master/CHANGELOG.md"

spec.bindir = "exe"
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.add_dependency "sentry-ruby", Sentry::VERSION
spec.add_dependency "concurrent-ruby"
end
3 changes: 2 additions & 1 deletion sentry-ruby/sentry-ruby.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Gem::Specification.new do |spec|
spec.metadata["source_code_uri"] = spec.homepage
spec.metadata["changelog_uri"] = "#{spec.homepage}/blob/master/CHANGELOG.md"

spec.add_dependency "sentry-ruby-core", Sentry::VERSION
spec.require_paths = ["lib"]

spec.add_dependency "concurrent-ruby", '~> 1.0', '>= 1.0.2'
end
2 changes: 1 addition & 1 deletion sentry-sidekiq/sentry-sidekiq.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.add_dependency "sentry-ruby-core", "~> 5.3.1"
spec.add_dependency "sentry-ruby", "~> 5.3.1"
spec.add_dependency "sidekiq", ">= 3.0"
end

0 comments on commit 1a0b244

Please sign in to comment.