pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/parallel/R-promises
Module Name: pkgsrc
Committed By: mef
Date: Sun Jun 7 02:34:48 UTC 2026
Modified Files:
pkgsrc/parallel/R-promises: Makefile distinfo
Log Message:
(parallel/R-promises) Updated 1.3.2 to 1.5.0
# promises 1.5.0
----------------
## OpenTelemetry
promises now integrates with the otel package to provide observability
and tracing for asynchronous operations.
* `local_otel_promise_domain()` adds an OpenTelemetry span promise
domain to the local scope. This is useful for `{coro}` operations
where encapsulating the coro operations inside `with_*()` methods is
not allowed. (#179)
* `with_otel_promise_domain()` creates a promise domain that restores
the currently active OpenTelemetry span from when a call to `then()`
is executed. This enables proper tracing context across asynchronous
operations. (#173)
* `with_otel_span()` creates an OpenTelemetry span, executes the given
expression within it, and ends the span when the expression
completes. This function handles both synchronous and asynchronous
(promise-based) operations. For promises, the span is automatically
ended when the promise resolves or rejects. To access the
OpenTelemetry span within your expression, use
`otel::get_current_span()`. (#198)
## New features
* Promises are now simple classed environments rather than R6 classes. This
reduces their creation overhead by up to 10x, thereby substantially
improving performance. (#191)
## Life cycle changes
* `local_ospan_promise_domain()`, `with_ospan_async()`, and
`with_ospan_promise_domain()` are deprecated in favor of
`local_otel_promise_domain()`, `with_otel_span()`, and
`with_otel_promise_domain()` respectively. (#198)
# promises 1.4.0
----------------
## Breaking changes
* Nested promise domains now correctly invoke in reverse
order. Previously, when promise domains were nested, the outer
domain would incorrectly take precedence over the inner domain in
`wrapOnFulfilled`/`wrapOnRejected` callbacks. The innermost (most
recently added) domain now properly wraps the callback first,
ensuring that nested promise domains behave consistently with the
expected scoping behavior. (#165)
## New features
* `hybrid_then()` synchronously or asynchronously executes
success/failure callbacks based on whether the input is a promise or
a regular value. This function is useful for writing code that can
handle both synchronous and asynchronous inputs seamlessly. (#192)
* `then()` gains a `tee` parameter. When `tee = TRUE`, `then()`
ignores the return value of the callback and returns the original
value instead. This is useful for performing operations with
side-effects, particularly logging to the console or a
file. `finally()` does not support `tee` as the return value is
always ignored. (#148)
### OpenTelemetry integration
promises now integrates with the otel package to provide observability
and tracing for asynchronous operations. OpenTelemetry integration is
experimental and subject to change.
* `with_ospan_async()` creates an OpenTelemetry span, executes the
given expression within it, and ends the span. This function handles
both synchronous and asynchronous (promise-based) operations. For
promises, the span is automatically ended when the promise resolves
or rejects. To access the OpenTelemetry span within your expression,
use `otel::get_current_span()`. (#173)
* `with_ospan_promise_domain()` creates a promise domain that restores
the currently active OpenTelemetry span from when a call to `then()`
is executed. This enables proper tracing context across asynchronous
operations. (#173)
* `local_ospan_promise_domain()` adds an OpenTelemetry span promise
domain to the local scope. This is useful for `{coro}` operations
where encapsulating the coro operations inside `with_*()` methods is
not allowed. (#179)
## Minor improvements and fixes
* promises now requires R 4.1 or later. R's native pipe (`|>`) and
function shorthand (`\(x) fn(x)`) syntax are now preferred over
promise pipe methods. The promise pipe methods (`%...>%`, `%...!%`,
`%...T>%`) are now superseded in favor of the R syntax supported in
R 4.1 or later. (#148)
* `catch()` API updated from `catch(promise, onRejected, tee = FALSE)`
to `catch(promise, onRejected, ..., tee = FALSE)`. The `tee`
parameter must now be specified as a keyword argument. (#148)
* `then(tee=)` and `catch(tee=)` now require a logical value (not just a truthy value). (#156)
* promises is now a pure R package that does not require
compilation. We include a test of a C++ interface in
`inst/promise_task.cpp` that is now dynamically compiled during
testing. (#154)
* `promise_all()` performance improved by using a counter instead of
checking completion status of all promises. This changes the time
complexity from `O(n^2)` to `O(n)` for determining when all promises
are complete. (#163)
* `promise_all()` now preserves duplicate named arguments (or `.list`
entries). A result will be produced for every promise
provided. (#163)
* `promise_map()` now properly handles `NULL` values being
returned. (Thank you, @RLesur! #47)
* promises no longer imports base packages in DESCRIPTION. (Thank you,
@shikokuchuo! #186)
# promises 1.3.3
----------------
* Changed the way we create future objects to stay compatible with new
versions of `{future}`. Apparently the way we were doing it was
never idiomatic and only worked by accident. (#121)
* Fixed #122: Use `future::future(..., lazy = TRUE)` to avoid manual
capturing of state within `future_promise` (Thank you,
@HenrikBengtsson! #123)
To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 pkgsrc/parallel/R-promises/Makefile \
pkgsrc/parallel/R-promises/distinfo
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/parallel/R-promises/Makefile
diff -u pkgsrc/parallel/R-promises/Makefile:1.5 pkgsrc/parallel/R-promises/Makefile:1.6
--- pkgsrc/parallel/R-promises/Makefile:1.5 Sun Jun 7 02:03:26 2026
+++ pkgsrc/parallel/R-promises/Makefile Sun Jun 7 02:34:48 2026
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.5 2026/06/07 02:03:26 mef Exp $
+# $NetBSD: Makefile,v 1.6 2026/06/07 02:34:48 mef Exp $
R_PKGNAME= promises
-R_PKGVER= 1.3.2
+R_PKGVER= 1.5.0
CATEGORIES= parallel
MAINTAINER= pkgsrc-users%NetBSD.org@localhost
@@ -9,7 +9,9 @@ COMMENT= Abstractions for promise-based
LICENSE= mit
DEPENDS+= R-fastmap-[0-9]*:../../devel/R-fastmap
+DEPENDS+= R-lifecycle-[0-9]*:../../devel/R-lifecycle
DEPENDS+= R-magrittr>=1.5:../../devel/R-magrittr
+DEPENDS+= R-otel-[0-9]*:../../devel/R-otel
DEPENDS+= R-rlang>=0.4.0:../../devel/R-rlang
DEPENDS+= R-R6-[0-9]*:../../devel/R-R6
@@ -35,4 +37,3 @@ pre-configure:
.include "../../devel/R-Rcpp/buildlink3.mk"
.include "../../sysutils/R-later/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
-.include "../../mk/bsd.prefs.mk"
Index: pkgsrc/parallel/R-promises/distinfo
diff -u pkgsrc/parallel/R-promises/distinfo:1.5 pkgsrc/parallel/R-promises/distinfo:1.6
--- pkgsrc/parallel/R-promises/distinfo:1.5 Wed Jan 1 12:23:40 2025
+++ pkgsrc/parallel/R-promises/distinfo Sun Jun 7 02:34:48 2026
@@ -1,5 +1,5 @@
-$NetBSD: distinfo,v 1.5 2025/01/01 12:23:40 mef Exp $
+$NetBSD: distinfo,v 1.6 2026/06/07 02:34:48 mef Exp $
-BLAKE2s (R/promises_1.3.2.tar.gz) = ab0a9fdf797fff4c55435d73ec2776b6d4d578266591f84037182d8e584988c6
-SHA512 (R/promises_1.3.2.tar.gz) = d57ff69f7ef5e0096143b45bd1bb9c67e0e4021e93434745f33ab375440b7a62dae337fd4047884092e5c0405ea88355d50b4945588d828a81addf678d016719
-Size (R/promises_1.3.2.tar.gz) = 3168224 bytes
+BLAKE2s (R/promises_1.5.0.tar.gz) = 13a3c7e5ce7986c618bdfbc7d1ed7b235675f34a14682da055b877cb90205139
+SHA512 (R/promises_1.5.0.tar.gz) = 6b3d26d16a0e9d130a07cec406f6534d97460eabd6a2ea46ea68787e790cc46ee0544e499d86907073dca8e6de75954b04f59034b3f5aff712f3c44152d79b4f
+Size (R/promises_1.5.0.tar.gz) = 3210294 bytes
Home |
Main Index |
Thread Index |
Old Index