Commit 4d3bb2e
authored
PIR: Fix shared webview being destroyed in PIR debug runs (duckduckgo#7755)
Task/Issue URL:
https://app.asana.com/1/137249556945/task/1212923242657599
### Description
Shared WebView that is passed to a PIR runner was destroyed between
jobs. This delegates the cleanup to the owner of the WebView (activity)
instead of to the runner.
### Steps to test this PR
QA optional - can run debug scans or opt-outs
### UI changes
No UI changes
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> **Low Risk**
> Small, debug-only control-flow change that avoids calling runner
cleanup which destroys the shared WebView; low blast radius outside
debug runs.
>
> **Overview**
> Prevents PIR *debug* scan/opt-out flows from destroying the
caller-provided (shared) `WebView` between sequential steps.
>
> In `RealPirScan.debugExecute` and `RealPirOptOut.debugExecute`,
removes the per-step `runners[0].stop()` call (with an explanatory
comment), leaving WebView lifecycle/cleanup to the debug WebView owner
while still cleaning WebView data at the end of the run.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
a3343a9. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->1 parent 4d52ad5 commit 4d3bb2e
File tree
2 files changed
+2
-2
lines changed- pir/pir-impl/src/main/java/com/duckduckgo/pir/impl
- optout
- scan
2 files changed
+2
-2
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
307 | 307 | | |
308 | 308 | | |
309 | 309 | | |
310 | | - | |
| 310 | + | |
311 | 311 | | |
312 | 312 | | |
313 | 313 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
238 | | - | |
| 238 | + | |
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
| |||
0 commit comments