Граф коммитов

88555 Коммитов

Автор SHA1 Сообщение Дата
KJ Tsanaktsidis 96e695ad00 Fix flakiness in TestGc#test_thrashing_for_young_objects
I caught a reproduction of this test failing under rr, and was able to
replay it to isolate the failure. The call to
`before_stat_heap = GC.stat_heap` is itself allocating a hash, which in
unlucky circumstances can result in a new page being allocated and thus
`before_stats[:heap_allocated_pages]` no longer equals
`after_stats[:heap_allocated_pages]`.

The solution is to use the form of GC.stat/stat_heap which takes a hash
as an argument, and thus needs to perform no Ruby allocations itself.
2024-11-06 09:58:47 -05:00
David Rodríguez 261f5d3202 [rubygems/rubygems] Add naive infinite loop detection when fixing lockfile dependencies
https://github.com/rubygems/rubygems/commit/5e933968a2
2024-11-06 13:16:58 +00:00
David Rodríguez c79d236493 [rubygems/rubygems] Note about why we don't fix lockfile dependencies backed by installed specs
https://github.com/rubygems/rubygems/commit/6fa94b5d72
2024-11-06 13:16:58 +00:00
David Rodríguez 40a2e8e9cf [rubygems/rubygems] This is not about the lockfile anymore
https://github.com/rubygems/rubygems/commit/f2e0a72291
2024-11-06 13:16:57 +00:00
David Rodríguez 54f6b787e3 [rubygems/rubygems] Automatically fix lockfile when the API reveals missing deps
https://github.com/rubygems/rubygems/commit/92196ccfdb
2024-11-06 13:16:57 +00:00
David Rodríguez a4938e5bc0 [rubygems/rubygems] Add missing spec for materializing lockfiles with only "ruby" platform
https://github.com/rubygems/rubygems/commit/4168a7f488
2024-11-06 13:16:57 +00:00
David Rodríguez db7455ae65 [rubygems/rubygems] Check for `EndpointSpecification` exactly
https://github.com/rubygems/rubygems/commit/8fac200ded
2024-11-06 13:16:56 +00:00
David Rodríguez 3e7a43e5e8 [rubygems/rubygems] Simplify code structure
https://github.com/rubygems/rubygems/commit/a4dd06f095
2024-11-06 13:16:56 +00:00
Kazuki Yamaguchi cb49ed2660 Update ext/openssl/depend
This is a follow-up to commit e5860e5654.
2024-11-06 21:59:38 +09:00
Étienne Barrié 84a8b911c1 Store precomputed hash when there's capacity
Co-authored-by: Jean Boussier <byroot@ruby-lang.org>
2024-11-06 12:57:17 +01:00
David Rodríguez 350baed6a9 [rubygems/rubygems] Fix manifest in gem package using incorrect platform sometimes
If a gem package is built from a specification whose platform has been
modified, it will include metadata using the old platform.

This change should fix the problem by making sure `original_platform` is
always properly set.

https://github.com/rubygems/rubygems/commit/ecd5cd4547
2024-11-06 11:37:29 +00:00
David Rodríguez 8c184885b0 [rubygems/rubygems] Fix some JRuby warnings when using `bundler/setup` with Ruby's -w flag
When using the `bundler/setup` entrypoint, Bundler prints the following
warnings in JRuby in `-w` is passed to Ruby.

```
/path/to/bundler/shared_helpers.rb:10: warning: constant Bundler::WINDOWS is deprecated
/path/to/bundler/shared_helpers.rb:11: warning: constant Bundler::FREEBSD is deprecated
/path/to/bundler/lib/bundler/shared_helpers.rb:12: warning: constant Bundler::NULL is deprecated
```

This does not happen in CRuby.

This seems like a JRuby bug but we can skip it by autoloading the
constants.

https://github.com/rubygems/rubygems/commit/761ca29fa2
2024-11-06 11:37:10 +00:00
HoneyryderChuck e5860e5654 [ruby/openssl] move ractor safe macro to ossl.h
in order to import or define the RUBY_TYPED_FROZEN_SHAREABLE macro.

