<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/uri/test_common.rb, branch v4.0.2</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>[ruby/uri] Switch a parsing behavior completely when switching a parser</title>
<updated>2025-10-31T01:38:16+00:00</updated>
<author>
<name>yuuji.yaginuma</name>
<email>yuuji.yaginuma@gmail.com</email>
</author>
<published>2025-04-13T22:55:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=1dce0ae55a58aa11baf25e9ff92b64974e673361'/>
<id>1dce0ae55a58aa11baf25e9ff92b64974e673361</id>
<content type='text'>
Currently, some methods' behavior(e.g. `URI.parse`) don't change
when switching a parser. This is because some methods use
`DEFAULT_PARSER`, but `parser=` doesn't change `DEFAULT_PARSER`.

This PR introduces a constant to keep a parser's instance and
change it when switching a parser. Also, change to use it in
methods.

https://github.com/ruby/uri/commit/aded210709
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently, some methods' behavior(e.g. `URI.parse`) don't change
when switching a parser. This is because some methods use
`DEFAULT_PARSER`, but `parser=` doesn't change `DEFAULT_PARSER`.

This PR introduces a constant to keep a parser's instance and
change it when switching a parser. Also, change to use it in
methods.

https://github.com/ruby/uri/commit/aded210709
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Escape reserved characters in scheme name</title>
<updated>2025-06-26T01:39:19+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-01-23T12:19:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=42f753d829d564c0c787741995a2c0dd3be51fd8'/>
<id>42f753d829d564c0c787741995a2c0dd3be51fd8</id>
<content type='text'>
Fix https://github.com/ruby/uri/pull/89

https://github.com/ruby/uri/commit/d543c0dafa
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix https://github.com/ruby/uri/pull/89

https://github.com/ruby/uri/commit/d543c0dafa
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Revert "Alias value or join to take in old Ruby"</title>
<updated>2025-06-04T05:35:09+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2025-06-04T05:33:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a88ff325594d97821ef06db609c6b500b707e295'/>
<id>a88ff325594d97821ef06db609c6b500b707e295</id>
<content type='text'>
This reverts commit https://github.com/ruby/uri/commit/443ed0cf8540.

https://github.com/ruby/uri/commit/9e51838a04
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit https://github.com/ruby/uri/commit/443ed0cf8540.

https://github.com/ruby/uri/commit/9e51838a04
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Alias value or join to take in old Ruby</title>
<updated>2025-06-03T08:40:46+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2025-06-03T07:55:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=a79e9ab3907160054386b597e79c8ef6c60faf16'/>
<id>a79e9ab3907160054386b597e79c8ef6c60faf16</id>
<content type='text'>
https://github.com/ruby/uri/commit/443ed0cf85
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/uri/commit/443ed0cf85
</pre>
</div>
</content>
</entry>
<entry>
<title>`Ractor::Port`</title>
<updated>2025-05-30T19:01:33+00:00</updated>
<author>
<name>Koichi Sasada</name>
<email>ko1@atdot.net</email>
</author>
<published>2025-05-26T18:58:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ef2bb61018cd9ccb5b61a3d91911e04a773da4a7'/>
<id>ef2bb61018cd9ccb5b61a3d91911e04a773da4a7</id>
<content type='text'>
* Added `Ractor::Port`
  * `Ractor::Port#receive` (support multi-threads)
  * `Rcator::Port#close`
  * `Ractor::Port#closed?`
* Added some methods
  * `Ractor#join`
  * `Ractor#value`
  * `Ractor#monitor`
  * `Ractor#unmonitor`
* Removed some methods
  * `Ractor#take`
  * `Ractor.yield`
* Change the spec
  * `Racotr.select`

You can wait for multiple sequences of messages with `Ractor::Port`.

```ruby
ports = 3.times.map{ Ractor::Port.new }
ports.map.with_index do |port, ri|
  Ractor.new port,ri do |port, ri|
    3.times{|i| port &lt;&lt; "r#{ri}-#{i}"}
  end
end

p ports.each{|port| pp 3.times.map{port.receive}}

```

In this example, we use 3 ports, and 3 Ractors send messages to them respectively.
We can receive a series of messages from each port.

You can use `Ractor#value` to get the last value of a Ractor's block:

```ruby
result = Ractor.new do
  heavy_task()
end.value
```

You can wait for the termination of a Ractor with `Ractor#join` like this:

```ruby
Ractor.new do
  some_task()
end.join
```

`#value` and `#join` are similar to `Thread#value` and `Thread#join`.

To implement `#join`, `Ractor#monitor` (and `Ractor#unmonitor`) is introduced.

This commit changes `Ractor.select()` method.
It now only accepts ports or Ractors, and returns when a port receives a message or a Ractor terminates.

We removes `Ractor.yield` and `Ractor#take` because:
* `Ractor::Port` supports most of similar use cases in a simpler manner.
* Removing them significantly simplifies the code.

We also change the internal thread scheduler code (thread_pthread.c):
* During barrier synchronization, we keep the `ractor_sched` lock to avoid deadlocks.
  This lock is released by `rb_ractor_sched_barrier_end()`
  which is called at the end of operations that require the barrier.
* fix potential deadlock issues by checking interrupts just before setting UBF.

https://bugs.ruby-lang.org/issues/21262
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Added `Ractor::Port`
  * `Ractor::Port#receive` (support multi-threads)
  * `Rcator::Port#close`
  * `Ractor::Port#closed?`
