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

feat: Emit ImexProgress(1) after receiving backup size #6347

Merged
merged 1 commit into from
Dec 18, 2024

Conversation

iequidoo
Copy link
Collaborator

@iequidoo iequidoo commented Dec 17, 2024

UIs may want to display smth like "Transferring..." after "Establishing connection between devices..." on nonzero progress. Before, progress on the receiver side was starting with 2 after receiving enough data.

UIs may want to display smth like "Transferring..." after "Establishing connection between
devices..." on nonzero progress. Before, progress on the receiver side was starting with 2 after
receiving enough data.
Copy link
Member

@Simon-Laux Simon-Laux left a comment

Choose a reason for hiding this comment

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

LGTM, with the disclaimer that I haven't tested it

@iequidoo
Copy link
Collaborator Author

LGTM, with the disclaimer that I haven't tested it

I tweaked the existing test and it fails w/o the change itself.

@iequidoo iequidoo force-pushed the iequidoo/get_backup2-progress-1 branch from b60f11c to 4590435 Compare December 18, 2024 00:11
@iequidoo iequidoo merged commit 3af4ea1 into main Dec 18, 2024
24 checks passed
@iequidoo iequidoo deleted the iequidoo/get_backup2-progress-1 branch December 18, 2024 00:12
@@ -309,6 +310,10 @@ pub async fn get_backup2(
let mut file_size_buf = [0u8; 8];
recv_stream.read_exact(&mut file_size_buf).await?;
let file_size = u64::from_be_bytes(file_size_buf);
info!(context, "Received backup file size.");
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Forgot to log file_size, but anyway having some log is good

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