Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Go: a full run grows GOCACHE without bound (235 GB) and fills the disk

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

Maintainers usually reply within 3 days

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
53/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
go, python

Research direction

Start by reading the README's Go section and tracing how Go test runs are launched for mutation workers; the issue names target/mutation-workers/run-*/gocache as a possible run-scoped location. Compare documenting the workaround with managing a private cache and cleanup, then verify that a full run keeps disk use bounded and removes its cache when the run ends.

Written by the indexing model from the issue text.

Description

What happens

A full run over a large Go codebase filled the disk. About 33,000 mutation sites in 65 packages ran for roughly 5 hours. Go's build cache (go env GOCACHE, ~/Library/Caches/go-build on macOS) grew to 235 GB. The disk reached 0 bytes free, and later packages failed with [Errno 28] No space left on device. Other processes on the machine failed too.

Why

Every mutant changes one source file, so go test compiles a new package archive and links a new test binary. Each binary is cached under a fresh key. With thousands of mutants per package, the cache grows by gigabytes per package and is never trimmed: Go's own trimming removes only entries unused for 5 days.

Workaround

Run with a private cache and remove it after each package:

GOCACHE=$PWD/target/gocache mutator ... ; go clean -cache

Suggestion

One of these, from simplest:

  1. Mention the disk cost in the README's Go section, together with the workaround.
  2. Give the mutant runs a cache under the run directory (target/mutation-workers/run-*/gocache), seeded from the user's cache or shared across workers, and delete it with the run.
  3. Run go clean -cache with GOCACHE set to the private cache between files.

Option 2 keeps dependency builds warm within a run and bounds disk use to one run.

Environment

mutator a5a0cb8, Go 1.27.1, macOS arm64, --max-workers 14.

Dominant language
Python
Stars
55
Forks
7
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

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.

More from unclebob/mutator

All issues in unclebob/mutator

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.