summaryrefslogtreecommitdiff
path: root/lib/rubygems/specification_policy.rb
diff options
context:
space:
mode:
authorDavid Rodriguez <[email protected]>2024-02-05 20:19:40 +0100
committergit <[email protected]>2024-05-03 15:12:55 +0000
commit281df1e495eeb8533b963c63a14c614fcab97859 ()
treeebd8a8865249b34eafd83873fd6f6917894aebc9 /lib/rubygems/specification_policy.rb
parent0948b6a592eb74f1ca4aae158f8bca6034ccb708 (diff)
[rubygems/rubygems] Remove `Gem::Specification#mark_version`
This gets in the middle if we ever start allowing to build as if using a different RubyGems version than the one being run. This could be useful to make `gem rebuild` a little more usable, and it's already done by Bundler specs which already make this method a noop when they need this. I'm not sure forcefully setting this, even if user explicitly specified something else is helpful. Since this could potentially prevent gems explicitly setting a constant RubyGems version from building, I changed the error of incorrect RubyGems version from a hard error to a warning, since it will start happening in those cases if we stop overwriting the version. https://.com/rubygems/rubygems/commit/45676af80d
-rw-r--r--lib/rubygems/specification_policy.rb4
1 files changed, 3 insertions, 1 deletions
@@ -274,7 +274,9 @@ duplicate dependency on #{dep}, (#{prev.requirement}) use:
return if rubygems_version == Gem::VERSION
- error "expected RubyGems version #{Gem::VERSION}, was #{rubygems_version}"
end
def validate_required_attributes