Skip to content
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

refactor(widget): tidy up and comment code a bit #4263

Merged
merged 3 commits into from
Nov 14, 2024

Conversation

bnjbvr
Copy link
Member

@bnjbvr bnjbvr commented Nov 14, 2024

I've been exploring the widget API so as to understand how it works, just for the purpose of review. I couldn't help but tweak things here and there; I think there's still a lot to be done before this code is understandable, but here's a small improvement over the status quo already.

cc @toger5

@bnjbvr bnjbvr requested a review from a team as a code owner November 14, 2024 10:37
@bnjbvr bnjbvr requested review from andybalaam and removed request for a team November 14, 2024 10:37
Copy link

codecov bot commented Nov 14, 2024

Codecov Report

Attention: Patch coverage is 92.30769% with 6 lines in your changes missing coverage. Please review.

Project coverage is 84.95%. Comparing base (aca83fb) to head (4130157).
Report is 14 commits behind head on main.

Files with missing lines Patch % Lines
crates/matrix-sdk/src/widget/machine/mod.rs 91.89% 3 Missing ⚠️
crates/matrix-sdk/src/widget/mod.rs 92.68% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4263      +/-   ##
==========================================
+ Coverage   84.92%   84.95%   +0.03%     
==========================================
  Files         274      274              
  Lines       29805    29798       -7     
==========================================
+ Hits        25311    25314       +3     
+ Misses       4494     4484      -10     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@andybalaam andybalaam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

// messages. Refer to the `widget-api-poc` for implementation notes.
error!("Failed to parse incoming message: {e}");
Err(error) => {
error!("couldn't deserialized incoming widget message: {error}");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

error!("Couldn't deserialize incoming widget message: {error}");

@bnjbvr bnjbvr force-pushed the bnjbvr/misc-widget-api-cleanups branch from 6515803 to 4130157 Compare November 14, 2024 15:09
@bnjbvr bnjbvr enabled auto-merge (rebase) November 14, 2024 15:09
@bnjbvr bnjbvr merged commit 0d01cab into main Nov 14, 2024
39 checks passed
@bnjbvr bnjbvr deleted the bnjbvr/misc-widget-api-cleanups branch November 14, 2024 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants