| Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
Fixes https://github.com/Shopify/ruby/issues/902
This pull request adds code generation for dividing fixnums.
Testing confirms the normal case, flooring, and side-exiting on division by zero.
|
|
|
|
|
|
(cherry picked from commit https://github.com/ruby/rubygems/commit/f3e5ebf5afe7)
https://github.com/ruby/rubygems/commit/583b0222ad
|
|
(cherry picked from commit https://github.com/ruby/rubygems/commit/26c1db5a65a8)
https://github.com/ruby/rubygems/commit/bbb5b767d0
|
|
|
|
- Define the error constants.
- Use system calls to copy files if available.
- Simplify fallback copying.
- Copy without stdio buffering.
|
|
once and without exceptions
* See discussion in https://github.com/ruby/net-http/pull/224
* This check is known to work on at least CRuby, TruffleRuby and JRuby.
* Exceptions show up with `ruby -d`/`$DEBUG == true` and would show for every Net::HTTP instance.
https://github.com/ruby/net-http/commit/8c76f92779
|
|
|
|
|
|
When you have a heredoc interpolated into another heredoc where
the inner heredoc is terminated by a newline, you need to avoid
adding the newline character a second time.
https://github.com/ruby/prism/commit/8eeb5f358b
|
|
If a block exit has a further block exit in its subtree, we need to
keep recursing.
https://github.com/ruby/prism/commit/855d81a4a8
|
|
When there is an invalid syntax tree, we need to make sure to fill
in the required call operator location.
https://github.com/ruby/prism/commit/937313d7f0
|
|
https://github.com/ruby/prism/commit/0ad30561e2
|
|
When running a fresh `bundle install` with gems that contains
executables, Bundler will generate binstubs but soon after will remove
them. This is a regression introduced in https://github.com/ruby/rubygems/commit/573ffad3ea4a.
This results in doing `bundle install && bundle exec foo` to raise an
error saying `foo` couldn't be found.
This issue only appears if `BUNDLE_CLEAN` is set.
At the end of the installation process, when Bundler has installed
gems and generated binstubs, it runs the cleanup.
1. It [detects](https://github.com/ruby/rubygems/blob/4f8aa3b40cded3465bb2cd761e9ce7f8673b7fcb/bundler/lib/bundler/runtime.rb#L182) the executable for the current specs
2. Any existing executables not detected is then removed https://github.com/ruby/rubygems/blob/4f8aa3b40cded3465bb2cd761e9ce7f8673b7fcb/bundler/lib/bundler/runtime.rb#L194.
The issue being that 1. now returns an empty array where as it should
return the executables of the gems from the current bundle.
The problem is in https://github.com/ruby/rubygems/commit/573ffad3ea4a where we
removed the `executables` method from the `EndpointSpecification`.
When Bundler reads the lockfile, it creates a `EndpointSpecification`
object for each spec. At this point, the EndpointSpecification doesn't
know about the `executables` of a gem. Once Bundler fetches the
`gemspec` from the remote, it swaps the the "spec" with the real one
and from here knows what executables the gem has.
Reintroduce the `executables` method and the `bindir` in the
EndpointSpecification class. From what I'm seeing, the removal
of those wasn't needed to resolve the issue where Bundler remembers
CLI flags. This is probably an oversight.
https://github.com/ruby/rubygems/commit/b47f6b0247
|
|
* It looked like:
In a future version of Bundler, running `bundle` without argument will no longer run `bundle install`.
Instead, the `cli_help` command will be displayed. Please use `bundle install` explicitly for scripts like CI/CD.
You can use the future behavior now with `bundle config set default_cli_command cli_help --global`,
or you can continue to use the current behavior with `bundle config set default_cli_command install --global`.
This message will be removed after a default_cli_command value is set.
Bundler version 4.0.0 (2025-12-08 commit https://github.com/ruby/rubygems/commit/9b4819ae18)
* And now looks like:
In a future version of Bundler, running `bundle` without argument will no longer run `bundle install`.
Instead, the `cli_help` command will be displayed. Please use `bundle install` explicitly for scripts like CI/CD.
You can use the future behavior now with `bundle config set default_cli_command cli_help --global`,
or you can continue to use the current behavior with `bundle config set default_cli_command install --global`.
This message will be removed after a default_cli_command value is set.
Bundler version 4.0.0 (2025-12-08 commit https://github.com/ruby/rubygems/commit/9b4819ae18)
https://github.com/ruby/rubygems/commit/979dada8f3
|
|
* `install_or_cli_help` does not exist for older Bundler like Bundler 2
and so results in a confusing error on Bundler 2:
```
$ bundle
Could not find command "".
```
* See https://github.com/ruby/rubygems/pull/9136/files#r2592366837
* Merge the behavior of `install_or_cli_help` in `install`.
https://github.com/ruby/rubygems/commit/9b4819ae18
|
|
`ruby2_keywords` is set only to be `0` in parse.y.
However `args->ruby2_keywords` is initialized with `0` by `MEMZERO`
in `rb_node_args_new` function and `body->param.flags.ruby2_keywords`
is initialized with `0` by `ZALLOC` in `rb_iseq_constant_body_alloc` function,
so `args->ruby2_keywords` does nothing for `body->param.flags.ruby2_keywords`.
|
|
Because `FORWARD_ARGS_WITH_RUBY2_KEYWORDS` definition was removed
by 4f77d8d3289ece0e3537d9273a5c745120bff59a.
|
|
Internal tracepoints only make sense to run globally, and they already
took completely different paths.
|
|
This solution is not quite correct because it doesn't solve multiple
Ractors subscribing to the same event, but this will avoid unrelated
events clobbering the flags for other events.
This however will work corretly for subscribing to global ObjectSpace GC
events.
|
|
|
|
|
|
|
|
|
|
installation.
https://github.com/ruby/rubygems/commit/a70e573973
|
|
If we don't have uint128, then rb_int128_to_numeric emits a strict
aliasing warning:
numeric.c:3641:39: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
3641 | return rb_uint128_to_numeric(*(rb_uint128_t*)&n);
| ^~~~~~~~~~~~~~~~~
|
|
|
|
We're seeing an occasional crash on CI because this ends up inlined all
the way into ractor_wait_receive. On llvm (possibly other compilers) the
thread local address of ec ends up cached (not the value of ec, the
address ec is read from). So if we are migrated to another native
thread, that may be invalid.
Using rb_current_ec_noinline avoids this problems. It would be good to
adjust this code so that ec (or current ractor) is calculated once and
then passed through to both lock and unlock.
|
|
|
|
This reverts commit https://github.com/ruby/timeout/commit/45816b1b2602.
https://github.com/ruby/timeout/commit/b54f91e9dd
|
|
|
|
|
|
https://github.com/ruby/resolv/commit/3678de9e30
|
|
https://github.com/ruby/resolv/commit/075e76f997
|
|
on resource limited environment.
```
stderr output is not empty
bootstraptest.test_ractor.rb_2446_1412.rb:23:in 'Ractor.new': can't create Thread: Cannot allocate memory (ThreadError)
```
|
|
Maybe because of TLS/coroutine problem, CI fails on clang-16/18
```
1) Failure:
TestTimeout#test_ractor [/tmp/ruby/src/trunk_clang_18/test/test_timeout.rb:288]:
pid 307341 killed by SIGSEGV (signal 11) (core dumped)
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:98: [BUG] Segmentation fault at 0x0000000000000030
| ruby 4.0.0dev (2025-12-07T16:51:02Z master 4f900c35bc) +PRISM [x86_64-linux]
|
| -- Control frame information -----------------------------------------------
| c:0006 p:---- s:0026 e:000025 l:y b:---- CFUNC :sleep
| c:0005 p:---- s:0023 e:000022 l:y b:---- CFUNC :wait
| c:0004 p:0020 s:0017 e:000016 l:n b:---- BLOCK /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:98 [FINISH]
| c:0003 p:---- s:0014 e:000013 l:y b:---- CFUNC :synchronize
| c:0002 p:0072 s:0010 e:000009 l:n b:---- BLOCK /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:96 [FINISH]
| c:0001 p:---- s:0003 e:000002 l:y b:---- DUMMY [FINISH]
|
| -- Ruby level backtrace information ----------------------------------------
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:96:in 'block in create_timeout_thread'
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:96:in 'synchronize'
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:98:in 'block (2 levels) in create_timeout_thread'
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:98:in 'wait'
| /tmp/ruby/src/trunk_clang_18/lib/timeout.rb:98:in 'sleep'
|
| -- Threading information ---------------------------------------------------
| Total ractor count: 3
| Ruby thread count for this ractor: 2
|
| -- Machine register context ------------------------------------------------
| RIP: 0x0000602b1e08a5b5 RBP: 0x000071c65facd130 RSP: 0x000071c6258842e0
| RAX: 0x0000000000000000 RBX: 0x000000006935f7c4 RCX: 0x0000000000000000
| RDX: 0x0000602b1e520c20 RDI: 0x000071c620012480 RSI: 0x000071c620012480
| R8: 0x0000000000000000 R9: 0x0000000000000000 R10: 0x0000000000000000
| R11: 0x0000000000000000 R12: 0x000071c65fa2f640 R13: 0x000071c65fb66e48
| R14: 0x0000000000000000 R15: 0xfdccaa3270000002 EFL: 0x0000000000010202
|
| -- C level backtrace information -------------------------------------------
| /tmp/ruby/build/trunk_clang_18/ruby(rb_print_backtrace+0x14) [0x602b1e31a6ea] /tmp/ruby/src/trunk_clang_18/vm_dump.c:1105
| /tmp/ruby/build/trunk_clang_18/ruby(rb_vm_bugreport) /tmp/ruby/src/trunk_clang_18/vm_dump.c:1450
| /tmp/ruby/build/trunk_clang_18/ruby(rb_bug_for_fatal_signal+0x15c) [0x602b1e2d960c] /tmp/ruby/src/trunk_clang_18/error.c:1131
| /tmp/ruby/build/trunk_clang_18/ruby(sigsegv+0x5a) [0x602b1e05528a] /tmp/ruby/src/trunk_clang_18/signal.c:948
| /lib/x86_64-linux-gnu/libc.so.6(0x71c65fd46320) [0x71c65fd46320]
| /tmp/ruby/build/trunk_clang_18/ruby(vm_check_ints_blocking+0x0) [0x602b1e08a5b5] /tmp/ruby/src/trunk_clang_18/vm_core.h:2097
| /tmp/ruby/build/trunk_clang_18/ruby(rb_current_execution_context) /tmp/ruby/src/trunk_clang_18/thread_sync.c:617
| /tmp/ruby/build/trunk_clang_18/ruby(rb_mutex_sleep) /tmp/ruby/src/trunk_clang_18/thread_sync.c:617
```
This patch introduces workaround by acquiring EC before swithcing coroutine.
|
|
RHEL-based systems
Add fallback to `require` when `require_relative` fails to load native
extensions. This addresses an issue on RHEL-based Linux distributions
where Ruby scripts and built native extension shared libraries are
installed in separate directories.
https://github.com/ruby/rubygems/commit/68599bd107
|
|
It is exported only for the extension library to test, but the method
is no longer used since 29e31e72fb5a14194a78ec974c4ba56c33ad8d45.
|
|
It is used only in hash.c, when `ENV['TZ']` is set.
|
|
|
|
https://github.com/ruby/timeout/commit/837d5aac73
|
|
Move these macros from include/ruby/backward.h to
include/ruby/internal/attr/deprecated.h, alongside the other similar
macros.
include/ruby/internal/intern/vm.h cannot currently use them because
include/ruby/backward.h is included too late.
|
|
The #ifdef is currently not taken because include/ruby/backward.h is
not included at this point. The attribute is unnecessary in an internal
header, so remove it.
|
|
|
|
|