rust-lang / rust-lang/rustup

Test needed - Verify streaming file installation

Open
#2,754 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

E-mentor enhancement help wanted
Dominant language
Rust
Stars
7k
Forks
1.1k
Avg merge
22h 40m
Merged PRs (30d)
46

Description

While preparing 1.24.2 we encountered a problem where streamed files were all NUL bytes.

This was easy to fix, but highlights the fact that our test set does not include any files large enough to trigger the streaming installation mode.

We should ensure that at least one (and at most a small number) of our tests validate that (a) the streaming mode is invoked (i.e. files larger than IO_CHUNK_SIZE) and (b) that the resultant installed file has not been corrupted.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the installation tests and the IO_CHUNK_SIZE constant, then identify how files larger than that threshold invoke streaming installation. Add a test using a file large enough to trigger streaming and verify the installed file matches the source without corruption. Keep the number of such tests small and run the relevant test suite.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
testing-qa
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.