https://github.com/ruby/openssl/commit/b8504c2215
2024-11-06 10:17:41 +00:00
Samuel Williams 3b9896acfc
Revert "Introduce Fiber Scheduler `blocking_region` hook. (#11963)" (#12013)
This reverts some of commit 87fb44dff6.

We will rename and propose a slightly different interface.
2024-11-06 22:19:40 +13:00
git 74834fd7b1 Update default gems list at 82008d38e0 [ci skip] 2024-11-06 08:59:01 +00:00
Hiroshi SHIBATA 82008d38e0 [ruby/shellwords] Bump up v0.2.1
https://github.com/ruby/shellwords/commit/ee08b981ac
2024-11-06 08:57:59 +00:00
git 6cb433758a Update default gems list at 8f4227b664 [ci skip] 2024-11-06 08:38:49 +00:00
Hiroshi SHIBATA 8f4227b664 [ruby/open-uri] Bump up v0.5.0
https://github.com/ruby/open-uri/commit/8f5a4ef6f9
2024-11-06 08:37:52 +00:00
git 81b30797f3 Update default gems list at 0c59048b3a [ci skip] 2024-11-06 08:27:52 +00:00
Hiroshi SHIBATA 0c59048b3a [ruby/timeout] Bump up v0.4.2
https://github.com/ruby/timeout/commit/2f52522994
2024-11-06 08:26:55 +00:00
git 201e1c6c2e Update default gems list at 7d9e9eabe7 [ci skip] 2024-11-06 08:06:05 +00:00
Hiroshi SHIBATA 7d9e9eabe7 [ruby/tmpdir] Bump up v0.3.0
https://github.com/ruby/tmpdir/commit/ef9ca591cf
2024-11-06 08:05:01 +00:00
git 348e925689 Update default gems list at 7e167b3225 [ci skip] 2024-11-06 07:48:42 +00:00
Hiroshi SHIBATA 7e167b3225 [ruby/tempfile] Bump up v0.3.0
https://github.com/ruby/tempfile/commit/2ff9b3ccef
2024-11-06 07:47:49 +00:00
git 9b287d3b3b Update default gems list at a3a0c675c1 [ci skip] 2024-11-06 07:33:37 +00:00
Hiroshi SHIBATA a3a0c675c1 [ruby/yaml] Bump up v0.4.0
https://github.com/ruby/yaml/commit/5e9bfff132
2024-11-06 07:32:52 +00:00
git 6e4fcddc7f Update default gems list at 0949c586c0 [ci skip] 2024-11-06 07:10:05 +00:00
Hiroshi SHIBATA 0949c586c0 [ruby/pathname] Bump up v0.4.0
https://github.com/ruby/pathname/commit/b020cbde46
2024-11-06 07:09:08 +00:00
Hiroshi SHIBATA a2dd471d9e
macOS 15 is the stable version today 2024-11-06 15:45:32 +09:00
Nobuyoshi Nakada d71be7274b
[Bug #20873] Consider `-FIXNUM_MIN` overflow
`-FIXNUM_MIN` is usually greater than `FIXNUM_MAX` on platforms using
two's complement representation.
2024-11-06 13:31:38 +09:00
Nobuyoshi Nakada 18c3e2d9f1
Assert newly added warning in `JSON.load` 2024-11-06 12:58:21 +09:00
Nobuyoshi Nakada c690ca03f3 Ignore return value of `into_raw_fd`
Fix as the compiler orders:
```
warning: unused return value of `into_raw_fd` that must be used
   --> ../src/yjit/src/disasm.rs:123:21
    |
123 |                     file.into_raw_fd(); // keep the fd open
    |                     ^^^^^^^^^^^^^^^^^^
    |
    = note: losing the raw file descriptor may leak resources
    = note: `#[warn(unused_must_use)]` on by default
help: use `let _ = ...` to ignore the resulting value
    |
123 |                     let _ = file.into_raw_fd(); // keep the fd open
    |                     +++++++

warning: unused return value of `into_raw_fd` that must be used
  --> ../src/yjit/src/log.rs:84:21
   |
84 |                     file.into_raw_fd(); // keep the fd open
   |                     ^^^^^^^^^^^^^^^^^^
   |
   = note: losing the raw file descriptor may leak resources
help: use `let _ = ...` to ignore the resulting value
   |
84 |                     let _ = file.into_raw_fd(); // keep the fd open
   |                     +++++++
```
2024-11-06 12:37:13 +09:00
Koichi Sasada ab7ab9e450 `Warning[:strict_unused_block]`
to show unused block warning strictly.

```ruby
class C
  def f = nil
end

class D
  def f = yield
end

[C.new, D.new].each{|obj| obj.f{}}
```

In this case, `D#f` accepts a block. However `C#f` doesn't
accept a block. There are some cases passing a block with
`obj.f{}` where `obj` is `C` or `D`. To avoid warnings on
such cases, "unused block warning" will be warned only if
there is not same name which accepts a block.
On the above example, `C.new.f{}` doesn't show any warnings
because there is a same name `D#f` which accepts a block.

We call this default behavior as "relax mode".

`strict_unused_block` new warning category changes from
"relax mode" to "strict mode", we don't check same name
methods and `C.new.f{}` will be warned.

[Feature #15554]
2024-11-06 11:06:18 +09:00
Kevin Newton 4203c70dfa Allow eval to see top scope
Fixes [Bug #20856]

Co-Authored-By: Aaron Patterson <tenderlove@ruby-lang.org>
2024-11-05 17:08:35 -05:00
Jean Boussier 4120f2babd [ruby/json] Appease ruby/ruby CI
https://github.com/ruby/json/commit/bc2c970ce4
2024-11-05 18:00:36 +01:00
Jean Boussier 633f65e471 [ruby/json] Strip whitespaces
https://github.com/ruby/json/commit/e85107197b
2024-11-05 18:00:36 +01:00
Jean Boussier 9987298654 Update depend files 2024-11-05 18:00:36 +01:00
Jean Boussier ca8f21ace8 [ruby/json] Resync 2024-11-05 18:00:36 +01:00
Benoit Daloze e8522f06b5 [ruby/json] Re-enable passing test
https://github.com/ruby/json/commit/82d21f01c5
2024-11-05 18:00:36 +01:00
Jean Boussier f664e7eaab [ruby/json] Add tests for the behavior of JSON.generate with base types subclasses
Ref: https://github.com/ruby/json/pull/674
Ref: https://github.com/ruby/json/pull/668

The behavior on such case it quite unclear, the goal here is to
figure out whatever was the behavior on Cext version of `json 2.7.0`
and get all implementations to converge.

We can then decide to make them all behave differently if we so wish.

https://github.com/ruby/json/commit/614921dcef
2024-11-05 18:00:36 +01:00
Jean Boussier 2f84a02ad5 [ruby/json] Use rb_str_new_frozen
https://github.com/ruby/json/commit/90c8aaaa6a
2024-11-05 18:00:36 +01:00
Jean Boussier ed22e68379 [ruby/json] JSON::Ext::Parser mark the name cache entries when not on the heap
This is somewhat dead code as unless you are using `JSON::Parser.new`
direcltly we never allocate `JSON::Ext::Parser` anymore.

But still, we should mark all its reference in case some code out there
uses that.

Followup: #675

https://github.com/ruby/json/commit/8bf74a977b
2024-11-05 18:00:36 +01:00
Jean Boussier 241a03483c Update json gem syncing logic 2024-11-05 18:00:36 +01:00
David Rodríguez 7fe775698b [rubygems/rubygems] Test with JRuby 9.4.9.0
https://github.com/rubygems/rubygems/commit/b282668d9d
2024-11-05 16:07:25 +00:00
Matt Valentine-House 01e509c45b Remove RGENGC_FORCE_MAJOR_GC flag
[Bug #20762]
2024-11-05 15:36:34 +00:00
Nobuyoshi Nakada 74fcf43767
Use wide character startup
Mingw crt-git 12.0.0.r369.g0d4221712-1 now prohibits "command line
contains characters that are not supported in the active code page".
0d42217123/

Already Ruby builds `argv` in `rb_w32_sysinit`, instead of mswin- or
mingw-made `argv`.  Just bypass the conversion in mingw crt.
2024-11-05 23:04:49 +09:00
YO4 ed06f018bd [ruby/irb] windows does not support Process.kill("TERM", pid)
(https://github.com/ruby/irb/pull/1026)

https://github.com/ruby/irb/commit/7bbb885163
2024-11-05 13:53:41 +00:00
Jean Boussier e440268d51 Get rid of JSON benchmarks 2024-11-05 12:19:55 +01:00
Jean Boussier 1cb9f9af23 tool/sync_default_gems.rb: update json rules
`lib/json/ext/generator/state.rb` should actually be
`ext/json/lib/json/ext/generator/state.rb`
2024-11-05 12:19:55 +01:00
Yusuke Endoh 6c5a808b86 Use rb_fiber_scheduler_get() instead of rb_fiber_scheduler_current()
rb_fiber_scheduler_current() may return nil depending on whether the
scheduler is being prevented for some reason, e.g., Fiber.blocking{}.

Co-Authored-By: Samuel Williams <samuel.williams@oriontransfer.co.nz>
2024-11-05 19:48:00 +09:00