prometheus / prometheus/procfs

tests fail when used with go modules

Open
#108 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
883
Forks
388
Avg merge
13h 28m
Merged PRs (30d)
3

Description

Both the main procfs package and the xfs package fail on my machine.
Here's a reproducer:

#!/bin/sh
set -ex
t=$(mktemp -d)
trap 'rm -r $t' EXIT
cd $t
cat >ex.go <<.
package main

import (
	_ "github.com/prometheus/procfs"
)

func main() {
	println("example")
}
.
go mod init example
go test all

The tests should automatically unpack fixtures.ttar if they need the files.

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

Run the provided Go modules reproducer and inspect the tests in the main procfs and xfs packages, along with fixtures.ttar. Confirm which tests need fixture files, then verify that go test all automatically unpacks fixtures.ttar and passes for both packages.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.