Coder Social home page Coder Social logo

Comments (8)

AniketKul avatar AniketKul commented on June 11, 2024

Getting following error with all the commands apart from ImagePull and ImagePush at present. investigating it further

go test -v ./pkg/docker/ -run TestDocker_Push
=== RUN   TestDocker_Push
--- FAIL: TestDocker_Push (0.00s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0xe0 pc=0x1a2c6e9]

goroutine 20 [running]:
testing.tRunner.func1(0xc00011e100)
	/usr/local/Cellar/go/1.13.1/libexec/src/testing/testing.go:874 +0x3a3
panic(0x1b39780, 0x2636b00)
	/usr/local/Cellar/go/1.13.1/libexec/src/runtime/panic.go:679 +0x1b2
github.com/ocibuilder/ocibuilder/pkg/docker.(*testClient).ContainerList(0x26465f0, 0x1e0b0e0, 0xc00003a0a8, 0x10100, 0x1c6d4a8, 0x9, 0x0, 0x0, 0x0, 0x0, ...)
	<autogenerated>:1 +0x39
github.com/ocibuilder/ocibuilder/pkg/docker.Docker.Push(0xc00014f0a0, 0x1e2f460, 0x26465f0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x263e420, ...)
	/Users/<username>/go_installation/src/github.com/ocibuilder/ocibuilder/pkg/docker/docker.go:202 +0x35f
github.com/ocibuilder/ocibuilder/pkg/docker.TestDocker_Push(0xc00011e100)
	/Users/<username>/go_installation/src/github.com/ocibuilder/ocibuilder/pkg/docker/docker_test.go:52 +0x76
testing.tRunner(0xc00011e100, 0x1cd3380)
	/usr/local/Cellar/go/1.13.1/libexec/src/testing/testing.go:909 +0xc9
created by testing.(*T).Run
	/usr/local/Cellar/go/1.13.1/libexec/src/testing/testing.go:960 +0x350
FAIL	github.com/ocibuilder/ocibuilder/pkg/docker	0.191s
FAIL

from ocibuilder.

AniketKul avatar AniketKul commented on June 11, 2024

Steps to fix this:

1] use cli.ImageTag in ImagePush function first and then
2] use cli.ImagePush

but the issue is I am getting above error with a simple cli.ImageTag call in ocibuilder repo. It works fine on my machine in another sample repository

from ocibuilder.

artbegolli avatar artbegolli commented on June 11, 2024

What error is being thrown with ImageTag?

from ocibuilder.

AniketKul avatar AniketKul commented on June 11, 2024

@artbegolli - similar to what I had posted earlier. ImageRemove that we have in our code also throws similar error.

=== RUN   TestDocker_Push
--- FAIL: TestDocker_Push (0.00s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x208 pc=0x1a4dee6]

goroutine 20 [running]:
testing.tRunner.func1(0xc00013e100)
	/usr/local/go/src/testing/testing.go:830 +0x392
panic(0x1b57940, 0x274c640)
	/usr/local/go/src/runtime/panic.go:522 +0x1b5
github.com/ocibuilder/ocibuilder/pkg/docker.(*testClient).ImageTag(0x275bb60, 0x1e2cc80, 0xc00003a090, 0x1c7d983, 0xa, 0xc00038e000, 0x2e, 0x0, 0x1c7a359)
	<autogenerated>:1 +0x36
github.com/ocibuilder/ocibuilder/pkg/docker.Docker.Push(0xc0000d15c0, 0x1e56640, 0x275bb60, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2753ba0, ...)
	/Users/<username>/go_installation/src/github.com/ocibuilder/ocibuilder/pkg/docker/docker.go:196 +0x3b4
github.com/ocibuilder/ocibuilder/pkg/docker.TestDocker_Push(0xc00013e100)
	/Users/<username>/go_installation/src/github.com/ocibuilder/ocibuilder/pkg/docker/docker_test.go:52 +0x76
testing.tRunner(0xc00013e100, 0x1cdfc68)
	/usr/local/go/src/testing/testing.go:865 +0xc0
created by testing.(*T).Run
	/usr/local/go/src/testing/testing.go:916 +0x35a
FAIL	github.com/ocibuilder/ocibuilder/pkg/docker	0.239s

from ocibuilder.

artbegolli avatar artbegolli commented on June 11, 2024

Add ImageTag to the mock test function in docker_test.go

from ocibuilder.

AniketKul avatar AniketKul commented on June 11, 2024

cool

from ocibuilder.

AniketKul avatar AniketKul commented on June 11, 2024

this is almost done. just need to regenerate clientset to fix some unwanted code in clientset. working on it

from ocibuilder.

AniketKul avatar AniketKul commented on June 11, 2024

PR #71 fixes this issue

from ocibuilder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.