Skip to content

Commit 3bd4376

Browse files
committed
Merge remote-tracking branch 'origin/master' into develop
2 parents fd8810a + 4724523 commit 3bd4376

8 files changed

+11
-11
lines changed

docs/images/coroutine-breakpoint.png

9.13 KB
Loading
78.5 KB
Loading

docs/images/flow-breakpoint.png

2.76 KB
Loading

docs/images/flow-build-project.png

25.1 KB
Loading

docs/images/flow-debug-project.png

35.1 KB
Loading

docs/topics/coroutine-context-and-dispatchers.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ The Coroutine Debugger of the Kotlin plugin simplifies debugging coroutines in I
148148
The **Debug** tool window contains the **Coroutines** tab. In this tab, you can find information about both currently running and suspended coroutines.
149149
The coroutines are grouped by the dispatcher they are running on.
150150

151-
![Debugging coroutines](coroutine-idea-debugging-1.png)
151+
![Debugging coroutines](coroutine-idea-debugging-1.png){width=700}
152152

153153
With the coroutine debugger, you can:
154154
* Check the state of each coroutine.

docs/topics/debug-coroutines-with-idea.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The tutorial assumes you have prior knowledge of the [coroutines](coroutines-gui
1616

1717
The `src` directory contains Kotlin source files and resources. The `main.kt` file contains sample code that will print `Hello World!`.
1818

19-
2. Change code in the `main()` function:
19+
3. Change code in the `main()` function:
2020

2121
* Use the [`runBlocking()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines/run-blocking.html) block to wrap a coroutine.
2222
* Use the [`async()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines/async.html) function to create coroutines that compute deferred values `a` and `b`.
@@ -61,7 +61,7 @@ The tutorial assumes you have prior knowledge of the [coroutines](coroutines-gui
6161

6262
![Debug the coroutine](coroutine-debug-1.png)
6363

64-
3. Resume the debugger session by clicking **Resume program** in the **Debug** tool window:
64+
3. Resume the debugger session by clicking **Resume Program** in the **Debug** tool window:
6565

6666
![Debug the coroutine](coroutine-debug-2.png)
6767

@@ -70,7 +70,7 @@ The tutorial assumes you have prior knowledge of the [coroutines](coroutines-gui
7070
* The second coroutine is calculating the `a` value – it has the **RUNNING** status.
7171
* The third coroutine has the **CREATED** status and isn’t calculating the value of `b`.
7272

73-
4. Resume the debugger session by clicking **Resume program** in the **Debug** tool window:
73+
4. Resume the debugger session by clicking **Resume Program** in the **Debug** tool window:
7474

7575
![Build a console application](coroutine-debug-3.png)
7676

docs/topics/debug-flow-with-idea.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
1818

1919
The `src` directory contains Kotlin source files and resources. The `main.kt` file contains sample code that will print `Hello World!`.
2020

21-
2. Create the `simple()` function that returns a flow of three numbers:
21+
3. Create the `simple()` function that returns a flow of three numbers:
2222

2323
* Use the [`delay()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines/delay.html) function to imitate CPU-consuming blocking code. It suspends the coroutine for 100 ms without blocking the thread.
2424
* Produce the values in the `for` loop using the [`emit()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow-collector/emit.html) function.
@@ -36,7 +36,7 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
3636
}
3737
```
3838

39-
3. Change the code in the `main()` function:
39+
4. Change the code in the `main()` function:
4040

4141
* Use the [`runBlocking()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines/run-blocking.html) block to wrap a coroutine.
4242
* Collect the emitted values using the [`collect()`](https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/collect.html) function.
@@ -53,13 +53,13 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
5353
}
5454
```
5555

56-
4. Build the code by clicking **Build Project**.
56+
5. Build the code by clicking **Build Project**.
5757

5858
![Build an application](flow-build-project.png)
5959

6060
## Debug the coroutine
6161

62-
1. Set a breakpoint at the at the line where the `emit()` function is called:
62+
1. Set a breakpoint at the line where the `emit()` function is called:
6363

6464
![Build a console application](flow-breakpoint.png)
6565

@@ -74,7 +74,7 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
7474

7575
![Debug the coroutine](flow-debug-1.png)
7676

77-
3. Resume the debugger session by clicking **Resume program** in the **Debug** tool window. The program stops at the same breakpoint.
77+
3. Resume the debugger session by clicking **Resume Program** in the **Debug** tool window. The program stops at the same breakpoint.
7878

7979
![Debug the coroutine](flow-resume-debug.png)
8080

@@ -101,7 +101,7 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
101101
}
102102
```
103103

104-
4. Build the code by clicking **Build Project**.
104+
3. Build the code by clicking **Build Project**.
105105

106106
## Debug a Kotlin flow with two coroutines
107107

@@ -117,7 +117,7 @@ Create a Kotlin [flow](https://kotlin.github.io/kotlinx.coroutines/kotlinx-corou
117117
The `buffer()` function buffers emitted values from the flow.
118118
The emitter coroutine has the **RUNNING** status, and the collector coroutine has the **SUSPENDED** status.
119119

120-
2. Resume the debugger session by clicking **Resume program** in the **Debug** tool window.
120+
3. Resume the debugger session by clicking **Resume Program** in the **Debug** tool window.
121121

122122
![Debugging coroutines](flow-debug-4.png)
123123

0 commit comments

Comments
 (0)