summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2024-07-23[DOC] Allow linking to File#path in Tempfile.createPeter Zhu
2024-07-23[DOC] Fix code formatting for Tempfile.createPeter Zhu
2024-07-22Document the reasoning behind the fix for [Bug #20641]Jean Boussier
Notes: Merged: https://github.com/ruby/ruby/pull/11219
2024-07-22bundled_gems.rb: Add a fast pathJean Boussier
[Bug #20641] `Gem::BUNDLED_GEMS.warning?` adds a lot of extra work on top of `require`. When the call end up atually loading code the overhead is somewhat marginal. However it's not uncommon for code to go some late `require` in some paths, so it's expected that calling `require` with something already required is somewhat fast, and `bundled_gems.rb` breaks this assumption. To avoid this, we can have a fast path that in most case allow to short-circuit all the heavy computations. If we extract the feature basename and it doesn't match any of the bundled gems we care about we can return very early. With this change `require 'date'` is now only 1.33x slower on Ruby 3.3.3, than it was on Ruby 3.2.2, whereas before this change it was at least 100x slower. Notes: Merged: https://github.com/ruby/ruby/pull/11208
2024-07-21[ruby/uri] Restrict constant checks to current namespace to avoid conflicts ↵Randy Stauner
with globals https://github.com/ruby/uri/commit/7a64e0245f
2024-07-19[rubygems/rubygems] Fix line comment issue for mapalpha0x00
https://github.com/rubygems/rubygems/commit/7ca06e139b
2024-07-19[ruby/uri] Also support URI::PATTERN with switch-backHiroshi SHIBATA
https://github.com/ruby/uri/commit/823697edb4
2024-07-19[ruby/uri] Added test for constant definition and remove URI::REGEXP when ↵Hiroshi SHIBATA
using RFC3986_PARSER https://github.com/ruby/uri/commit/6f616d97fc
2024-07-19[ruby/uri] URI.extract needs to pass blockHiroshi SHIBATA
If given block to URI.extract, it returns nil. https://github.com/ruby/uri/commit/984145c407
2024-07-19[ruby/uri] Added compatibility methods for RFC2396 parserHiroshi SHIBATA
https://github.com/ruby/uri/commit/bbb8a40eae
2024-07-19[ruby/uri] Added URI.parser= method for switch back to RFC2396_ParserHiroshi SHIBATA
https://github.com/ruby/uri/commit/d7dc19ad3f
2024-07-18[rubygems/rubygems] Small tweak to avoid making the same mistake againDavid Rodríguez
We checking completeness of a SpecSet, we should always ignore dependencies not relevant for the current platform, since the resolver and the lockfile ignore those too. https://github.com/rubygems/rubygems/commit/c4b0c6d84e
2024-07-18[rubygems/rubygems] Fix another removal issueDavid Rodríguez
I failed to ignore (again) specs only considered for resolution under some platforms that are not the current one. https://github.com/rubygems/rubygems/commit/b72deec57e
2024-07-18[rubygems/rubygems] Fix incorrect standalone script when default gems with ↵David Rodríguez
extensions are used https://github.com/rubygems/rubygems/commit/55649cd09b
2024-07-18[rubygems/rubygems] Fix gemspec `require_paths` type validationDavid Rodríguez
It was not properly being detected as an Array attribute, and thus not properly validated. Fixing this allows us to remove a strange `rescue` clause in Bundler. https://github.com/rubygems/rubygems/commit/4121a32408
2024-07-18[rubygems/rubygems] Warn non flattened require paths in old RubyGems ↵David Rodríguez
versions too https://github.com/rubygems/rubygems/commit/b3cdccc6fb
2024-07-18[rubygems/rubygems] Use `caller_locations` instead of splitting `caller`Nobuyoshi Nakada
Also limit caller ranges https://github.com/rubygems/rubygems/commit/a274b1af78
2024-07-18Require space between hash/content in ATX heading (#1140)Hartley McGuire
While writing some Markdown documentation for Rails, I came across an interesting case where trying to link to an instance method at the start of a line would instead parse as an H1 heading: ```markdown #response_body= ``` Expected: ```html <a href=""><code>#response_body=</code></a> ``` Actual: ```html <h1>response_body=</h1> ``` According to the CommonMark spec: > At least one space or tab is required between the # characters and the > heading’s contents, unless the heading is empty. Note that many > implementations currently do not require the space. However, the space > was required by the original ATX implementation, and it helps prevent > things like the following from being parsed as headings: > > Example 64 So while some implementations do not follow this requirement, I believe RDoc should because it makes it easy to write text similar to Example 64 (which was used in the new test) and it also enables automatically linking to instance methods at the start of a line.
2024-07-17[ruby/rdoc] Improve rubocop setupStan Lo
(https://github.com/ruby/rdoc/pull/1139) * Rename rake rubocop to rake format_generated_files * Add rubocop rules to ensure spaces are applied consistently * Improve rubocop related CI workflows https://github.com/ruby/rdoc/commit/27932d001c
2024-07-17[rubygems/rubygems] Fix another case of `bundle lock --add-platform` doing ↵David Rodríguez
nothing https://github.com/rubygems/rubygems/commit/0629e27dda
2024-07-16[ruby/irb] Group class methods under `class << self`Stan Lo
(https://github.com/ruby/irb/pull/981) https://github.com/ruby/irb/commit/cdaa356df2
2024-07-16[ruby/rdoc] Drop reimplementation of Ripper lex statenicholas a. evans
(https://github.com/ruby/rdoc/pull/1118) * Drop reimplementation of Ripper lex state This code was for ruby 2.4 compatibility, but rdoc dropped support for ruby 2.4 about three years ago, in f480b970c. This code was almost half of the lines of code in rdoc/parser/ripper_state_lex. * Remove unused Ripper constants and const_defined? This was mostly copied from the diff in @st0012's PR comment. The remaining constants have been updated to get their value directly from Ripper. Co-authored-by: Stan Lo <[email protected]> * Use Ripper::EXPR_LABEL directly Since this is only used from outside RipperStateLex, there's no longer any benefit to using the indirect reference rather than just going straight to Ripper. --------- https://github.com/ruby/rdoc/commit/dd8c216263 Co-authored-by: Stan Lo <[email protected]>
2024-07-12[ruby/reline] Fix rendering bug of nomultiline prompttomoya ishida
(https://github.com/ruby/reline/pull/730) Fix bug of `print('a'*10); Reline.readline('>')` wrong rendering https://github.com/ruby/reline/commit/c0469a12b9
2024-07-11[ruby/prism] (ruby_parser) Handle bare string in implicit concatKevin Newton
https://github.com/ruby/prism/commit/afc7c9344a
2024-07-11[ruby/prism] (ruby_parser) Match match3 nodes for regular expressionsKevin Newton
https://github.com/ruby/prism/commit/47cb73ce69
2024-07-11[ruby/prism] (ruby_parser) Reverse associativity of and and or nodesKevin Newton
https://github.com/ruby/prism/commit/073e8ba307
2024-07-11[PRISM] Use node ids for error highlightKevin Newton
2024-07-11[ruby/prism] Various cleanup for initializers and typechecksKevin Newton
https://github.com/ruby/prism/commit/86cf82794a
2024-07-11[ruby/prism] Add node ids to nodesKevin Newton
https://github.com/ruby/prism/commit/bf16ade7f9
2024-07-11[ruby/prism] Move Node#type and Node::type documentationKevin Newton
https://github.com/ruby/prism/commit/08a71f6259
2024-07-11[ruby/prism] Expose flags on every node typeKevin Newton
https://github.com/ruby/prism/commit/9f12a56fd6
2024-07-11[ruby/prism] Move location to second position for node initializersKevin Newton
https://github.com/ruby/prism/commit/4cc0eda4ca
2024-07-11[ruby/prism] Reconfigure error testsKevin Newton
https://github.com/ruby/prism/commit/fb7e1ebb7f
2024-07-11[ruby/logger] Add reraise_write_errors keyword argument to Logger and LogDeviceJeremy Evans
This allows the user to specify exception classes to treat as regular exceptions instead of being swallowed. Among other things, it is useful for having Logger work with Timeout. Fixes Ruby Bug 9115. https://github.com/ruby/logger/commit/436a7d680f
2024-07-11[ruby/open-uri] document max_redirects optionJoão Pinheiro
https://github.com/ruby/open-uri/commit/4a247e5ca1
2024-07-11[ruby/open-uri] apply default max_redirectsJoão Pinheiro
https://github.com/ruby/open-uri/commit/5d29e626bc
2024-07-11[rubygems/rubygems] fix s3 source configuration issueDmitriy Ivliev
https://github.com/rubygems/rubygems/commit/356726bd1a
2024-07-11[ruby/net-http] implement talking SSL to the proxy tooEvgeni Golov
https://bugs.ruby-lang.org/issues/16482 https://github.com/ruby/net-http/commit/ae2d83f88b
2024-07-11[ruby/net-http] Add ability to configure default settings for new connectionsfatkodima
https://github.com/ruby/net-http/commit/fed3dcd0c2
2024-07-11[ruby/net-http] net/http.rb - derive SSL_IVNAMES from SSL_ATTRIBUTESMSP-Greg
https://github.com/ruby/net-http/commit/7191bb923b
2024-07-10[rubygems/rubygems] Fix another strange error when running `bundle add` in ↵David Rodríguez
frozen mode If there's a lockfile, but it's out of sync with the Gemfile because a dependency has been deleted, and frozen mode is set, Bundler will print the following strange error: ``` $ bundle add rake , but the lockfile can't be updated because frozen mode is set You have deleted from the Gemfile: * rake (~> 13.2) Run `bundle install` elsewhere and add the updated Gemfile to version control. ``` This commit changes the error to: ``` Some dependencies were deleted from your gemfile, but the lockfile can't be updated because frozen mode is set You have deleted from the Gemfile: * rake (~> 13.2) Run `bundle install` elsewhere and add the updated Gemfile to version control. ``` https://github.com/rubygems/rubygems/commit/452da4048d
2024-07-10[rubygems/rubygems] Fix strange error when running `bundle add` with frozen ↵David Rodríguez
mode set If Gemfile is empty and there's no lockfile (situation after `bundle init`), and `frozen` is configured, running `bundle add` will result in an strange error, like this: ``` $ bundle add rake , but the lockfile can't be updated because frozen mode is set You have deleted from the Gemfile: * rake (~> 13.2) Run `bundle install` elsewhere and add the updated Gemfile to version control. ``` This commit fixes the problem to instead print https://github.com/rubygems/rubygems/commit/152331a9dc
2024-07-09[rubygems/rubygems] Fix generic platform gems getting incorrectly removed ↵David Rodríguez
when locked for a specific platform If they are already in the lockfile as the most specific variant for a platform, we shouldn't change that unless explicitly unlocking. https://github.com/rubygems/rubygems/commit/a901660498
2024-07-09[rubygems/rubygems] Refactor selecting specs from a SpecSetDavid Rodríguez
https://github.com/rubygems/rubygems/commit/bcbbff5149
2024-07-09[rubygems/rubygems] Resolve all platforms directlyDavid Rodríguez
Instead of having to do a complete pass after resolve. To do this, we add to the ruby group all the platform specs with the same dependencies as the ruby specs. https://github.com/rubygems/rubygems/commit/e50415f2a6
2024-07-09[rubygems/rubygems] Don't memoize sorted_spec_namesDavid Rodríguez
It's just for debugging and a simple method, so no need. https://github.com/rubygems/rubygems/commit/3230425a9a
2024-07-09[rubygems/rubygems] Instantiate `Resolver::SpecGroup` with explicit priorityDavid Rodríguez
https://github.com/rubygems/rubygems/commit/e2c1bc1b6c
2024-07-09[rubygems/rubygems] Let resolver consider unique specs from the beginningDavid Rodríguez
It results in more consistent error messages. https://github.com/rubygems/rubygems/commit/a4b34361cc
2024-07-08[rubygems/rubygems] Fix wrong version is commentDavid Rodríguez
This RubyGems feature is being released as 3.5.15, so we can stop monkeypatching RubyGems once support for the previous version is dropped. https://github.com/rubygems/rubygems/commit/36f146840d
2024-07-08[rubygems/rubygems] Backport binstub race condition fix to BundlerDavid Rodríguez
https://github.com/rubygems/rubygems/commit/b07e46820d