Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #315 +/- ##
==========================================
- Coverage 75.17% 74.57% -0.60%
==========================================
Files 44 45 +1
Lines 4374 4409 +35
==========================================
Hits 3288 3288
- Misses 1086 1121 +35 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Love the tidiness: the added docs and supplied example. Considering this method does not match the signature of The |
|
Before it gets lost, here is the branch I created for you last week that outlines what could be the abstracted Keep up the good work! |
|
Thanks for your comments Luuk, will make relevant changes and think about that optimization once I make a bit more progress on this.
Yeah this is a good point and something I am still thinking on. Correct me if I am wrong, I thought I needed to deviate from the signature and return an error with more context than a zbus error, to handle the case in which a timeout occurs As of right now, I think I will a pattern similar to your code. Namely, by using a wrapper struct and having it check if the Collection proxy works and falling back to the clientside traversal if not. Will play around with the API a bit to see what is most natural. |
|
@C-Loftus if possible, move to a local (starting with |
With respect to the timeout, I think your added I just re-read the discussion and it seems @TTWNO and I may have somewhat differing north-stars.. Then I suggested abstracting over One can certainly be a building block for the other.
Note that some things in object_match can be a bit awkward, such as the
Great! |
Regarding caching, I think that will be useful, but I think we should get a baseline first to get a sense of the API and the performance. In my mind that would be a followup PR since I think it would be rather complicated. I did explore having a trait like I like having a separate struct since it clearly distinguishes that this code is a custom helper. However, happy to chat further if you disagree. |
|
Yeah let's not add the burden of the second hardest problem in computer science to this PR. We will get traversal working first, and then move on to caching at some (unspecified) future date. |
|
Glad to see progress coming anew to this section of code. Thanks, Colton. |
Sure thing! FYI my plan is to continuously push to this PR branch so everything is backed up and its clear my progress on things. I think you can mute to prevent notifications on this sort of thing until I formally request a review, but if you prefer I do a different workflow let me know! |
|
Noted. Thanks. |
|
Hi @TTWNO , @luukvanderduim I have 2 questions for you both:
As context:
/// Flow sort order
///
/// Unimplemented
Flow, |
|
I am fine with splitting this up into smaller PRs :) But yes, there are a lot of confusing issues in traversal semantics... as you have seen, haha! |
As mentioned in #299 it is useful to have client-side traversal helpers since
Collectionis often unimplemented by many apps.This PR begins this work. I am submitting it here for review so we can see if I am on the same page. I will PR into this PR as a stack.
PR Structure
I have structured this to begin with an explicit
TraversalHelperstruct. This helps to encapsulate behavior and store variables like the atspi connection so that they don't need to be passed in the functions. I think this is cleanest so the function definitions stay the same.I may add a few new atspi errors that are specific to clientside traversals like timeouts or max depth.
Roadmap
get_active_descendantget_matchesget_matches_fromget_matches_toCollectiontrait once I haveCollectionClientsidefully implemented