core-async 0.5.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/lib/core/async/bootstrap.rb +4 -1
- data/lib/core/async/future.rb +2 -0
- data/lib/core/async/version.rb +1 -1
- data/lib/is/async.rb +13 -3
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 32453e0ff3a28813b566b881be5fc88da0143249ac9164a332218a4c94799574
|
4
|
+
data.tar.gz: cb436adf5261d76f982b032996044ac379b1487b8e504a80641cc6c80aa5ba7a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 55253a5d64873e32794e5fa9fbc7497e1db49c99eeb0f673ce4ebdc70f33360ef547d5f676c1f13b3bef1f376493659305d1329753d758e5e3fd9ea0c20794c8
|
7
|
+
data.tar.gz: 80a4872f6d51426a1518f5b904413f5ed6296382a3d508268c04df3011bc7e28feb11f01f9df58e3998bc41db9afc53597a7d117df484f8eba35011aff019ce2
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
## [v0.6.0](https://github.com/metabahn/corerb/releases/tag/2021-05-20)
|
2
|
+
|
3
|
+
*released on 2021-05-20*
|
4
|
+
|
5
|
+
* `fix` [#28](https://github.com/metabahn/corerb/pull/28) Turn off the console logger in all contexts ([bryanp](https://github.com/bryanp))
|
6
|
+
* `chg` [#27](https://github.com/metabahn/corerb/pull/27) Propagate throws from async contexts ([bryanp](https://github.com/bryanp))
|
7
|
+
|
1
8
|
## [v0.5.0](https://github.com/metabahn/corerb/releases/tag/2021-03-26)
|
2
9
|
|
3
10
|
*released on 2021-03-26*
|
data/lib/core/async/bootstrap.rb
CHANGED
data/lib/core/async/future.rb
CHANGED
data/lib/core/async/version.rb
CHANGED
data/lib/is/async.rb
CHANGED
@@ -47,6 +47,8 @@ module Is
|
|
47
47
|
}.result
|
48
48
|
}.wait
|
49
49
|
end
|
50
|
+
rescue UncaughtThrowError => error
|
51
|
+
throw error.tag, error.value
|
50
52
|
end
|
51
53
|
|
52
54
|
# [public] Call behavior within an async context without additional nesting.
|
@@ -73,16 +75,24 @@ module Is
|
|
73
75
|
#
|
74
76
|
# Raises `Core::Async::Timeout` if execution exceeds `seconds`.
|
75
77
|
#
|
76
|
-
private def timeout(seconds
|
78
|
+
private def timeout(seconds)
|
77
79
|
internal_await do |task|
|
80
|
+
timed_task = internal_async {
|
81
|
+
yield
|
82
|
+
}
|
83
|
+
|
78
84
|
if seconds && seconds > 0
|
79
85
|
task.with_timeout(seconds, Core::Async::Timeout) do
|
80
|
-
|
86
|
+
timed_task.wait
|
81
87
|
end
|
82
88
|
else
|
83
|
-
|
89
|
+
timed_task.wait
|
84
90
|
end
|
91
|
+
ensure
|
92
|
+
timed_task&.stop
|
85
93
|
end
|
94
|
+
rescue UncaughtThrowError => error
|
95
|
+
throw error.tag, error.value
|
86
96
|
end
|
87
97
|
|
88
98
|
# [public] Yields control to allow other fibers to execute.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: core-async
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bryan Powell
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-05-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: async
|
@@ -54,14 +54,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
54
54
|
requirements:
|
55
55
|
- - ">="
|
56
56
|
- !ruby/object:Gem::Version
|
57
|
-
version: 2.
|
57
|
+
version: 2.6.7
|
58
58
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
59
59
|
requirements:
|
60
60
|
- - ">="
|
61
61
|
- !ruby/object:Gem::Version
|
62
62
|
version: '0'
|
63
63
|
requirements: []
|
64
|
-
rubygems_version: 3.2.
|
64
|
+
rubygems_version: 3.2.15
|
65
65
|
signing_key:
|
66
66
|
specification_version: 4
|
67
67
|
summary: Makes Ruby objects async-aware.
|