Make DEFAULT_INSTALL_EXTENSION_IN_LIB to false#9240
Conversation
false
There was a problem hiding this comment.
Pull request overview
This pull request changes the default value of DEFAULT_INSTALL_EXTENSION_IN_LIB from true to false in RubyGems. This change stops installing C extension artifacts to the lib directory by default, making it easier to share gems across different Ruby versions. The change was planned for RubyGems 4.0 (as indicated by the removed TODO comment) and is now being implemented in version 4.1.0.dev.
Key changes:
- Changes default behavior for C extension installation location
- Removes the TODO comment that indicated this change should happen in RubyGems 4.0
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| DEFAULT_IPV4_FALLBACK_ENABLED = false | ||
| # TODO: Use false as default value for this option in RubyGems 4.0 | ||
| DEFAULT_INSTALL_EXTENSION_IN_LIB = true | ||
| DEFAULT_INSTALL_EXTENSION_IN_LIB = false |
There was a problem hiding this comment.
The test in test_initialize doesn't verify the default value of install_extension_in_lib when no configuration is provided. Consider adding an assertion like assert_equal false, @cfg.install_extension_in_lib in the first part of the test_initialize method (around line 45) to explicitly test that the new default value is false when no config file setting overrides it.
There was a problem hiding this comment.
@copilot open a new pull request to apply changes based on this feedback
8eaf071 to
bcc9e0d
Compare
…ling extensions into lib directory
…ialize Co-authored-by: hsbt <12301+hsbt@users.noreply.github.com>
bcc9e0d to
cf8c9ee
Compare
What is your fix for the problem, implemented in this PR?
install_extension_in_libleads to install C extension artifacts to under thelibdirectory.This makes to hard to share gems across different version of Ruby. We should stop this in the future.
see also:
Make sure the following tasks are checked