* Added some methods
  * `Ractor#join`
  * `Ractor#value`
  * `Ractor#monitor`
  * `Ractor#unmonitor`
* Removed some methods
  * `Ractor#take`
  * `Ractor.yield`
* Change the spec
  * `Racotr.select`

You can wait for multiple sequences of messages with `Ractor::Port`.

```ruby
ports = 3.times.map{ Ractor::Port.new }
ports.map.with_index do |port, ri|
  Ractor.new port,ri do |port, ri|
    3.times{|i| port &lt;&lt; "r#{ri}-#{i}"}
  end
end

p ports.each{|port| pp 3.times.map{port.receive}}

```

In this example, we use 3 ports, and 3 Ractors send messages to them respectively.
We can receive a series of messages from each port.

You can use `Ractor#value` to get the last value of a Ractor's block:

```ruby
result = Ractor.new do
  heavy_task()
end.value
```

You can wait for the termination of a Ractor with `Ractor#join` like this:

```ruby
Ractor.new do
  some_task()
end.join
```

`#value` and `#join` are similar to `Thread#value` and `Thread#join`.

To implement `#join`, `Ractor#monitor` (and `Ractor#unmonitor`) is introduced.

This commit changes `Ractor.select()` method.
It now only accepts ports or Ractors, and returns when a port receives a message or a Ractor terminates.

We removes `Ractor.yield` and `Ractor#take` because:
* `Ractor::Port` supports most of similar use cases in a simpler manner.
* Removing them significantly simplifies the code.

We also change the internal thread scheduler code (thread_pthread.c):
* During barrier synchronization, we keep the `ractor_sched` lock to avoid deadlocks.
  This lock is released by `rb_ractor_sched_barrier_end()`
  which is called at the end of operations that require the barrier.
* fix potential deadlock issues by checking interrupts just before setting UBF.

https://bugs.ruby-lang.org/issues/21262
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Suppress deprecate warning of test class (retry)</title>
<updated>2024-11-26T10:02:58+00:00</updated>
<author>
<name>Yusuke Endoh</name>
<email>mame@ruby-lang.org</email>
</author>
<published>2024-11-26T10:02:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=16d98dc3c14675295ecb0945d0464c02a66453a7'/>
<id>16d98dc3c14675295ecb0945d0464c02a66453a7</id>
<content type='text'>
(https://github.com/ruby/uri/pull/140)

A follow-up to https://github.com/ruby/uri/commit/bd2e4be9d0fa

Also, leave a comment that the use of `URI::REGEXP` is intentional

https://github.com/ruby/uri/commit/bdf765e44a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/uri/pull/140)

A follow-up to https://github.com/ruby/uri/commit/bd2e4be9d0fa

Also, leave a comment that the use of `URI::REGEXP` is intentional

https://github.com/ruby/uri/commit/bdf765e44a
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Suppress deprecate warning of test class and use EnvUtil.suppress_warning.</title>
<updated>2024-11-26T03:32:01+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2024-11-26T01:47:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8655b9f7c644b023036c8745e3b26ed541af2325'/>
<id>8655b9f7c644b023036c8745e3b26ed541af2325</id>
<content type='text'>
https://github.com/ruby/uri/commit/bd2e4be9d0
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/uri/commit/bd2e4be9d0
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Revert "Prevent a warning: URI::REGEXP is obsolete</title>
<updated>2024-11-26T03:32:01+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2024-11-26T01:32:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=1d9dc4c5044c056d9c3ec61aafde9905dba49a67'/>
<id>1d9dc4c5044c056d9c3ec61aafde9905dba49a67</id>
<content type='text'>
(https://github.com/ruby/uri/pull/138)"

This reverts commit https://github.com/ruby/uri/commit/c00726a20a00.

https://github.com/ruby/uri/commit/22f5a7a790
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/uri/pull/138)"

This reverts commit https://github.com/ruby/uri/commit/c00726a20a00.

https://github.com/ruby/uri/commit/22f5a7a790
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Prevent a warning: URI::REGEXP is obsolete</title>
<updated>2024-11-25T07:28:52+00:00</updated>
<author>
<name>Yusuke Endoh</name>
<email>mame@ruby-lang.org</email>
</author>
<published>2024-11-25T07:28:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=da8f55401174408bda4823f5ac52adfc38a92b0e'/>
<id>da8f55401174408bda4823f5ac52adfc38a92b0e</id>
<content type='text'>
(https://github.com/ruby/uri/pull/138)

https://github.com/ruby/uri/commit/c00726a20a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/uri/pull/138)

https://github.com/ruby/uri/commit/c00726a20a
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/uri] Removed duplicated declare step for constants under the URI::RFC2396_REGEXP::PATTERN</title>
<updated>2024-11-14T02:20:04+00:00</updated>
<author>
<name>Hiroshi SHIBATA</name>
<email>hsbt@ruby-lang.org</email>
</author>
<published>2024-11-13T03:02:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=1bab8bf88fdd23d9a86131a43fac7736c88e4608'/>
<id>1bab8bf88fdd23d9a86131a43fac7736c88e4608</id>
<content type='text'>
https://github.com/ruby/uri/commit/60a8bc1575
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/uri/commit/60a8bc1575
</pre>
</div>
</content>
</entry>
</feed>
