| Age | Commit message (Collapse) | Author |
|
Originally, the call to `.stubs_for` allowed to incrementally populate
the `@@stubs_by_name` (especially see the `"#{name}-*.gemspec"` pattern
in 4fa03bb7aac9f25f44394e818433fdda9962ae8d). Now it looks like it
expects that all stubs are loaded, but the `.stubs_for` still matches
the .gemspec files by the `name` pattern:
https://github.com/rubygems/rubygems/blob/6d45e0f7ac1caca22900e39f703e226c4cfdebf7/lib/rubygems/specification.rb#L845
I think this was done by mistake incrementally by PR #1239 and
4cee8ca9199ac7b3ab8647e0b78615f55d3eb02b. I think the best option is to
get back to the original implementation, to let RubyGems incrementally
populate the array. Other option would be to replace the logic in
`.stub_for` by call to `.stubs`, but the means the performance
improvement from the original commit was lost.
https://github.com/rubygems/rubygems/commit/4d0e18185a
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This list of exceptions is no longer rescued since
1f03275ff3faa1c808d3a3b89ef5db62dc2eb2ba.
https://github.com/rubygems/rubygems/commit/6e71e7be67
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Otherwise if this test file is run in isolation, this test will fail.
https://github.com/rubygems/rubygems/commit/79da003948
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
By default, the `Zlib::GzipFile::Error` does not include the actual data
that was not in gzip format that caused the error.
However, its `#inspect` method includes it.
I think this can be helpful to troubleshoot errors.
https://github.com/rubygems/rubygems/commit/11c8717133
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Remove unused module variable.
https://github.com/rubygems/rubygems/commit/98135bb3d8
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
The file was removed at
https://github.com/rubygems/rubygems/commit/65b709b095b8354ac2620d1a5d7d537e539f6498,
shipped with rubygems 2.6.5.
https://github.com/rubygems/rubygems/commit/739159a120
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
I believe these are most certainly due to a problem outside of rubygems.
I'm skipping these at least until webrick officially supports jruby
(defining "officially" as "webrick's CI passes on jruby").
https://github.com/rubygems/rubygems/commit/4fca025358
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This is a default gem on jruby, which ships with a rubygems plugin,
which prints warnings all over the place during our tests.
This plugin is unnecessary from our tests, so I disable it through the
`JARS_SKIP` environment variable provided by this gem.
https://github.com/rubygems/rubygems/commit/0aabbcf269
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This requirement was introduced 14 years ago in
7ce7039b390440754954df5efea619e9f57ef823, and I don't think it's
necessary anymore. I made several tests introducing UTF-8 characters in
gemspec files and generating indexes out of them, and couldn't find any
issues. Gemspecs are read with UTF-8 encoding these days.
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This code is not necessary and has the bad side effect of causing
test failures in cascade once a single test inside the file fails.
See https://github.com/rubygems/rubygems/runs/538978838 for an example.
https://github.com/rubygems/rubygems/commit/2291d32915
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/44ebbded12
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
To make tests more deterministic, since `Dir.tmpdir` sometimes will
return the current directory dependending on the writability of other
paths, and in that case since the current directory is changed by our
tests, tests can fail.
Force a local tmp folder instead, which will always be writable.
https://github.com/rubygems/rubygems/commit/3e522bac65
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Fixed in
https://github.com/ruby/ruby/commit/45df1c24d269f93a2bc1e7a6fe0ffcecc1193051,
released with ruby 2.3
https://github.com/rubygems/rubygems/commit/f8f67f3952
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
raised while trying to activate a gem
https://github.com/rubygems/rubygems/commit/4da54a8e8b
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/b23d2421df
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
In ruby 2.7.0, there's a slight change in bundler's default gemspec file
where the executable folder of the bundler gem is `libexec` instead of
`exe`. I made that change in https://github.com/ruby/ruby/pull/2380 to
try to simplify the integration of the `bundler` gem with upstream,
minimizing the number of changes that need to be made to the gemspec to
adapt to the structure of ruby-core.
That worked ok, expected for this issue. The new name of the folder
including the executable files uncovered a bug in rubygems, which is the
following:
* In order to be able to use newer versions of default gems, `rubygems`
ships with a customized `require` that has knowledge about which files
belong to which default gem. If one of these files is required,
`rubygems` will detect that and activate its gem mechanism to choose the
newest version of the corresponding default gem present in the system
(unless a different version has already been activated). It's this part
of the custom require:
https://github.com/rubygems/rubygems/blob/ea3e6f194df500b028b52b3b64decbd3df1d5ab0/lib/rubygems/core_ext/kernel_require.rb#L77-L85
* In order to do that, `rubygems` registers a map of default gems and
their files when it is first required:
https://github.com/rubygems/rubygems/blob/ea3e6f194df500b028b52b3b64decbd3df1d5ab0/lib/rubygems.rb#L1247-L1276
As explained in the method's header, two types of default gem
specifications are supported. One of the formats is the style used by
some ruby-core gemspec files, where paths inside the `spec.files` array
don't include the `spec.require_paths` part. So in this "old style", if
a gem ships with a `lib/bundler.rb` file, it will be registered in this
array as `spec.files = ["bundler.rb"]`, not as `spec.files =
["lib/bundler.rb"]`. The `Gem.register_default_spec` method "detects"
this style by making sure that none of the files in the `spec.files`
array start with any of the `spec.require_paths`.
* Since in ruby 2.7 the default specification file of the `bundler` gem
includes a `libexec/bundle` file, this check would no longer work
correctly, because even though the specification file is still "old
style", it has one registered file which starts with "lib", one of the
"require paths" of the gem.
* This means that the gem is incorrectly detected as "new style", but
since none of the paths start with "lib/", no files are actually
registered, so the gem is not being considered a default gem, and thus
the default version is always used with no possibility of being
"upgraded".
The fix of the problem is simple: check that no files start with `lib/`
(or any other require paths), instead of with "lib" which doesn't
exclude other potential "non requirable folder" starting with lib, like
in the `bundler` case.
https://github.com/rubygems/rubygems/commit/94df740c2b
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/dc715888d4
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/1cea3d4dce
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
When bundler is installed as a default gem (either by ruby's or by
rubygems' installer), bundler man pages wouldn't be properly found.
https://github.com/rubygems/rubygems/commit/0831b40492
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/445c9da2ac
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/28d6d77d81
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/8cc6087590
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/6ddbf5bcab
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/5106ea4582
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/fb824b7a81
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/665099fe53
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/f1a5815896
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/a43cffddad
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/b85db66e2d
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/6dc76146ad
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/a0880d78a8
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
`site_dir`, or `vendor_dir`, is the location where the default version
of bundler & rubygems gets installed. These folders are placed directly
in the LOAD_PATH, so they cannot hold any nested gem directory
structure. So a single copy of either rubygems or bundler can be placed
in these folders.
What the tests are actually testing is the TODO comment that I'm
removing: that installing the default copy of bundler doesn't affect any
already installed copies of bundler as regular gems.
https://github.com/rubygems/rubygems/commit/7ca8831d72
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/1d0981809a
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This is not detected by the `Performance/StringReplacement` cop, I guess
because of using constants. But still seems like a good change.
Co-authored-by: MSP-Greg <MSP-Greg@users.noreply.github.com>
https://github.com/rubygems/rubygems/commit/f862103133
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
If the class variable is set, we can skip the whole thing from the
beginning.
Co-authored-by: MSP-Greg <MSP-Greg@users.noreply.github.com>
https://github.com/rubygems/rubygems/commit/83abf3a3d4
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Co-authored-by: MSP-Greg <MSP-Greg@users.noreply.github.com>
https://github.com/rubygems/rubygems/commit/5f390478c7
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Co-authored-by: MSP-Greg <MSP-Greg@users.noreply.github.com>
https://github.com/rubygems/rubygems/commit/5f2b7474eb
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
Currently `gem uninstall --all` shows the following incorrect message
after completion:
```
INFO: Uninstalled all gems in
```
Now it shows something that actually makes sense like:
```
INFO: Uninstalled all gems in /home/deivid/Code/rubygems/tmp/test_rubygems_6986/gemhome
```
https://github.com/rubygems/rubygems/commit/8fa05e8f8c
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/1e5ef177ac
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
`@host` _could_ be `nil` at this point, but only if all the conditions
above for setting `@host` were `nil`. In that case, it is guaranteed
to `default_gem_server` metadata is `nil` since it's one of the
branches in that condition. So this code would just be setting an
already `nil` variable to `nil`. Hence, not needed.
https://github.com/rubygems/rubygems/commit/e3ccff3c5c
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
This block was a branch and variable heavy way of saying use the
user-provided host if available, or fall-back to the default host if
none of the other options match. IMO the resultant single-if condition
is clearer in intentions
https://github.com/rubygems/rubygems/commit/42dbb71cfa
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
These tests work on jruby, but the flags to the system command used to
detect whether `cmake` is present seem to be ignored on jruby and the
output is printed to screen instead of being sent to /dev/null. This
results in very verbose tests, like this:
```
$ rake TESTOPTS=--name=TestGemExtCmakeBuilder#test_self_build
(... warnings skipped ...)
Skipping `gem cert` tests on jruby.
Skipping Gem::Security tests on jruby.
Run options: --name=TestGemExtCmakeBuilder#test_self_build --seed 16839
# Running:
/home/deivid/Code/rubygems/test/rubygems/test_gem_ext_cmake_builder.rb:13: warning: system does not support options in JRuby yet: {:out=>"/dev/null", :err=>[:child, :out]}
Usage
cmake [options] <path-to-source>
cmake [options] <path-to-existing-build>
Specify a source directory to (re-)generate a build system for it in the
current working directory. Specify an existing build directory to
re-generate its build system.
Run 'cmake --help' for more information.
.
Finished in 0.387301s, 2.5820 runs/s, 20.6558 assertions/s.
1 runs, 8 assertions, 0 failures, 0 errors, 0 skips
Coverage report generated for Unit Tests to /home/deivid/Code/rubygems/coverage. 2258 / 8832 LOC (25.57%) covered.
```
By using `Open3`, we get the test output clean:
```
$ rake TESTOPTS=--name=TestGemExtCmakeBuilder#test_self_build
(... warnings skipped ...)
Skipping `gem cert` tests on jruby.
Skipping Gem::Security tests on jruby.
Run options: --name=TestGemExtCmakeBuilder#test_self_build --seed 22605
# Running:
.
Finished in 0.381959s, 2.6181 runs/s, 20.9446 assertions/s.
1 runs, 8 assertions, 0 failures, 0 errors, 0 skips
Coverage report generated for Unit Tests to /home/deivid/Code/rubygems/coverage. 2258 / 8832 LOC (25.57%) covered.
```
https://github.com/rubygems/rubygems/commit/531ce37ea3
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/43819b6973
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
project sources
https://github.com/rubygems/rubygems/commit/7506f7eb07
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/5f20647ec1
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/583316bf49
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/2f072e3dc7
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/ff223d8489
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/7fbef2f0e3
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|
|
https://github.com/rubygems/rubygems/commit/cca2fccd95
Notes:
Merged: https://github.com/ruby/ruby/pull/3092
|