-
Notifications
You must be signed in to change notification settings - Fork 448
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[2743] Migrate internal use of CircuitBreaker double to duration #2748
Conversation
@mjmoore thanks for this awesome contribution, and congrats on your first contribution 👏 👏 👏 🥳 The CI is currently failing because of some changes in the public API, can you run I think we should also deprecate the @Deprecated(
"Prefer the kotlin.time.Duration constructor instead",
ReplaceWith(
"of(maxFailures, resetTimeoutNanos.nanoseconds, exponentialBackoffFactor, maxResetTimeout, onRejected, onClosed, onHalfOpen, onOpen)",
"import kotlin.time.Duration.Companion.nanoseconds"
)
)
The |
@nomisRev Thanks for the guidance! Should look a little better now 🙂 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great to me @mjmoore. Nice work 👏 👏 👏
A couple suggestions for improving the error messages for the preconditions of the constructors. Also it was missing && it != Duration.ZERO
check. If you agree with my suggestions, I think it's ready to be merged 🙌
So this is probably also missing tests. Would be great if you don't mind adding one, but not a blocker for this PR ;)
arrow-libs/fx/arrow-fx-coroutines/src/commonMain/kotlin/arrow/fx/coroutines/CircuitBreaker.kt
Outdated
Show resolved
Hide resolved
arrow-libs/fx/arrow-fx-coroutines/src/commonMain/kotlin/arrow/fx/coroutines/CircuitBreaker.kt
Outdated
Show resolved
Hide resolved
arrow-libs/fx/arrow-fx-coroutines/src/commonMain/kotlin/arrow/fx/coroutines/CircuitBreaker.kt
Outdated
Show resolved
Hide resolved
arrow-libs/fx/arrow-fx-coroutines/src/commonMain/kotlin/arrow/fx/coroutines/CircuitBreaker.kt
Outdated
Show resolved
Hide resolved
a5ed622
to
bc06e65
Compare
@nomisRev Thanks for the comments!
|
public fun equals (Ljava/lang/Object;)Z | ||
public final fun getResetTimeoutNanos ()D | ||
public final fun getResetTimeout-UwyO8pc ()J |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we redump the api file, just to check if that hash goes away?
It seems that every time we use Duration it produces this binary output and changes the descriptor Name for instance here https://github.com/nomisRev/ArrowDokkaTest/blob/507f6addb1e379f84aa4257d14b002fc4fcfac7f/arrow-libs/fx/arrow-fx-coroutines/api/arrow-fx-coroutines.api#L57
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mjmoore 🙌🏾
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the contribution @mjmoore! 🙏 Was my pleasure to work together ;)
ConstructorValues(maxResetTimeout = Duration.ZERO), | ||
ConstructorValues(maxResetTimeout = (-1).seconds), | ||
).forEach { value -> | ||
"should require valid constructor values" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome!
7d7c7e8
to
9c1dcc4
Compare
binary breaking change in HalfOpen and Open public resetTimeOut variable
arrow-libs/fx/arrow-fx-coroutines/src/commonMain/kotlin/arrow/fx/coroutines/CircuitBreaker.kt
Outdated
Show resolved
Hide resolved
@mjmoore Sorry for the long wait. I had a busy week, but I was finally able to dedicate some time to this again. We should really maintain binary compatibility so we don't break libraries depending on older 1.x.x versions of Arrow, Feel free to copy the changes, or cherry-pick this commit whatever makes most sense for you 👍 |
PS: @i-walker this fixes the binary compat issues. Thanks for watching out for this 🙏 |
b70babd
to
d31cf29
Compare
Hey @mjmoore, awesome! 🙌 I'll review it asap 😊 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mjmoore 🙌🏾
71b0e11
to
d296cc9
Compare
Hey @nomisRev, looks like the previous build failed due to a timeout when configuring |
Hey @mjmoore, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for @mjmoore for your first-contribution 🥳
Really nice work venturing in Arrow Fx straight away 🙌
Apologies that it took so long to get your contribution in, and thanks for your patience 🙏
* Add Resource.allocated() to decompose Resource into it's allocate and… (#2820) * [2743] Migrate internal use of CircuitBreaker double to duration (#2748) * Fix typo (#2824) * Make the server disconnect test more general (#2822) * Update NonEmptyList.fromList deprecation to suggest `toOption()` instead (#2832) * Improve Either.getOrHandle() docs (#2833) * Improve allocated, and fix knit examples Co-authored-by: Jeff Martin <jeff@custommonkey.org> Co-authored-by: Martin Moore <martinmoorej@gmail.com> Co-authored-by: valery1707 <valery1707@gmail.com> Co-authored-by: Lukasz Kalnik <70261110+lukasz-kalnik-gcx@users.noreply.github.com> Co-authored-by: stylianosgakis <stylianos.gakis98@gmail.com>
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [io.arrow-kt:arrow-fx-coroutines](https://github.com/arrow-kt/arrow) | `1.1.3` -> `1.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/io.arrow-kt:arrow-fx-coroutines/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/io.arrow-kt:arrow-fx-coroutines/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/io.arrow-kt:arrow-fx-coroutines/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/io.arrow-kt:arrow-fx-coroutines/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [io.arrow-kt:arrow-optics-ksp-plugin](https://github.com/arrow-kt/arrow) | `1.1.3` -> `1.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/io.arrow-kt:arrow-optics-ksp-plugin/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/io.arrow-kt:arrow-optics-ksp-plugin/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/io.arrow-kt:arrow-optics-ksp-plugin/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/io.arrow-kt:arrow-optics-ksp-plugin/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [io.arrow-kt:arrow-optics](https://github.com/arrow-kt/arrow) | `1.1.3` -> `1.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/io.arrow-kt:arrow-optics/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/io.arrow-kt:arrow-optics/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/io.arrow-kt:arrow-optics/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/io.arrow-kt:arrow-optics/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [io.arrow-kt:arrow-core](https://github.com/arrow-kt/arrow) | `1.1.3` -> `1.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/io.arrow-kt:arrow-core/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/io.arrow-kt:arrow-core/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/io.arrow-kt:arrow-core/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/io.arrow-kt:arrow-core/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [io.arrow-kt:arrow-stack](https://github.com/arrow-kt/arrow) | `1.1.3` -> `1.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/io.arrow-kt:arrow-stack/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/io.arrow-kt:arrow-stack/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/io.arrow-kt:arrow-stack/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/io.arrow-kt:arrow-stack/1.1.3/1.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### ⚠ Dependency Lookup Warnings ⚠ Warnings were logged while processing this repo. Please check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>arrow-kt/arrow (io.arrow-kt:arrow-fx-coroutines)</summary> ### [`v1.2.0`](https://github.com/arrow-kt/arrow/releases/tag/1.2.0) [Compare Source](https://github.com/arrow-kt/arrow/compare/1.1.5...1.2.0) ##### What's Changed - Add CNAME file to Dokka output by [@​franciscodr](https://github.com/franciscodr) in [https://github.com/arrow-kt/arrow/pull/3029](https://github.com/arrow-kt/arrow/pull/3029) - Remove legacy site code by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3030](https://github.com/arrow-kt/arrow/pull/3030) - Update README by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3033](https://github.com/arrow-kt/arrow/pull/3033) - Cancel previous PR action on new commit by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3032](https://github.com/arrow-kt/arrow/pull/3032) - Remove legacy script files by [@​franciscodr](https://github.com/franciscodr) in [https://github.com/arrow-kt/arrow/pull/3034](https://github.com/arrow-kt/arrow/pull/3034) - Ensure optics type with "data" modifier is a class by [@​DeoTimeTheGithubUser](https://github.com/DeoTimeTheGithubUser) in [https://github.com/arrow-kt/arrow/pull/3036](https://github.com/arrow-kt/arrow/pull/3036) - Update all dependencies (major) by [@​renovate](https://github.com/renovate) in [https://github.com/arrow-kt/arrow/pull/3042](https://github.com/arrow-kt/arrow/pull/3042) - Remove test dependency from Arrow Fx by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3046](https://github.com/arrow-kt/arrow/pull/3046) - Bump Kotlin, KSP and coroutines version by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3047](https://github.com/arrow-kt/arrow/pull/3047) - fix mapIndexed when collecting multiple times by [@​hoc081098](https://github.com/hoc081098) in [https://github.com/arrow-kt/arrow/pull/3056](https://github.com/arrow-kt/arrow/pull/3056) - Update versions by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3058](https://github.com/arrow-kt/arrow/pull/3058) - optics ksp plugin: fixed handling of variance ([#​3057](https://github.com/arrow-kt/arrow/issues/3057)) by [@​vladd-g](https://github.com/vladd-g) in [https://github.com/arrow-kt/arrow/pull/3060](https://github.com/arrow-kt/arrow/pull/3060) - Fixes recover inconsistency with raise DSL on types other than Either by [@​yoxjames](https://github.com/yoxjames) in [https://github.com/arrow-kt/arrow/pull/3052](https://github.com/arrow-kt/arrow/pull/3052) - Change NonEmptySet type parameter name from T to A by [@​franciscodr](https://github.com/franciscodr) in [https://github.com/arrow-kt/arrow/pull/3062](https://github.com/arrow-kt/arrow/pull/3062) - Add withError and (Eager)Effect.mapError by [@​kyay10](https://github.com/kyay10) in [https://github.com/arrow-kt/arrow/pull/3059](https://github.com/arrow-kt/arrow/pull/3059) - Update versions of several libraries by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3017](https://github.com/arrow-kt/arrow/pull/3017) - Add merge builder for raise by [@​kyay10](https://github.com/kyay10) in [https://github.com/arrow-kt/arrow/pull/3061](https://github.com/arrow-kt/arrow/pull/3061) - Update all dependencies by [@​renovate](https://github.com/renovate) in [https://github.com/arrow-kt/arrow/pull/3065](https://github.com/arrow-kt/arrow/pull/3065) - Update dependency gradle to v8.2 by [@​renovate](https://github.com/renovate) in [https://github.com/arrow-kt/arrow/pull/3070](https://github.com/arrow-kt/arrow/pull/3070) - Fix warnings of single-subclass sealed classes by [@​jooohn](https://github.com/jooohn) in [https://github.com/arrow-kt/arrow/pull/3067](https://github.com/arrow-kt/arrow/pull/3067) - KDoc for `Raise#raise`, `Raise#ensure` and `Raise#ensureNotNull` by [@​ILIYANGERMANOV](https://github.com/ILIYANGERMANOV) in [https://github.com/arrow-kt/arrow/pull/3038](https://github.com/arrow-kt/arrow/pull/3038) - Fix text repetition in EffectScope's deprecation message by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3072](https://github.com/arrow-kt/arrow/pull/3072) - Introduce `NonEmptyCollection` by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3068](https://github.com/arrow-kt/arrow/pull/3068) - Set up Spotless by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3075](https://github.com/arrow-kt/arrow/pull/3075) - Update all dependencies by [@​renovate](https://github.com/renovate) in [https://github.com/arrow-kt/arrow/pull/3079](https://github.com/arrow-kt/arrow/pull/3079) - Add option to disable `inline` when using `@optics` by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3078](https://github.com/arrow-kt/arrow/pull/3078) - Update JS versions in `yarn.lock` by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3084](https://github.com/arrow-kt/arrow/pull/3084) - Enable Automatic Modules for JVM by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3071](https://github.com/arrow-kt/arrow/pull/3071) - Serialization module by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3077](https://github.com/arrow-kt/arrow/pull/3077) - Add missing docs for `Raise` operations by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3082](https://github.com/arrow-kt/arrow/pull/3082) - Add mapOrAccumulate extension in RaiseAccumulate by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3086](https://github.com/arrow-kt/arrow/pull/3086) - Additional tests for `copy` in Optics by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3089](https://github.com/arrow-kt/arrow/pull/3089) - Apply Gradle Versioning in top project by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3092](https://github.com/arrow-kt/arrow/pull/3092) - Add missing Versioning plug-in to `arrow-core-retrofit` by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3093](https://github.com/arrow-kt/arrow/pull/3093) - Update `arrow-gradle-config` to 0.12-rc.4 by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3094](https://github.com/arrow-kt/arrow/pull/3094) - MemoizedDeepRecursiveFunction by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/3091](https://github.com/arrow-kt/arrow/pull/3091) - Add reset and barrierAction to CyclicBarrier. by [@​HSAR](https://github.com/HSAR) in [https://github.com/arrow-kt/arrow/pull/3055](https://github.com/arrow-kt/arrow/pull/3055) - \[HOTFIX] Fix main publish by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/3095](https://github.com/arrow-kt/arrow/pull/3095) ##### New Contributors - [@​DeoTimeTheGithubUser](https://github.com/DeoTimeTheGithubUser) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3036](https://github.com/arrow-kt/arrow/pull/3036) - [@​vladd-g](https://github.com/vladd-g) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3060](https://github.com/arrow-kt/arrow/pull/3060) - [@​yoxjames](https://github.com/yoxjames) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3052](https://github.com/arrow-kt/arrow/pull/3052) - [@​kyay10](https://github.com/kyay10) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3059](https://github.com/arrow-kt/arrow/pull/3059) - [@​jooohn](https://github.com/jooohn) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3067](https://github.com/arrow-kt/arrow/pull/3067) - [@​ILIYANGERMANOV](https://github.com/ILIYANGERMANOV) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3038](https://github.com/arrow-kt/arrow/pull/3038) - [@​HSAR](https://github.com/HSAR) made their first contribution in [https://github.com/arrow-kt/arrow/pull/3055](https://github.com/arrow-kt/arrow/pull/3055) **Full Changelog**: arrow-kt/arrow@1.2.0-RC...1.2.0 ### [`v1.1.5`](https://github.com/arrow-kt/arrow/releases/tag/1.1.5) [Compare Source](https://github.com/arrow-kt/arrow/compare/1.1.4...1.1.5) #### What's Changed - Remove `test` modules by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2874](https://github.com/arrow-kt/arrow/pull/2874) - Mention Arrow 2.0 in README by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2878](https://github.com/arrow-kt/arrow/pull/2878) - Prisms for Either by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2877](https://github.com/arrow-kt/arrow/pull/2877) - Test 1.8.0 on CI by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2864](https://github.com/arrow-kt/arrow/pull/2864) - Implement 'align' using 'buildList' by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2886](https://github.com/arrow-kt/arrow/pull/2886) - Improve debugging experience of leaked shift calls by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2884](https://github.com/arrow-kt/arrow/pull/2884) - Fix knitCheck & re-add check by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2887](https://github.com/arrow-kt/arrow/pull/2887) **Full Changelog**: arrow-kt/arrow@1.1.4...1.1.5 ### [`v1.1.4`](https://github.com/arrow-kt/arrow/releases/tag/1.1.4) [Compare Source](https://github.com/arrow-kt/arrow/compare/1.1.3...1.1.4) #### What's Changed - \[2743] Migrate internal use of CircuitBreaker double to duration by [@​mjmoore](https://github.com/mjmoore) in [https://github.com/arrow-kt/arrow/pull/2748](https://github.com/arrow-kt/arrow/pull/2748) - Fix typo by [@​valery1707](https://github.com/valery1707) in [https://github.com/arrow-kt/arrow/pull/2824](https://github.com/arrow-kt/arrow/pull/2824) - Make the server disconnect test more general by [@​lukasz-kalnik-gcx](https://github.com/lukasz-kalnik-gcx) in [https://github.com/arrow-kt/arrow/pull/2822](https://github.com/arrow-kt/arrow/pull/2822) - Update NonEmptyList.fromList deprecation to suggest `toOption()` instead by [@​StylianosGakis](https://github.com/StylianosGakis) in [https://github.com/arrow-kt/arrow/pull/2832](https://github.com/arrow-kt/arrow/pull/2832) - Improve Either.getOrHandle() docs by [@​lukasz-kalnik-gcx](https://github.com/lukasz-kalnik-gcx) in [https://github.com/arrow-kt/arrow/pull/2833](https://github.com/arrow-kt/arrow/pull/2833) - Correct `addressStrees` -> `addressStreet` in optics documentation by [@​vikrem](https://github.com/vikrem) in [https://github.com/arrow-kt/arrow/pull/2836](https://github.com/arrow-kt/arrow/pull/2836) - Arrow Fx: deprecate Platform#composeError, never and unit() by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2837](https://github.com/arrow-kt/arrow/pull/2837) - Backport Optics KSP plugin NPE on multiplatform fix by [@​cvb941](https://github.com/cvb941) in [https://github.com/arrow-kt/arrow/pull/2840](https://github.com/arrow-kt/arrow/pull/2840) - Refactor - [#​2812](https://github.com/arrow-kt/arrow/issues/2812) sequence separate performance by [@​Khepu](https://github.com/Khepu) in [https://github.com/arrow-kt/arrow/pull/2818](https://github.com/arrow-kt/arrow/pull/2818) - Use `super` equals and hashCode overrides for NonEmptyList by [@​RusticFlare](https://github.com/RusticFlare) in [https://github.com/arrow-kt/arrow/pull/2825](https://github.com/arrow-kt/arrow/pull/2825) - Resource API deprecation, and preparation for 2.x.x. & back port improvements by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2847](https://github.com/arrow-kt/arrow/pull/2847) - introduce iterable.toNonEmptyListOrNone() by [@​myuwono](https://github.com/myuwono) in [https://github.com/arrow-kt/arrow/pull/2843](https://github.com/arrow-kt/arrow/pull/2843) - \[PROPOSAL] Either API deprecation, and preparation for 2.x.x by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2830](https://github.com/arrow-kt/arrow/pull/2830) - Use major versions in GitHub Actions by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2849](https://github.com/arrow-kt/arrow/pull/2849) - Weaken Either monoid dependencies to only require a semigroup on left by [@​mjvmroz](https://github.com/mjvmroz) in [https://github.com/arrow-kt/arrow/pull/2845](https://github.com/arrow-kt/arrow/pull/2845) - Do not reuse the name of the file in Optics KSP by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2850](https://github.com/arrow-kt/arrow/pull/2850) - Additional deprecations, and backports for JVM by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2856](https://github.com/arrow-kt/arrow/pull/2856) - Update various versions by [@​serras](https://github.com/serras) in [https://github.com/arrow-kt/arrow/pull/2852](https://github.com/arrow-kt/arrow/pull/2852) - Add CountDownLatch by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2854](https://github.com/arrow-kt/arrow/pull/2854) - Add CyclicBarrier by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2857](https://github.com/arrow-kt/arrow/pull/2857) - Temp rollback error handling deprecations until 1.2.x by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2858](https://github.com/arrow-kt/arrow/pull/2858) - Setup Kover as test coverage tool by [@​MarkMarkyMarkus](https://github.com/MarkMarkyMarkus) in [https://github.com/arrow-kt/arrow/pull/2793](https://github.com/arrow-kt/arrow/pull/2793) - Fix Monad.either binary combat by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2867](https://github.com/arrow-kt/arrow/pull/2867) - Backport: MPP No Trace by [@​nomisRev](https://github.com/nomisRev) in [https://github.com/arrow-kt/arrow/pull/2869](https://github.com/arrow-kt/arrow/pull/2869) #### New Contributors - [@​mjmoore](https://github.com/mjmoore) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2748](https://github.com/arrow-kt/arrow/pull/2748) - [@​valery1707](https://github.com/valery1707) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2824](https://github.com/arrow-kt/arrow/pull/2824) - [@​lukasz-kalnik-gcx](https://github.com/lukasz-kalnik-gcx) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2822](https://github.com/arrow-kt/arrow/pull/2822) - [@​StylianosGakis](https://github.com/StylianosGakis) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2832](https://github.com/arrow-kt/arrow/pull/2832) - [@​vikrem](https://github.com/vikrem) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2836](https://github.com/arrow-kt/arrow/pull/2836) - [@​cvb941](https://github.com/cvb941) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2840](https://github.com/arrow-kt/arrow/pull/2840) - [@​RusticFlare](https://github.com/RusticFlare) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2825](https://github.com/arrow-kt/arrow/pull/2825) - [@​mjvmroz](https://github.com/mjvmroz) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2845](https://github.com/arrow-kt/arrow/pull/2845) - [@​MarkMarkyMarkus](https://github.com/MarkMarkyMarkus) made their first contribution in [https://github.com/arrow-kt/arrow/pull/2793](https://github.com/arrow-kt/arrow/pull/2793) **Full Changelog**: arrow-kt/arrow@1.1.3...1.1.4-rc.3 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/elide-dev/elide). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi4xMS4wIiwidXBkYXRlZEluVmVyIjoiMzYuMTEuMCIsInRhcmdldEJyYW5jaCI6InYzIn0=-->
* The beginning of Arrow 2.0 * Resource Arrow 2.0 (#2786) * Flatten Resource ADT, maintain API * [Arrow 2.0] Effect without suspending shift (#2797) * Shift without suspend, inline all the rest * Add new error handlers signatures * Make ShiftCancellationException private * Rename Shift to Raise according to Slack Poll, and add some initial docs (#2827) * Remove all references to shift from new Arrow 2.0 code (#2834) * Remove all references to shift from new code * Update API files * Fixes merge conflict between main and arrow-2 (#2835) * Add Resource.allocated() to decompose Resource into it's allocate and… (#2820) * [2743] Migrate internal use of CircuitBreaker double to duration (#2748) * Fix typo (#2824) * Make the server disconnect test more general (#2822) * Update NonEmptyList.fromList deprecation to suggest `toOption()` instead (#2832) * Improve Either.getOrHandle() docs (#2833) * Improve allocated, and fix knit examples Co-authored-by: Jeff Martin <jeff@custommonkey.org> Co-authored-by: Martin Moore <martinmoorej@gmail.com> Co-authored-by: valery1707 <valery1707@gmail.com> Co-authored-by: Lukasz Kalnik <70261110+lukasz-kalnik-gcx@users.noreply.github.com> Co-authored-by: stylianosgakis <stylianos.gakis98@gmail.com> * Add Atomic module, and StateShift (#2817) * Two small deprecations * Add Atomic module, and StateShift. Implement ior through StateShift * Fix build * Fix atomic knit * Fix knit attempt #2 * Update API files * Remove references to shift * Change return type of raise to Nothing (#2839) * Change return type of raise to Nothing Implements #2805 * Update public api with ./gradlew apiDump * Suppress warnings for unreachable calls to fail in tests The test is verifying that no code will be executed after a call to raise, so it's actually testing the very behaviour that the compiler is warning us about. Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update API files * Increase timeout * Fix compiler bug with nested inline + while + return * Clean up ExitCase.fromError * Update API files@ * Feature/remove validated (#2795) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Remove CancellationExceptionNoTrace.kt after merge, and run apiDump * Add missing runnerJUnit5 for arrow-atomic JVM * Publish Arrow 2.0.0-SNAPSHOT (#2871) Co-authored-by: Javier Segovia Córdoba <7463564+JavierSegoviaCordoba@users.noreply.github.com> * Simplify optics to Traversal/Optional/Lens/Prism (#2873) * 'mapOrAccumulate' for Raise (#2872) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * Fix problems with Atomic * Smaller timeouts * Remove Tuple10 to Tuple22, Const, Eval, computation blocks, and arrow-continuations (#2784) * Revert typo * Fix build * Fix ParMapJvmTest * Implement NonEmptyList using value class (#2911) * Fix merge w.r.t. Saga * apiDump * Test other return expression * change unalign signature (#2972) see discussion in #2960 (comment) #2960 (comment) --------- Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update after merge main * Fix :arrow-optics-ksp-plugin:compileKotlin * Fix Every instances * Move functions to arrow functions (#3014) * Bring back `Iso` (#3013) * Bring back Iso * API Dump --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Update BOM (#3019) * Fix andThen duplication (#3020) * Fix Knit * Fix weird problem with value classes * Update API docs * Update publish workflow Following the instructions in #3090 (comment) * No closing repo on snapshot * knit * Fix optics tests * Fix after merge * Refactor ParMapTest from Kotest Plugin to Kotlin-test runtime #3191 (#3221) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor: Use Kotlin-test runtime for arrow-fx-stm tests (#3224) Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update all Gradle files to mention kotlin.test * Refactor ParZip2Test from Kotest Plugin to Kotlin-test runtime #3192 (#3222) Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor ParZip3Test from Kotest Plugin to Kotlin-test runtime #3193 (#3223) Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor GuaranteeCaseTest to use kotlin test (#3226) Closes #3190 * refactor: migrate NotEmptySetTest to kotlin-test (#3230) Co-authored-by: Alejandro Serrano <trupill@gmail.com> * refactor: migrate EagerEffectSpec to kotlin-test (#3233) Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor NullableSpec from Kotest Plugin to Kotlin-test runtime (#3236) #3153 Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor BracketCaseTest to use kotlin test (#3237) Closes #3186 Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Move arrow-functions tests to kotlin.test (#3243) * Inline `AtomicBoolean` (#3240) * Inline AtomicBoolean * Update API files --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * refactor: migrate MappersSpec to kotlin-test (#3248) * Refactor ResourceTestJvm from Kotest Plugin to Kotlin-test runtime (#3244) Closes #3213 * refactor: migrate FlowJvmTest to Kotlin-test (#3228) * Refactor ParZip9JvmTest from Kotest Plugin to Kotlin-test runtime (#3245) Closes #3211 * Refactor ParZip8JvmTest from Kotest Plugin to Kotlin-test runtime (#3246) Closes #3210 * refactor: migrate NumberInstancesTest to kotlin-test (#3232) * refactor: OptionTest to kotlin-test runtime (#3229) * Revert "Inline `AtomicBoolean` (#3240)" (#3279) This reverts commit a6f1e73. * Refactor ParZip6JvmTest from Kotest Plugin to Kotlin-test runtime (#3255) Closes #3208 * Refactor ParZip5JvmTest from Kotest Plugin to Kotlin-test runtime (#3256) Closes #3207 * Refactor ParZip3JvmTest from Kotest Plugin to Kotlin-test runtime (#3258) Closes #3205 * Refactor ParZip2JvmTest from Kotest Plugin to Kotlin-test runtime (#3259) Closes #3204 * Refactor ParMapJvmTest from Kotest Plugin to Kotlin-test runtime (#3260) Closes #3203 * Refactor ParZip4JvmTest from Kotest Plugin to Kotlin-test runtime (#3257) Closes #3206 * refactor: migrate RaiseAccumulateSpec to kotlin-test (#3250) * Refactor ParZip7JvmTest from Kotest Plugin to Kotlin-test runtime (#3247) Closes #3209 Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update ComparisonKtTest.kt (#3274) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * Update OptionSpec.kt (#3271) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * Update TraceJvmSpec.kt (#3276) * Update TraceJvmSpec.kt * Update TraceJvmSpec.kt --------- Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * Update ParZip9Test.kt (#3265) * Update ParZip9Test.kt * Update ParZip9Test.kt * Update ParZip8Test.kt (#3266) * Update ParZip7Test.kt (#3267) * Update ParZip6Test.kt (#3268) * Update ParZip5Test.kt (#3269) * Update ParZip4Test.kt (#3270) * Refactor CountDownLatchSpec and CyclicBarrierSpec to use kotlin test (#3227) * Refactor CountDownLatchSpec to use kotlin test Closes #3187 * Refactor CyclicBarrierSpec to use kotlin test Closes #3188 --------- Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Refactor NonEmptyListTest to kotlin-test (#3231) * Add kotlin test dependency * Refactor NonEmptyList Test to use kotlin test --------- Co-authored-by: Alejandro Serrano <trupill@gmail.com> * refactor: migrate EffectSpec to kotlin-test (#3234) * Refactor FlowTest to use kotlin test (#3238) Closes #3189 Co-authored-by: Alejandro Serrano <trupill@gmail.com> * refactor: migrate IorSpec to kotlin-test (#3249) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * refactor: migrate ResultSpec to kotlin-test (#3251) Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> * refactor: migrate StructuredConcurrencySpec to kotlin-test (#3252) * refactor: migrate TraceSpec to kotlin-test (#3253) * refactor: migrate GeneratorsTest to kotlin-test (#3254) * Refactor RaceNJvmTest from Kotest Plugin to Kotlin-test runtime (#3261) Closes #3212 Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update ArrowResponseEAdapterTest.kt (#3264) * Update ArrowResponseEAdapterTest.kt * Update ArrowResponseEAdapterTest.kt --------- Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update CollectionsSyntaxTests.kt (#3273) * Update CollectionsSyntaxTests.kt * Update CollectionsSyntaxTests.kt --------- Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> Co-authored-by: Alejandro Serrano <trupill@gmail.com> * Update NonFatalJvmTest.kt (#3277) * Update ArrowEitherCallAdapterTest.kt (#3278) * Update ArrowEitherCallAdapterTest.kt * Update ArrowEitherCallAdapterTest.kt * Move tests from `serialization` and `functions` completely to `kotlin.test` (#3289) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Fix problems with tests * Remove a bunch of warnings in `arrow-2` (#3282) Co-authored-by: serras <serras@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Finish transition to `kotlin.test` of `retrofit` and `fx-coroutines` (#3291) * Fix problems with concurrency in tests, take 8 * Port rest of `arrow-core` to `kotlin.test` (#3292) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Implement `fixedRate` using monotonic time source (#3294) Co-authored-by: serras <serras@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Port `optics` tests to `kotlin.test` (#3295) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Add or fix contracts in Raise (#3293) * Add or fix contracts in Raise * Make contracts less strict * Get back contract on Either * ignoreErrors should also be AT_MOST_ONCE --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * Alternate `SingletonRaise` (#3328) Co-authored-by: Youssef Shoaib <canonballt@gmail.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: serras <serras@users.noreply.github.com> * Remove (unused) tests for high-arity module * Fix tests + Knit * Fix merge NullableSpec * Regression in Arb.list? * Fix test for nonEmptyList * Develocity warning * Fix merge problem with optics-ksp-plugin * Fix timeout in test --------- Co-authored-by: Simon Vergauwen <nomisRev@users.noreply.github.com> Co-authored-by: Sam Cooper <54266448+roomscape@users.noreply.github.com> Co-authored-by: Marc Moreno Ferrer <ignis.fatue@gmail.com> Co-authored-by: Javier Segovia Córdoba <7463564+JavierSegoviaCordoba@users.noreply.github.com> Co-authored-by: Alphonse Bendt <370821+abendt@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Andreas Storesund Madsen <andreas@asmadsen.no> Co-authored-by: molikuner <molikuner@gmail.com> Co-authored-by: Jonathan Lagneaux <lagneaux.j@gmail.com> Co-authored-by: Marcus Ilgner <mail@marcusilgner.com> Co-authored-by: Chris Black <2538545+chrsblck@users.noreply.github.com> Co-authored-by: Tejas Mate <hi.tejas@pm.me> Co-authored-by: HyunWoo Lee (Nunu Lee) <54518925+l2hyunwoo@users.noreply.github.com> Co-authored-by: serras <serras@users.noreply.github.com> Co-authored-by: Youssef Shoaib <canonballt@gmail.com>
Fixes #2743
Double
toDuration
.CircuitBreaker::of
). Questionable to accept aDuration
, convert it toDouble
and then covert it back to aDuration
again to pass to the internal constructor. Would appreciate some guidance here on how to manage the@ExperimentalTime
annotation here.