async
async copied to clipboard
An awesome asynchronous event-driven reactor for Ruby.
@soutaro What is the process to create/add RBS to this project? I would love to add it and expose users downstream to it, and maybe catch bugs with it too!
**WIP** As discussed [here](https://github.com/socketry/async/issues/62) I introduce a new class called `Waiter` which can be a drop-in replacement `Barrier`. The only difference is that it can await for first N tasks....
There are occasions where any one of several Task activities might produce a result and only the first result matters. Ideally there's a method like `#wait_first` which can return the...
It would be interesting to explore something which can check the sanity of operations, e.g. ```ruby expect do user_code end.to_not modify_globals(except: @cache) ```
I found that the Select backend is a little bit buggy. Introduce some tests to show these issues so that they can be fixed. ### Types of Changes - Bug...
I cannot figure out why the spec in the 2nd context does not terminate: ``` RSpec.describe Spec do context 'terminates' do let(:s) { Sync { 1 } } it 'eq'...
## Description Support tracing between asynchronous tasks. ### Types of Changes - New feature. ### Testing - [ ] I added tests for my changes. - [x] I tested my...
This simple code hangs: ```ruby Async do |task| task.async do # raise TypeError # this properly raises an error sleep nil end end.wait ``` ```ruby sleep nil (irb):62:in `sleep': can't...
Given that https://github.com/ged/ruby-pg/pull/397 is merged, I'm trying to use the `async` gem with latest `ruby-pg` in Rails 7. However, it seems that I could *not* use a database connection to...
Hi, When I tried to run this, I got NoMethodError: undefined method `wait_any'... ``` require 'db/client' require 'db/postgres' client = DB::Client.new(DB::Postgres::Adapter.new(database: 'test')) def create_schema(session) session.clause("DROP TABLE IF EXISTS").identifier(:things).call session.clause("CREATE TABLE...