actions / actions/toolkit

downloadTool should confirm file length matches `Content-length` header

Open
#426 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement tool-cache
Dominant language
TypeScript
Stars
5.9k
Forks
1.8k
PR merge metrics
No merged PRs in 30d

Description

We should verify the response stream size matches the Content-length header. Node doesn't check. Better yet, verify the written file length to make sure we're not losing anything end-to-end.

Debug tracing the Content-length header may also be useful.

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 TypeScript implementation and entry point for downloadTool, then trace the response stream through the written file. Review any existing downloadTool tests before changing behavior. Done means the response and final file lengths are checked against Content-length, with useful tracing for that header.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.