-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
2.x: Update Error Handling Operators docs #6266
2.x: Update Error Handling Operators docs #6266
Conversation
Codecov Report
@@ Coverage Diff @@
## 2.x #6266 +/- ##
============================================
+ Coverage 98.25% 98.26% +0.01%
- Complexity 6206 6208 +2
============================================
Files 667 667
Lines 44905 44905
Branches 6228 6228
============================================
+ Hits 44121 44126 +5
- Misses 239 243 +4
+ Partials 545 536 -9
Continue to review full report at Codecov.
|
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.
This is really good, but few comments
docs/Error-Handling-Operators.md
Outdated
.doOnError(error -> System.err.println("The error message is: " + error.getMessage())) | ||
.subscribe( | ||
x -> System.out.println("This should never be printed!"), |
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.
Let's be more clear for newcomers here with something like: "onNext should never be printed!"
docs/Error-Handling-Operators.md
Outdated
x -> System.out.println("This should never be printed!"), | ||
Throwable::printStackTrace, | ||
() -> System.out.println("This should never be printed!")); |
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.
Same as above
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.
Similar cases below, don't want to mention them all with separate comments
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.
Included the "onNext" etc. in the print statements.
docs/Error-Handling-Operators.md
Outdated
**ReactiveX documentation:** [http://reactivex.io/documentation/operators/catch.html](http://reactivex.io/documentation/operators/catch.html) | ||
|
||
When the reactive type signals an error event, the error will be swallowed and replaced by a complete event. |
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.
"by a completion event"?
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.
Changed it.
**ReactiveX documentation:** [http://reactivex.io/documentation/operators/catch.html](http://reactivex.io/documentation/operators/catch.html) | ||
|
||
Instructs a reactive type to emit a sequence of items if it encounters an error. |
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.
Inconsistency here compared to descriptions above, they started with
When the reactive type signals an error event
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.
I'd suggest to stick to one or another style
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.
"Instructs …" is actually pretty good and concise
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.
I have changed it to use "Instructs ..." in all descriptions.
``` | ||
|
||
## retry |
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.
Is there a reason that sytnax highlighting breaks here?
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.
I don't know why this happens (BTW this already happens in line 170; the triple backticks should also be blue). Locally, in VS Code the highlighting of the Markdown looks correct.
This PR updates the
Error-Handling-Operators.md
wiki page as per issue #6132:The page now follows the structure that was defined in #6131.