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(backup): replace ByteArray with Uint8Array for JS [WPB-10575] #3286

Merged
merged 1 commit into from
Feb 7, 2025

Conversation

vitorhugods
Copy link
Member

@vitorhugods vitorhugods commented Feb 7, 2025

StoryWPB-10575 Cross Platform Backup: Write common backup / restore library


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

JS uses Uint8Array instead of ByteArray when dealing with files.

Solutions

Ensure compatibility with JavaScript by replacing ByteArray with Uint8Array in key backup export/import functions. Updated type handling across related classes and methods to support the new standard, maintaining seamless integration with the web platform.

Testing

N/A - But I've updated the sample to use UInt8Array


PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

Ensure compatibility with JavaScript by replacing `ByteArray` with `Uint8Array` in key backup export/import functions. Updated type handling across related classes and methods to support the new standard, maintaining seamless integration with the web platform.
Copy link

sonarqubecloud bot commented Feb 7, 2025

Copy link
Contributor

github-actions bot commented Feb 7, 2025

Test Results

3 513 tests  ±0   3 405 ✅ ±0   6m 21s ⏱️ +13s
  603 suites ±0     108 💤 ±0 
  603 files   ±0       0 ❌ ±0 

Results for commit acb89e4. ± Comparison against base commit 8838325.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Feb 7, 2025

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 50.83%. Comparing base (20791fd) to head (acb89e4).
Report is 3 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3286      +/-   ##
===========================================
- Coverage    50.84%   50.83%   -0.01%     
===========================================
  Files         1607     1607              
  Lines        58052    58053       +1     
  Branches      5203     5203              
===========================================
  Hits         29514    29514              
- Misses       26521    26523       +2     
+ Partials      2017     2016       -1     

see 3 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 20791fd...acb89e4. Read the comment docs.

@datadog-wireapp
Copy link

Datadog Report

Branch report: chore/backup/use-uint8array-for-javascript
Commit report: 88fe23e
Test service: kalium-jvm

✅ 0 Failed, 3405 Passed, 108 Skipped, 1m 1.45s Total Time

@vitorhugods vitorhugods enabled auto-merge February 7, 2025 15:46
@vitorhugods vitorhugods added this pull request to the merge queue Feb 7, 2025
Merged via the queue into develop with commit a5d42e4 Feb 7, 2025
24 checks passed
@vitorhugods vitorhugods deleted the chore/backup/use-uint8array-for-javascript branch February 7, 2025 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants