Commit 8a56ad0
refactor(agent): address review comments for window recording support (#1600)
Addresses review feedback from PR #1583 on the window recording feature
implementation.
### Dependency Management
- Updated `now-proto-pdu` to use v0.4.2 from crates.io for stable,
reproducible builds
### Task Lifecycle
- Track window monitor task with `JoinHandle` and await completion on
shutdown to prevent race conditions
- Made `stop_window_recording` async to properly await task termination
### Code Quality
- Removed redundant type annotation on `run_dvc_io` result
- Extracted duplicate timestamp logic into `get_current_timestamp()`
helper
- Fixed module docs to clarify polling is used for title change
detection
### Bug Fix
- When title tracking is disabled, preserve previous title in snapshot
to avoid missing actual window changes:
```rust
// Before: updating full snapshot could mask process/exe_path changes
last_snapshot = Some(snapshot);
// After: preserve previous title when tracking disabled
let prev_title = last_snapshot.as_ref().map_or_else(String::new, |s| s.title.clone());
last_snapshot = Some(WindowSnapshot {
process_id: snapshot.process_id,
exe_path: snapshot.exe_path.clone(),
title: prev_title,
});
```
<!-- START COPILOT CODING AGENT TIPS -->
---
💬 We'd love your input! Share your thoughts on Copilot coding agent in
our [2 minute survey](https://gh.io/copilot-coding-agent-survey).
---------
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: pacmancoder <[email protected]>1 parent 0875d84 commit 8a56ad0
File tree
4 files changed
+47
-32
lines changed- devolutions-session
- src/dvc
4 files changed
+47
-32
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
48 | | - | |
| 47 | + | |
49 | 48 | | |
50 | 49 | | |
51 | 50 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
77 | | - | |
| 77 | + | |
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| |||
298 | 298 | | |
299 | 299 | | |
300 | 300 | | |
| 301 | + | |
| 302 | + | |
301 | 303 | | |
302 | 304 | | |
303 | 305 | | |
| |||
312 | 314 | | |
313 | 315 | | |
314 | 316 | | |
| 317 | + | |
315 | 318 | | |
316 | 319 | | |
317 | 320 | | |
| |||
482 | 485 | | |
483 | 486 | | |
484 | 487 | | |
485 | | - | |
| 488 | + | |
486 | 489 | | |
487 | 490 | | |
488 | 491 | | |
| |||
763 | 766 | | |
764 | 767 | | |
765 | 768 | | |
766 | | - | |
| 769 | + | |
767 | 770 | | |
768 | 771 | | |
769 | 772 | | |
| |||
783 | 786 | | |
784 | 787 | | |
785 | 788 | | |
786 | | - | |
| 789 | + | |
787 | 790 | | |
788 | 791 | | |
789 | 792 | | |
790 | 793 | | |
791 | 794 | | |
792 | 795 | | |
| 796 | + | |
| 797 | + | |
793 | 798 | | |
794 | 799 | | |
795 | 800 | | |
796 | | - | |
| 801 | + | |
797 | 802 | | |
798 | 803 | | |
799 | 804 | | |
800 | 805 | | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
801 | 813 | | |
802 | 814 | | |
803 | 815 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
194 | 195 | | |
195 | 196 | | |
196 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
197 | 206 | | |
198 | 207 | | |
199 | 208 | | |
| |||
394 | 403 | | |
395 | 404 | | |
396 | 405 | | |
397 | | - | |
| 406 | + | |
398 | 407 | | |
399 | 408 | | |
400 | 409 | | |
401 | 410 | | |
402 | 411 | | |
403 | 412 | | |
404 | 413 | | |
405 | | - | |
406 | | - | |
407 | | - | |
408 | | - | |
| 414 | + | |
409 | 415 | | |
410 | 416 | | |
411 | 417 | | |
| |||
441 | 447 | | |
442 | 448 | | |
443 | 449 | | |
444 | | - | |
445 | | - | |
446 | | - | |
447 | | - | |
| 450 | + | |
448 | 451 | | |
449 | 452 | | |
450 | 453 | | |
| |||
486 | 489 | | |
487 | 490 | | |
488 | 491 | | |
489 | | - | |
490 | | - | |
491 | | - | |
492 | | - | |
| 492 | + | |
493 | 493 | | |
494 | 494 | | |
495 | 495 | | |
| |||
532 | 532 | | |
533 | 533 | | |
534 | 534 | | |
535 | | - | |
536 | | - | |
537 | | - | |
538 | | - | |
| 535 | + | |
539 | 536 | | |
540 | 537 | | |
541 | 538 | | |
| |||
544 | 541 | | |
545 | 542 | | |
546 | 543 | | |
547 | | - | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
548 | 554 | | |
549 | 555 | | |
550 | 556 | | |
| |||
590 | 596 | | |
591 | 597 | | |
592 | 598 | | |
593 | | - | |
594 | | - | |
595 | | - | |
596 | | - | |
| 599 | + | |
597 | 600 | | |
598 | 601 | | |
599 | 602 | | |
| |||
0 commit comments