Nixpkgs: restic: calling /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1 and panics

Created on 12 Sep 2020  路  4Comments  路  Source: NixOS/nixpkgs

Describe the bug
I have reported an issue where restic panics upstream (https://github.com/restic/restic/issues/2919).

The panic shows /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1 which does not exist and should not exist.

...
Sep 11 10:38:57 survey restic[6098]: will delete 224 packs and rewrite 1983 packs, this frees 4.523 GiB
Sep 11 11:47:37 survey restic[6098]: read tcp 78.47.220.153:33298->77.22.214.62:9001: read: connection reset by peer
Sep 11 11:47:37 survey restic[6098]: Load
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/internal/repository.DownloadAndHash
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/internal/repository/repository.go:786
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/internal/repository.Repack
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/internal/repository/repack.go:26
Sep 11 11:47:37 survey restic[6098]: main.pruneRepository
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_prune.go:278
Sep 11 11:47:37 survey restic[6098]: main.runForget
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_forget.go:215
Sep 11 11:47:37 survey restic[6098]: main.glob..func10
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_forget.go:22
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).execute
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:762
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).ExecuteC
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:852
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).Execute
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:800
Sep 11 11:47:37 survey restic[6098]: main.main
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/main.go:86
Sep 11 11:47:37 survey restic[6098]: runtime.main
Sep 11 11:47:37 survey restic[6098]:         /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1/share/go/src/runtime/proc.go:204
Sep 11 11:47:37 survey restic[6098]: runtime.goexit
Sep 11 11:47:37 survey restic[6098]:         /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1/share/go/src/runtime/asm_amd64.s:1374
Sep 11 11:47:37 survey restic[6098]: Repack
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/internal/repository.Repack
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/internal/repository/repack.go:28
Sep 11 11:47:37 survey restic[6098]: main.pruneRepository
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_prune.go:278
Sep 11 11:47:37 survey restic[6098]: main.runForget
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_forget.go:215
Sep 11 11:47:37 survey restic[6098]: main.glob..func10
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/cmd_forget.go:22
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).execute
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:762
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).ExecuteC
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:852
Sep 11 11:47:37 survey restic[6098]: github.com/restic/restic/vendor/github.com/spf13/cobra.(*Command).Execute
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/vendor/github.com/spf13/cobra/command.go:800
Sep 11 11:47:37 survey restic[6098]: main.main
Sep 11 11:47:37 survey restic[6098]:         /build/go/src/github.com/restic/restic/cmd/restic/main.go:86
Sep 11 11:47:37 survey restic[6098]: runtime.main
Sep 11 11:47:37 survey restic[6098]:         /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1/share/go/src/runtime/proc.go:204
Sep 11 11:47:37 survey restic[6098]: runtime.goexit
Sep 11 11:47:37 survey restic[6098]:         /nix/store/eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee-go-1.15.1/share/go/src/runtime/asm_amd64.s:1374

Is this a problem with our package?

To Reproduce
Steps to reproduce the behavior:

  1. see linked issue

Expected behavior
no panic

Notify maintainers
@mbrgm

Metadata

  • system: "x86_64-linux"
  • host os: Linux 5.4.62, NixOS, 20.09pre-git (Nightingale)
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.3.7
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos

using this branch https://github.com/davidak/nixpkgs/tree/survey-2020

Maintainer information:

# a list of nixpkgs attributes affected by the problem
attribute: restic
# a list of nixos modules affected by the problem
module:
bug golang

All 4 comments

Pretty sure this is because the Go infrastructure removes all references to the Go compiler (by replacing the store path with an impossible path) so the program doesn't depend on the compiler itself after it has been compiled... Though I could be totally wrong.

cc @zowoq who seems to be involved in our Go infra.

cc @NixOS/golang

This is intended to avoid store path references and add go as a runtime dependencies to every go package. This should not break anything in this case - also here the actual error is a closed connections from the looks of it. If you really want the original go paths than you can override fixupPhase for this package but this is really only cosmetics.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

langston-barrett picture langston-barrett  路  3Comments

tomberek picture tomberek  路  3Comments

ghost picture ghost  路  3Comments

edolstra picture edolstra  路  3Comments

teto picture teto  路  3Comments