Skip to content
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

👷 Added new methods and inline methods #74

Merged
merged 2 commits into from
Jan 9, 2021

Conversation

Globegitter
Copy link
Collaborator

@Globegitter Globegitter commented Dec 18, 2020

This adds most of the methods and changes we have been using internally and we think really improves the usability of this library and fixes an imo very important bug we ran into a lot at the beginning in production and is not super easy to debug if you are not aware of it: #59

One nice thing about having all these inline methods it basically means that we do not need a separate coroutines result but that one can work out of the box with coroutines as you can see in the .map test I added.

I know this PR adds a lot at once, I am also happy to split it up and I guess it would require a 4.0 release. Let me know what you think @kittinunf .

@codecov
Copy link

codecov bot commented Dec 18, 2020

Codecov Report

Merging #74 (1a1a134) into master (3f626af) will decrease coverage by 12.50%.
The diff coverage is 12.00%.

Impacted file tree graph

@@              Coverage Diff              @@
##             master      #74       +/-   ##
=============================================
- Coverage     62.50%   50.00%   -12.50%     
  Complexity        8        8               
=============================================
  Files             4        5        +1     
  Lines           144      144               
  Branches         41       38        -3     
=============================================
- Hits             90       72       -18     
- Misses           46       67       +21     
+ Partials          8        5        -3     
Impacted Files Coverage Δ Complexity Δ
...main/kotlin/com/github/kittinunf/result/Factory.kt 0.00% <0.00%> (ø) 0.00 <0.00> (?)
.../main/kotlin/com/github/kittinunf/result/Result.kt 29.68% <17.64%> (-21.71%) 2.00 <0.00> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3f626af...1a1a134. Read the comment docs.

@kittinunf
Copy link
Owner

Wow!!! Thanks for this 👏. Let me take a look on this.

@kittinunf
Copy link
Owner

@Globegitter Thanks soooo much! I agree with you I think this is a great addition to the library! I think we need 4.0 for this though. but I am happy to bump this up to improve the usage of Result 👏

@Globegitter Globegitter requested a review from kittinunf January 6, 2021 16:05
@Globegitter
Copy link
Collaborator Author

Awesome, happy to hear that we can get this in :) And yes makes sense to release as 4.0

@Globegitter
Copy link
Collaborator Author

@kittinunf anything still blocking the merge? Would love to upgrade one of our new projects to the new version asap :) I am also not sure why codecov is saying that certain lines are not covered when my tests clearly are covering them. Any idea?

@kittinunf
Copy link
Owner

I don't care too much about the codecov no worries.

Yes let me check one more time but I think it is pretty much good to go.

Copy link
Owner

@kittinunf kittinunf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is golden, let me merge and prepare for 4.0

@kittinunf kittinunf changed the title Added new methods and inline methods 👷 Added new methods and inline methods Jan 9, 2021
@kittinunf kittinunf merged commit de71cd5 into kittinunf:master Jan 9, 2021
@Globegitter Globegitter deleted the markus-factory branch January 11, 2021 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants