profile
viewpoint

push eventSamWhited/moby

Sam Whited

commit sha 7e52ea2b9f0e7950900dee0226d22796bc8caf0b

Use containerd importer Fixes dmcgowan/docker#48 Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 10 hours

push eventSamWhited/moby

Sam Whited

commit sha 4bd385e626b7ee3493df86e5b6de23ae1261dca8

Use containerd importer Fixes dmcgowan/docker#48 Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 10 hours

push eventSamWhited/moby

Sam Whited

commit sha 2e596b063df68c108a7d875601dfdd7bf19c2777

Use containerd importer Fixes dmcgowan/docker#48 Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 11 hours

push eventSamWhited/moby

Chow

commit sha 75a59c65880acdef589d2e6781bec83a6ef54fde

Enable DNS Lookups for CIFS Volumes This comes from an old suggestion (https://github.com/docker/cli/issues/706#issuecomment-371157691) on an issue we were having and has since popped up again. For NFS volumes, Docker will do an IP lookup on the volume name. This is not done for CIFS volumes, which forces you to add the volume via IP address instead. This change will enable the IP lookup also for CIFS volumes. Signed-off-by: Shu-Wai Chow <shu-wai.chow@seattlechildrens.org>

view details

Kir Kolyshkin

commit sha 53cbf1797b001314035a13578ed60f015a0179e4

daemon/ProcessEvent: make sure to cancel the contexts Reported by govet linter: > daemon/monitor.go:57:9: lostcancel: the cancel function returned by context.WithTimeout should be called, not discarded, to avoid a context leak (govet) > ctx, _ := context.WithTimeout(context.Background(), 2*time.Second) > ^ > daemon/monitor.go:128:9: lostcancel: the cancel function returned by context.WithTimeout should be called, not discarded, to avoid a context leak (govet) > ctx, _ := context.WithTimeout(context.Background(), 2*time.Second) > ^ Fixes: b5f288 ("Handle blocked I/O of exec'd processes") Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>

view details

Olli Janatuinen

commit sha 8660330173e5053e274cf12860079f132cbaa9fa

Unit test for getOrphan Signed-off-by: Olli Janatuinen <olli.janatuinen@gmail.com>

view details

Arko Dasgupta

commit sha f3a3ea0d3c7f4d4da035db871d3c8a8bbb51371f

Fix flaky TestServiceWithDefaultAddressPoolInit 1.This commit replaces serviceRunningCount with swarm.RunningTasksCount to accurately check if the service is running with the accurate number of instances or not. serviceRunningCount was only checking the ServiceList and was not checking if the tasks were running or not This adds a safe barrier to execute docker network inspect commands for overlay networks which get created asynchronously via Swarm 2. Make sure client connections are closed 3. Make sure every service and network name is unique 4. Make sure services and networks are cleaned up Signed-off-by: Arko Dasgupta <arko.dasgupta@docker.com>

view details

Arko Dasgupta

commit sha a65dee30fc36ed974940b699ed22ab9242eac6cf

Move defer method to the top right after New is called Signed-off-by: Arko Dasgupta <arko.dasgupta@docker.com>

view details

Nick Adcock

commit sha 1a5dafb31eed7a44115f13595b54eaf109c4f388

Improve readability of Windows connect error Improve the readability of the connection error displayed to the user on Windows when running docker commands fails by checking if the client is privileged. If so then display the actual error wrapped in a generic error "This error may indicate that the docker daemon is not running." If not that display the actual error wrapped in a more specific error: "In the default daemon configuration on Windows, the docker client must be run with elevated privileges to connect." Signed-off-by: Nick Adcock <nick.adcock@docker.com>

view details

Hannes Ljungberg

commit sha 4d09fab232ed282d020afbe1e0935b53379df4ad

Update service networks documentation The previous description stated that an array of names / ids could be passed when the API in reality expects objects in the form of NetworkAttachmentConfig. This is fixed by updating the description and adding a definition for NetworkAttachmentConfig. Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>

view details

Jintao Zhang

commit sha f8f6f7c2a0e1e1e8b541b29b0f1bdae44964e714

cleanup: remove SetDead function Signed-off-by: Jintao Zhang <zhangjintao9020@gmail.com>

view details

Sebastiaan van Stijn

commit sha 556d26c07d068d92fd896428ab4ac890554239d7

pkg/term: refactor TestEscapeProxyRead - use subtests to make it clearer what the individual test-cases are, and to prevent tests from depending on values set by the previous test(s). - remove redundant messages in assert (gotest.tools already prints a useful message if assertions fail). Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Daniel Sweet

commit sha db2bc43017b45dbb4e2aa51e093eab3fbb86ead1

Use correct `LOOP_CTL_GET_FREE` API in `pkg/loopback` The `ioctl` interface for the `LOOP_CTL_GET_FREE` request on `/dev/loop-control` is a little different from what `unix.IoctlGetInt` expects: the first index is the returned status in `r1`, not an `int` pointer as the first parameter. Unfortunately we have to go a little lower level to get the appropriate loop device index out, using `unix.Syscall` directly to read from `r1`. Internally, the index is returned as a signed integer to match the internal `ioctl` expectations of interpreting a negative signed integer as an error at the userspace ABI boundary, so the direct interface of `ioctlLoopCtlGetFree` can remain as-is. [@kolyshkin: it still worked before this fix because of /dev scan fallback in ioctlLoopCtlGetFree()] Signed-off-by: Daniel Sweet <danieljsweet@icloud.com> Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>

view details

Sebastiaan van Stijn

commit sha 31885181fcc0ca0cacd6c12f6c64ac553ff2bc2b

integration: windows.ps1: turn defender error into a warning Some integration tests are known to fail if Windows Defender is enabled. On the machines that run our CI, defender is disabled for that reason. Contributors likely will have defender enabled, and because of that are currently not able to run the integration tests. This patch changes the ERROR into a WARNING, so that contributors can still run (a limited set of) the integration tests, but get informed that some may fail. We should make this requirement more specific, and only skip tests that are known to require defender to be disabled, but while that's not yet in place, let's print a warning instead. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha f1cd79976a9acabbafd8a053f1bcb4581e43b7a8

bump google.golang.org/grpc v1.23.0 full diff: https://github.com/grpc/grpc-go/compare/v1.20.1...v1.23.0 This update contains security fixes: - transport: block reading frames when too many transport control frames are queued (grpc/grpc-go#2970) - Addresses CVE-2019-9512 (Ping Flood), CVE-2019-9514 (Reset Flood), and CVE-2019-9515 (Settings Flood). Other changes can be found in the release notes: https://github.com/grpc/grpc-go/releases/tag/v1.23.0 Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha 8769255d1bb9c469d4f2966e7e9869a9f126f9e9

bump containerd/ttrpc 92c8520ef9f86600c650dd540266a007bf03670f full diff: https://github.com/containerd/ttrpc/compare/699c4e40d1e7416e08bf7019c7ce2e9beced4636...92c8520ef9f86600c650dd540266a007bf03670f changes: - containerd/ttrpc#37 Handle EOF to prevent file descriptor leak - containerd/ttrpc#38 Improve connection error handling - containerd/ttrpc#40 Support headers - containerd/ttrpc#41 Add client and server unary interceptors - containerd/ttrpc#43 metadata as KeyValue type - containerd/ttrpc#42 Refactor close handling for ttrpc clients - containerd/ttrpc#44 Fix method full name generation - containerd/ttrpc#46 Client.Call(): do not return error if no Status is set (gRPC v1.23 and up) - containerd/ttrpc#49 Handle ok status Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Daniel Black

commit sha 7b4b940470ee34c96bf434b810e4cd5ca2e68182

/containers/{id}/json missing Platform To match ContainerJSONBase api/types/types.go Signed-off-by: Daniel Black <daniel@linux.ibm.com>

view details

Simon Barendse

commit sha ea65f0bca2f778412a3ca1b662eb70ee23903fae

Fix getting the operating system on Darwin This used to return "Darwin\n", but now returns "Darwin" Signed-off-by: Simon Barendse <simon.barendse@gmail.com>

view details

Simon Barendse

commit sha fa29ff22124b41e30360b83b93072fbab53d99b8

Fix compiling pkg/parsers/operatingsystem on unix fmt.Error does not exist. I've replaced it with errors.New. Signed-off-by: Simon Barendse <simon.barendse@gmail.com>

view details

Michael Crosby

commit sha e4605cc2a5624f0eb7922cce4d182f3b1ee73e4d

Add sigprocmask to default seccomp profile Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

view details

Sebastiaan van Stijn

commit sha 1250e42a43e5c2dd3efbcbc20c7fa3804c3dc3fb

daemon:containerStart() fix unhandled error for saveApparmorConfig Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha 156ad54fb707ed8b03a1084a841ef5602198799a

windows.ps1: fix leaked NdisAdapters not being cleaned up on RS1 Windows RS1 has problems with leaking NdisAdapters during the integration tests; the windows.ps1 script has a cleanup stesp to remove those leaked adapters. For internal testing at Microsoft on internal builds, this cleanup step was skipped, and only ran on the CI machines in our Jenkins. Due to the move to our new Jenkins, the names of Windows machines changed, and because of that, the cleanup step was never executed, resulting in the leaked adapters not being cleaned up: ``` 20:32:23 WARNING: There are 608 NdisAdapters leaked under Psched\Parameters 20:32:23 WARNING: Not cleaning as not a production RS1 server 20:32:24 WARNING: There are 608 NdisAdapters leaked under WFPLWFS\Parameters 20:32:24 WARNING: Not cleaning as not a production RS1 server ``` ``` 22:01:31 WARNING: There are 1209 NdisAdapters leaked under Psched\Parameters 22:01:31 WARNING: Not cleaning as not a production RS1 server 22:01:31 WARNING: There are 1209 NdisAdapters leaked under WFPLWFS\Parameters 22:01:31 WARNING: Not cleaning as not a production RS1 server ``` This patch removes the check for non-production builds, and unconditionally cleans up leaked adapters if they are found. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha 8877d8e1b96ce9412583adc3f70e140153a3ba1a

Merge pull request #39824 from crosbymichael/sigprocmask Add sigprocmask to default seccomp profile

view details

push time in 12 hours

push eventmellium/xmpp

Sam Whited

commit sha 791439e357c48487e8e0567feaf946a6135c711b

uri: add missing test and some docs

view details

push time in a day

push eventmellium/mellium.im

Sam Whited

commit sha da5eb808a4c518e3d784f549fb1b62c5a12565e4

xmpp/uri: add new package

view details

push time in a day

delete branch mellium/xmpp

delete branch : iri

delete time in a day

PR merged mellium/xmpp

uri: new package implementing XMPP URI's and IRI's

Implements a parser for XMPP IRIs (see RFC 3987) and URIs (RFC 3986) as defined in RFC 5122. Because it piggybacks on net/url, it may make a handful of invalid assumptions but it should parse most common XMPP IRI's. It also needs a lot of work on the efficiency front to prevent having to escape and unescape repeatedly.

+429 -0

0 comment

3 changed files

SamWhited

pr closed time in a day

push eventmellium/xmpp

Sam Whited

commit sha d0f13824e7dcfc8ec664b3ff2548f2be94bd7254

uri: new package implementing XMPP URI's and IRI's

view details

push time in a day

Pull request review commentmellium/xmpp

uri: new package implementing XMPP URI's and IRI's

+// Copyright 2019 The Mellium Contributors.+// Use of this source code is governed by the BSD 2-clause+// license that can be found in the LICENSE file.++// Package uri parses XMPP URI and IRI's as defined in RFC 5122.+//+// It also provides easy access to query components defined in XEP-0147: XMPP+// URI Scheme Query Components and the XMPP URI/IRI Querytypes registry.+package uri++import (+	"errors"+	"fmt"+	"net/url"+	"strings"+	"unicode/utf8"++	"mellium.im/xmpp/jid"+)++var (+	errBadScheme = errors.New("uri: expected scheme xmpp")+)++// URI is a parsed XMPP URI or IRI.+type URI struct {+	*url.URL++	ToAddr   jid.JID+	AuthAddr jid.JID+	Action   string+}++// TODO: encoding and escaping, see+// https://tools.ietf.org/html/rfc5122#section-2.7.2++// Parse parses rawuri into a URI structure.+func Parse(rawuri string) (*URI, error) {+	u, err := url.Parse(rawuri)+	if err != nil {+		return nil, err+	}++	if u.Scheme != "xmpp" {+		return nil, errBadScheme+	}++	uri := &URI{+		URL: u,+	}++	if u.Host != "" {+		// If an authentication address was provided (ie. the URI started with+		// `xmpp://'), parse it out and take the recipient address from the path.++		uri.AuthAddr, err = jid.New(u.User.Username(), u.Hostname(), "")+		if err != nil {+			return nil, err+		}+		if u.Path != "" {+			// Strip the root / and use the path as the JID.+			iri, err := toIRI(u.Path[1:], false)+			if err != nil {+				return nil, err+			}+			uri.ToAddr, err = jid.Parse(iri)+			if err != nil {+				return nil, err+			}+		}+	} else {+		// If no auth address was provided (ie. the URI started with `xmpp:') take+		// the recipient address from the opaque part and ignore the user info.+		iri, err := toIRI(u.Opaque, true)+		if err != nil {+			return nil, err+		}+		uri.ToAddr, err = jid.Parse(iri)+		if err != nil {+			return nil, err+		}+	}++	for k, v := range u.Query() {+		if len(v) == 0 || len(v) == 1 && v[0] == "" {+			uri.Action = k+			break+		}+	}++	return uri, err+}++// String reassembles the URI or IRI Into a valid IRI string.+func (u *URI) String() string {+	iri, _ := toIRI(u.URL.String(), true)+	return iri+}++// toIRI converts the URI to a valid IRI using the algorithm defined in RFC 3987+// §3.2.+// It does not validate that the input is a valid URI.+func toIRI(u string, needsUnescape bool) (string, error) {+	// 1.  Represent the URI as a sequence of octets in US-ASCII.+	//+	// 2.  Convert all percent-encodings ("%" followed by two hexadecimal+	//     digits) to the corresponding octets, except those corresponding+	//     to "%", characters in "reserved", and characters in US-ASCII not+	//     allowed in URIs.+	// TODO: using PathUnescape to create a new string is very inefficient, but+	// it's the only method available in the standard library for this.+	// In the future we should write an escape/unescaper that implements+	// "golang.org/x/text/transform".Transformer or simply appends to a buffer or+	// byte slice so that the next step can also be done in the same iteration+	// without creating yet another builder.+	var err error+	if needsUnescape {+		u, err = url.PathUnescape(u)+		if err != nil {+			return "", err+		}+	}++	// 3. Re-percent-encode any octet produced in step 2 that is not part+	//    of a strictly legal UTF-8 octet sequence.+	// 4. Re-percent-encode all octets produced in step 3 that in UTF-8+	//    represent characters that are not appropriate according to+	//    sections 2.2, 4.1, and 6.1.+	u = escapeInvalidUTF8(u)++	// 5. Interpret the resulting octet sequence as a sequence of characters+	//    encoded in UTF-8.+	// TODO:++	return u, nil+}++// escapeInvalidUTF8 is like strings.ToValidUTF8 except that it replaces invalid+// UTF8 with % encoded versions of the invalid bytes instead of a fixed string.+func escapeInvalidUTF8(s string) string {

Wrote a nicer implementation that's much easier to read, but it's far less optimized than the version from the standard library (as you might expect) and I can't see a good way to get similar performance (mine was an ~3.5x slowdown) and the same readability. Given that it wasn't even all that much easier to follow, I'll stick with this implementation for now while I think about it more.

SamWhited

comment created time in a day

push eventmellium/xmpp

push time in a day

push eventmellium/xmpp

Sam Whited

commit sha 0351897e1390da87d184fbe4396b5f2a363ad1f3

uri: rewrite escaping to be more readable

view details

push time in a day

push eventtiborvass/docker

Sam Whited

commit sha 5e05d3e9b567a2f1f4b914e3e423a73e13f250d5

Run buildkit integration tests Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Andrew Hsu

commit sha c9b2b4c505520fd2c1b7d85e915b7f6486651dad

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com> Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 2 days

push eventtiborvass/docker

Sam Whited

commit sha 449ebc6ec3e067933ad30c725bdab1879f3aade4

Run buildkit integration tests Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Andrew Hsu

commit sha 8565a7b47505aefd589124af5d19a4460a5cd7fb

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com> Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 2 days

pull request commentmoby/moby

Run buildkit integration tests

@tibor can you mark this as ready for review? I don't have permissions. Thanks!

tiborvass

comment created time in 2 days

pull request commentmoby/moby

vendor: update buildkit

Closing for now since this is just vendoring and it shouldn't be taking up space on peoples dashboards. I'll reopen as soon as the dependencies are merged.

SamWhited

comment created time in 2 days

PR closed moby/moby

vendor: update buildkit

Bump to latest buildkit to fix some issues that have already been fixed by @tonistiigi in https://github.com/moby/buildkit/pull/1228

Caught by a test run of #40023.

+1355 -471

2 comments

18 changed files

SamWhited

pr closed time in 2 days

push eventSamWhited/buildkit

Sam Whited

commit sha 00bfbab0390c02c11ae86e74e82f29d424d41532

all: bump the systemd dep to use Go Modules Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 2 days

PR opened moby/buildkit

all: bump the systemd dep to use Go Modules

There is really only one small change to the library itself; v21 moved a package that we don't use into internal/, fixed an error that likely never happens, and made a few minor linter fixes. v22 just moved fully to modules support.

Pushing this to get rid of one more meta version and make it easier for us to pin to specific releases going forward.

+8 -4

0 comment

8 changed files

pr created time in 2 days

create barnchSamWhited/buildkit

branch : bump_systemd_dep

created branch time in 2 days

Pull request review commentmellium/xmpp

uri: new package implementing XMPP URI's and IRI's

+// Copyright 2019 The Mellium Contributors.+// Use of this source code is governed by the BSD 2-clause+// license that can be found in the LICENSE file.++// Package uri parses XMPP URI and IRI's as defined in RFC 5122.+//+// It also provides easy access to query components defined in XEP-0147: XMPP+// URI Scheme Query Components and the XMPP URI/IRI Querytypes registry.+package uri++import (+	"errors"+	"fmt"+	"net/url"+	"strings"+	"unicode/utf8"++	"mellium.im/xmpp/jid"+)++var (+	errBadScheme = errors.New("uri: expected scheme xmpp")+)++// URI is a parsed XMPP URI or IRI.+type URI struct {+	*url.URL++	ToAddr   jid.JID+	AuthAddr jid.JID+	Action   string+}++// TODO: encoding and escaping, see+// https://tools.ietf.org/html/rfc5122#section-2.7.2++// Parse parses rawuri into a URI structure.+func Parse(rawuri string) (*URI, error) {+	u, err := url.Parse(rawuri)+	if err != nil {+		return nil, err+	}++	if u.Scheme != "xmpp" {+		return nil, errBadScheme+	}++	uri := &URI{+		URL: u,+	}++	if u.Host != "" {+		// If an authentication address was provided (ie. the URI started with+		// `xmpp://'), parse it out and take the recipient address from the path.++		uri.AuthAddr, err = jid.New(u.User.Username(), u.Hostname(), "")+		if err != nil {+			return nil, err+		}+		if u.Path != "" {+			// Strip the root / and use the path as the JID.+			iri, err := toIRI(u.Path[1:], false)+			if err != nil {+				return nil, err+			}+			uri.ToAddr, err = jid.Parse(iri)+			if err != nil {+				return nil, err+			}+		}+	} else {+		// If no auth address was provided (ie. the URI started with `xmpp:') take+		// the recipient address from the opaque part and ignore the user info.+		iri, err := toIRI(u.Opaque, true)+		if err != nil {+			return nil, err+		}+		uri.ToAddr, err = jid.Parse(iri)+		if err != nil {+			return nil, err+		}+	}++	for k, v := range u.Query() {+		if len(v) == 0 || len(v) == 1 && v[0] == "" {+			uri.Action = k+			break+		}+	}++	return uri, err+}++// String reassembles the URI or IRI Into a valid IRI string.+func (u *URI) String() string {+	iri, _ := toIRI(u.URL.String(), true)+	return iri+}++// toIRI converts the URI to a valid IRI using the algorithm defined in RFC 3987+// §3.2.+// It does not validate that the input is a valid URI.+func toIRI(u string, needsUnescape bool) (string, error) {+	// 1.  Represent the URI as a sequence of octets in US-ASCII.+	//+	// 2.  Convert all percent-encodings ("%" followed by two hexadecimal+	//     digits) to the corresponding octets, except those corresponding+	//     to "%", characters in "reserved", and characters in US-ASCII not+	//     allowed in URIs.+	// TODO: using PathUnescape to create a new string is very inefficient, but+	// it's the only method available in the standard library for this.+	// In the future we should write an escape/unescaper that implements+	// "golang.org/x/text/transform".Transformer or simply appends to a buffer or+	// byte slice so that the next step can also be done in the same iteration+	// without creating yet another builder.+	var err error+	if needsUnescape {+		u, err = url.PathUnescape(u)+		if err != nil {+			return "", err+		}+	}++	// 3. Re-percent-encode any octet produced in step 2 that is not part+	//    of a strictly legal UTF-8 octet sequence.+	// 4. Re-percent-encode all octets produced in step 3 that in UTF-8+	//    represent characters that are not appropriate according to+	//    sections 2.2, 4.1, and 6.1.+	u = escapeInvalidUTF8(u)++	// 5. Interpret the resulting octet sequence as a sequence of characters+	//    encoded in UTF-8.+	// TODO:++	return u, nil+}++// escapeInvalidUTF8 is like strings.ToValidUTF8 except that it replaces invalid+// UTF8 with % encoded versions of the invalid bytes instead of a fixed string.+func escapeInvalidUTF8(s string) string {

This needs to be rewritten before merge; this got copied, then its purpose changed and a bunch of stuff got tacked on, and now it's a monstrosity.

SamWhited

comment created time in 2 days

push eventmellium/xmpp

Sam Whited

commit sha d0f13824e7dcfc8ec664b3ff2548f2be94bd7254

uri: new package implementing XMPP URI's and IRI's

view details

push time in 2 days

push eventmellium/xmpp

Sam Whited

commit sha d119a9f66dfc36a782c15a1e4d50b029842d7ab4

uri: new package implementing XMPP URI's and IRI's

view details

push time in 2 days

push eventmellium/xmpp

Sam Whited

commit sha 1f60593eea0c356552de676ae95c4bc21a98761e

uri: new package implementing XMPP URI's and IRI's

view details

push time in 2 days

PR opened mellium/xmpp

uri: new package implementing XMPP URI's and IRI's

Implements a parser for XMPP IRIs and URIs as defined in RFC 5122. Because it piggybacks on net/url, it may make a handful of invalid assumptions but it should parse most common XMPP IRI's.

+420 -0

0 comment

3 changed files

pr created time in 2 days

create barnchmellium/xmpp

branch : iri

created branch time in 2 days

push eventmellium/xmpp

Sam Whited

commit sha 07676d2b962101dd4479193f175d50f61281b378

jid: move all errors to the top of the file Not only will this make them easier to reuse later, it makes it possible to extract them into other packages tests by deliberately parsing a bad JID, this way they can be compared for equality or using errors.Is.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 751e75381c648e341505c199c1ea78c7bbb74f72

dial: remove all tests The dial tests are passing on FreeBSD, but sometimes blocking forever on Linux, not to mention they're very slow. Until I can figure out a better way to handle the DNS resolution tests, remove them alltogether.

view details

push time in 3 days

PR closed mellium/xmpp

.builds: add DCO check

Adds an experimental DCO check. I am unsure if I want to use the DCO for this repo, so feedback would be appreciated.

+81 -0

1 comment

3 changed files

SamWhited

pr closed time in 3 days

pull request commentmellium/xmpp

.builds: add DCO check

I'm not going to add a DCO check right this moment. I do like it better than a CLA, but it's still an extra hoop that contributors would have to jump through and doesn't really solve a problem since it's mostly only me working on this project right now.

SamWhited

comment created time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 7ee19a085d1e358735f4c2e34321600b241418f0

dial: fix flaky test Previous a request might be made for A or AAAA records depending on what networks were available. We don't care which is used, so normalize all requests that we record to AAAA which was already being used in the tests.

view details

Sam Whited

commit sha 770c912e6e3b08841e1bc44965c16bee8419b231

.builds: fix GitHub integration Apparently having .git at the end of the URL breaks dispatch.sr.ht, per https://man.sr.ht/dispatch.sr.ht/github.md

view details

Sam Whited

commit sha f4362edbdfb8bd8216cdaada1387a1a96c793dc8

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

Sam Whited

commit sha 0c374f1d2b0f2c5067a54cb2f3f69fcb94d315a8

.builds: add DCO check

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 6338ecd5dfe3ae3fd17bb120194b0ec8cf0597c6

dial: check DNS questions in tests

view details

Sam Whited

commit sha 7ee19a085d1e358735f4c2e34321600b241418f0

dial: fix flaky test Previous a request might be made for A or AAAA records depending on what networks were available. We don't care which is used, so normalize all requests that we record to AAAA which was already being used in the tests.

view details

Sam Whited

commit sha 770c912e6e3b08841e1bc44965c16bee8419b231

.builds: fix GitHub integration Apparently having .git at the end of the URL breaks dispatch.sr.ht, per https://man.sr.ht/dispatch.sr.ht/github.md

view details

Sam Whited

commit sha f4362edbdfb8bd8216cdaada1387a1a96c793dc8

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

Sam Whited

commit sha 03e6fd352b5b154c3dc03e4ec67c52e20dcd12ad

examples/im: new example similar to sendxmpp(1)

view details

push time in 3 days

delete branch mellium/xmpp

delete branch : dial_tests_locking

delete time in 3 days

PR merged mellium/xmpp

dial: wait for server to shut down before finishing tests

The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

+14 -4

0 comment

3 changed files

SamWhited

pr closed time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 770c912e6e3b08841e1bc44965c16bee8419b231

.builds: fix GitHub integration Apparently having .git at the end of the URL breaks dispatch.sr.ht, per https://man.sr.ht/dispatch.sr.ht/github.md

view details

Sam Whited

commit sha f4362edbdfb8bd8216cdaada1387a1a96c793dc8

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha f4362edbdfb8bd8216cdaada1387a1a96c793dc8

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 2bd36c9e8c6f80f76d1347f37725d92b1472393d

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 30be500aa2422d3ab1135a22bb07972a5729c1bb

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 770c912e6e3b08841e1bc44965c16bee8419b231

.builds: fix GitHub integration Apparently having .git at the end of the URL breaks dispatch.sr.ht, per https://man.sr.ht/dispatch.sr.ht/github.md

view details

Sam Whited

commit sha 060349cd8e9f2eed018a41ba34afac62028a73e7

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 91f203d6fb4a158a2273a0858ef15516bdcf1690

dial: wait for testing DNS server to shut down The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

Sam Whited

commit sha b52db008bdd51ea38d7357dad09d354ec5f55ec1

.builds: fix GitHub integration Apparently having .git at the end of the URL breaks dispatch.sr.ht, per https://man.sr.ht/dispatch.sr.ht/github.md

view details

push time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 394176c6a8ac83f4e89a3abb76ea8f65ce87b2f6

dial: add locking around testing output The append is sometimes happening after the tests have completed, resulting in a failure. Wait until the DNS server goroutine shuts down to check the test results.

view details

push time in 3 days

PR opened mellium/xmpp

dial: add locking around testing output

Dial tests were breaking on FreeBSD, but when examining the requests being made they appeared to be right so I am taking a stab in the dark that this is a race condition.

+8 -0

0 comment

1 changed file

pr created time in 3 days

create barnchmellium/xmpp

branch : dial_tests_locking

created branch time in 3 days

push eventmellium/xmpp

Sam Whited

commit sha 7ee19a085d1e358735f4c2e34321600b241418f0

dial: fix flaky test Previous a request might be made for A or AAAA records depending on what networks were available. We don't care which is used, so normalize all requests that we record to AAAA which was already being used in the tests.

view details

push time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 6338ecd5dfe3ae3fd17bb120194b0ec8cf0597c6

dial: check DNS questions in tests

view details

Sam Whited

commit sha e3f79dce57f3750effa15ec89b349714ea3cde97

.builds: add DCO check

view details

push time in 4 days

delete branch mellium/xmpp

delete branch : improve_dial_tests

delete time in 4 days

PR merged mellium/xmpp

dial: check DNS questions in tests

Tests for the dial package were sadly incomplete. This is the start of a way to test the public interface that can replace some of the tests for internal components and do a better job of testing end-to-end without requiring actual integration tests that need external resources.

It is rather slow and requires a lot of extra testing infrastructure that makes me a bit nervous, so I'm unsure if I want to merge it yet.

+147 -24

0 comment

2 changed files

SamWhited

pr closed time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 6338ecd5dfe3ae3fd17bb120194b0ec8cf0597c6

dial: check DNS questions in tests

view details

push time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 7c24d94058abedf8bd00ad68ea46505add19554e

examples/im: new example similar to sendxmpp(1)

view details

push time in 4 days

PR opened mellium/xmpp

examples/im: new example similar to sendxmpp(1) and mail(1)

Add another example similar to sendxmpp(1).

+273 -0

0 comment

3 changed files

pr created time in 4 days

create barnchmellium/xmpp

branch : add_im_example

created branch time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 699e77a2cd78fc8620ebf3192eb2de5a5cfe0ecc

.builds: add DCO check Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 279e27dc12c675786c6f277d5a7c6075c348935d

.builds: add DCO check Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha 667fa6b235fd64d30461da9ba92ab094801de1f2

.builds: add DCO check

view details

push time in 4 days

PR opened mellium/xmpp

.builds: add DCO check

Adds an experimental DCO check. I am unsure if I want to use the DCO for this repo, so feedback would be appreciated.

+80 -0

0 comment

3 changed files

pr created time in 4 days

create barnchmellium/xmpp

branch : dco_check

created branch time in 4 days

PR opened mellium/xmpp

dial: check DNS questions in tests

Tests for the dial package were sadly incomplete. This is the start of a way to test the public interface that can replace some of the tests for internal components and do a better job of testing end-to-end without requiring actual integration tests that need external resources.

It is rather slow and requires a lot of extra testing infrastructure that makes me a bit nervous, so I'm unsure if I want to merge it yet.

+147 -24

0 comment

2 changed files

pr created time in 4 days

create barnchmellium/xmpp

branch : improve_dial_tests

created branch time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha d64d96a2cc00a213856e82b1baa8569e7c34dff4

xmpp: fix missing argument in package level docs

view details

push time in 4 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

 ADD %s /dest/ }  func testDockerfileAddArchive(t *testing.T, sb integration.Sandbox) {+	skipDockerd(t, sb)

Can we do that in a followup PR since this one has been open for a while? I've got a list of minor followups I can add this to

SamWhited

comment created time in 4 days

push eventmellium/xmpp

Sam Whited

commit sha cc941b65880aae48d648fe1f864f0994db18e93b

dial: fix broken tests

view details

push time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

+package integration++import (+	"bytes"+	"context"+	"fmt"+	"io"+	"io/ioutil"+	"net"+	"time"++	"github.com/docker/docker/testutil/daemon"+)++const dockerdBinary = "dockerd"++type logTAdapter struct {+	Name string+	Logs map[string]*bytes.Buffer+}++func (l logTAdapter) Logf(format string, v ...interface{}) {+	if buf, ok := l.Logs[l.Name]; !ok || buf == nil {+		l.Logs[l.Name] = &bytes.Buffer{}+	}+	fmt.Fprintf(l.Logs[l.Name], format, v...)+}++// InitDockerdWorker registers a dockerd worker with the global registry.+func InitDockerdWorker() {+	Register(&dockerd{})+}++type dockerd struct{}++func (c dockerd) Name() string {+	return dockerdBinary+}++func (c dockerd) New(cfg *BackendConfig) (b Backend, cl func() error, err error) {+	if err := requireRoot(); err != nil {+		return nil, nil, err+	}++	deferF := &multiCloser{}+	cl = deferF.F()++	defer func() {+		if err != nil {+			deferF.F()()+			cl = nil+		}+	}()++	workDir, err := ioutil.TempDir("", "integration")+	if err != nil {+		return nil, nil, err+	}++	cmd, err := daemon.NewDaemon(+		workDir,+		daemon.WithTestLogger(logTAdapter{+			Name: "creatingDaemon",+			Logs: cfg.Logs,+		}),+		daemon.WithContainerdSocket(""),+	)+	if err != nil {+		return nil, nil, fmt.Errorf("new daemon error: %q, %s", err, formatLogs(cfg.Logs))+	}++	err = cmd.StartWithError()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(cmd.StopWithError)++	logs := map[string]*bytes.Buffer{}+	if err := waitUnix(cmd.Sock(), 5*time.Second); err != nil {+		return nil, nil, fmt.Errorf("dockerd did not start up: %q, %s", err, formatLogs(logs))+	}++	ctx, cancel := context.WithCancel(context.Background())+	deferF.append(func() error { cancel(); return nil })++	dockerAPI, err := cmd.NewClient()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(dockerAPI.Close)++	listener, err := net.Listen("tcp", ":0")+	if err != nil {+		return nil, nil, err+	}+	deferF.append(listener.Close)++	go func() {+		for {+			tmpConn, err := listener.Accept()+			if err != nil {+				return+			}+			conn, err := dockerAPI.DialHijack(ctx, "/grpc", "h2c", nil)+			if err != nil {+				return+			}++			go func() {

Returned the first error in the deferF which I had forgotten about, this should end up causing the test to fail and logging.

SamWhited

comment created time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 58cf258aff50c4e6ff960a150c66eeea65692815

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 17e3dfdce8bd2fd16a7ba502617adf44a67f32bb

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

+package integration++import (+	"bytes"+	"context"+	"fmt"+	"io"+	"io/ioutil"+	"net"+	"time"++	"github.com/docker/docker/testutil/daemon"+)++const dockerdBinary = "dockerd"++type logTAdapter struct {+	Name string+	Logs map[string]*bytes.Buffer+}++func (l logTAdapter) Logf(format string, v ...interface{}) {+	if buf, ok := l.Logs[l.Name]; !ok || buf == nil {+		l.Logs[l.Name] = &bytes.Buffer{}+	}+	fmt.Fprintf(l.Logs[l.Name], format, v...)+}++// InitDockerdWorker registers a dockerd worker with the global registry.+func InitDockerdWorker() {+	Register(&dockerd{})+}++type dockerd struct{}++func (c dockerd) Name() string {+	return dockerdBinary+}++func (c dockerd) New(cfg *BackendConfig) (b Backend, cl func() error, err error) {+	if err := requireRoot(); err != nil {+		return nil, nil, err+	}++	deferF := &multiCloser{}+	cl = deferF.F()++	defer func() {+		if err != nil {+			deferF.F()()+			cl = nil+		}+	}()++	workDir, err := ioutil.TempDir("", "integration")+	if err != nil {+		return nil, nil, err+	}++	cmd, err := daemon.NewDaemon(+		workDir,+		daemon.WithTestLogger(logTAdapter{+			Name: "creatingDaemon",+			Logs: cfg.Logs,+		}),+		daemon.WithContainerdSocket(""),+	)+	if err != nil {+		return nil, nil, fmt.Errorf("new daemon error: %q, %s", err, formatLogs(cfg.Logs))+	}++	err = cmd.StartWithError()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(cmd.StopWithError)++	logs := map[string]*bytes.Buffer{}+	if err := waitUnix(cmd.Sock(), 5*time.Second); err != nil {+		return nil, nil, fmt.Errorf("dockerd did not start up: %q, %s", err, formatLogs(logs))+	}++	ctx, cancel := context.WithCancel(context.Background())+	deferF.append(func() error { cancel(); return nil })++	dockerAPI, err := cmd.NewClient()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(dockerAPI.Close)++	listener, err := net.Listen("tcp", ":0")+	if err != nil {+		return nil, nil, err+	}+	deferF.append(listener.Close)++	go func() {+		for {+			tmpConn, err := listener.Accept()+			if err != nil {+				return+			}+			conn, err := dockerAPI.DialHijack(ctx, "/grpc", "h2c", nil)+			if err != nil {+				return+			}++			go func() {

Logging would be good, but I don't see a good way to do that right now. Existing logs in this package just get returned and formatted somewhere else. Even if we add some locking around the log aggregation, they have already been returned by the time this goroutine completes, so I'm not sure there's a good place to do it unless you'd like a larger refactor of how logging works? I'd love to get rid of the aggregation and find a way to stream logs somewhere instead.

SamWhited

comment created time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 552289ab69e678d491e2e37a8a98c5ac8d247e7f

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

+package integration++import (+	"bytes"+	"context"+	"fmt"+	"io"+	"io/ioutil"+	"net"+	"time"++	"github.com/docker/docker/testutil/daemon"+)++const dockerdBinary = "dockerd"++type logTAdapter struct {+	Name string+	Logs map[string]*bytes.Buffer+}++func (l logTAdapter) Logf(format string, v ...interface{}) {+	if buf, ok := l.Logs[l.Name]; !ok || buf == nil {+		l.Logs[l.Name] = &bytes.Buffer{}+	}+	fmt.Fprintf(l.Logs[l.Name], format, v...)+}++// InitDockerdWorker registers a dockerd worker with the global registry.+func InitDockerdWorker() {+	Register(&dockerd{})+}++type dockerd struct{}++func (c dockerd) Name() string {+	return dockerdBinary+}++func (c dockerd) New(cfg *BackendConfig) (b Backend, cl func() error, err error) {+	if err := requireRoot(); err != nil {+		return nil, nil, err+	}++	deferF := &multiCloser{}+	cl = deferF.F()++	defer func() {+		if err != nil {+			deferF.F()()+			cl = nil+		}+	}()++	workDir, err := ioutil.TempDir("", "integration")+	if err != nil {+		return nil, nil, err+	}++	cmd, err := daemon.NewDaemon(+		workDir,+		daemon.WithTestLogger(logTAdapter{+			Name: "creatingDaemon",+			Logs: cfg.Logs,+		}),+		daemon.WithContainerdSocket(""),+	)+	if err != nil {+		return nil, nil, fmt.Errorf("new daemon error: %q, %s", err, formatLogs(cfg.Logs))+	}++	err = cmd.StartWithError()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(cmd.StopWithError)++	logs := map[string]*bytes.Buffer{}+	if err := waitUnix(cmd.Sock(), 5*time.Second); err != nil {+		return nil, nil, fmt.Errorf("dockerd did not start up: %q, %s", err, formatLogs(logs))+	}++	ctx, cancel := context.WithCancel(context.Background())+	deferF.append(func() error { cancel(); return nil })++	dockerAPI, err := cmd.NewClient()+	if err != nil {+		return nil, nil, err+	}+	deferF.append(dockerAPI.Close)++	listener, err := net.Listen("tcp", ":0")

Good call; didn't do this originally because I wasn't sure if we needed Windows support, but it sounds like some magic is happening and it will keep working anyways. Adding it.

SamWhited

comment created time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 64133aca631e95d376647687b3d1bed9de6920c6

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

 func testStdinClosed(t *testing.T, sb integration.Sandbox) { }  func testSSHMount(t *testing.T, sb integration.Sandbox) {+	skipDockerd(t, sb)

I think apk add --no-cache openssh was failing for some reason, might have just been a temporary issue with alpine or something, it doesn't appear to be happening now. Re-enabling this one.

SamWhited

comment created time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

 func testExporterTargetExists(t *testing.T, sb integration.Sandbox) { }  func testTarExporterWithSocket(t *testing.T, sb integration.Sandbox) {+	if os.Getenv("TEST_DOCKERD") == "1" {

@tiborvass can provide more context on this one, I think it just needs a workaround cherry picked:

--- FAIL: TestIntegration (4.21s)                                                                
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:46175/library/alpine:latest
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:46175/library/busybox:latest                                                                                       
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:36189/library/busybox:latest                                                                                       
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:36189/library/alpine:latest                                                                                         
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:46565/library/alpine:latest                                                                                         
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:46565/library/busybox:latest                                                                                       
    --- FAIL: TestIntegration/TestTarExporterWithSocket/worker=dockerd (7.20s)                                                                                                                     
        require.go:794:                                                                                                                                                                            
                Error Trace:    client_test.go:1534                                              
                                                        run.go:164                                                                                                                                 
                Error:          Received unexpected error:                                                                                                                                         
                                rpc error: code = Unknown desc = archive/tar: sockets not supported                                                                                                
                                failed to solve                                                                                                                                                    
                                github.com/moby/buildkit/client.(*Client).solve.func2                                                                                                              
                                        /go/src/github.com/docker/docker/buildkit/client/solve.go:203                                                                                              
                                golang.org/x/sync/errgroup.(*Group).Go.func1                                                                                                                       
                                        /go/src/github.com/docker/docker/buildkit/vendor/golang.org/x/sync/errgroup/errgroup.go:57
                                runtime.goexit                                                   
                                        /usr/local/go/src/runtime/asm_amd64.s:1357                                                                                                                 
                Test:           TestIntegration/TestTarExporterWithSocket/worker=dockerd                                                                                                           
        oci.go:74: creatingDaemon                                                                
        oci.go:77: [d032d6151cfb9] waiting for daemon to start[d032d6151cfb9] waiting for daemon to start[d032d6151cfb9] daemon started
        oci.go:77: [d032d6151cfb9] stopping daemon[d032d6151cfb9] exiting daemon[d032d6151cfb9] daemon stopped                                                                                     
FAIL                                                                                                                                                                                               
FAIL    github.com/moby/buildkit/client 13.736s
SamWhited

comment created time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

 ADD %s /dest/ }  func testDockerfileAddArchive(t *testing.T, sb integration.Sandbox) {+	skipDockerd(t, sb)
--- FAIL: TestIntegration (10.95s)                                                                                                                
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:34343/library/busybox:latest                                      
    run.go:219: copied docker.io/docker/dockerfile-copy:v0.1.9@sha256:e8f159d3f00786604b93c675ee2783f8dc194bb565e61ca5788f6a6e9d304061 to local mirror localhost:34343/docker/dockerfile-copy:v0.1.9
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:37649/library/busybox:latest                                      
    run.go:219: copied docker.io/docker/dockerfile-copy:v0.1.9@sha256:e8f159d3f00786604b93c675ee2783f8dc194bb565e61ca5788f6a6e9d304061 to local mirror localhost:37649/docker/dockerfile-copy:v0.1.9
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:38031/library/busybox:latest                                       
    run.go:219: copied docker.io/docker/dockerfile-copy:v0.1.9@sha256:e8f159d3f00786604b93c675ee2783f8dc194bb565e61ca5788f6a6e9d304061 to local mirror localhost:38031/docker/dockerfile-copy:v0.1.9
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:34943/library/busybox:latest                                      
    run.go:219: copied docker.io/docker/dockerfile-copy:v0.1.9@sha256:e8f159d3f00786604b93c675ee2783f8dc194bb565e61ca5788f6a6e9d304061 to local mirror localhost:34943/docker/dockerfile-copy:v0.1.9
    --- FAIL: TestIntegration/TestDockerfileAddArchive/worker=dockerd/frontend=builtin (1.52s)                                                    
        require.go:794:                                                                                                                           
                Error Trace:    dockerfile_test.go:2048        
                                                        run.go:164                                                                                
                Error:          Received unexpected error:                                                                                        
                                exec: "buildctl": executable file not found in $PATH                                                              
                Test:           TestIntegration/TestDockerfileAddArchive/worker=dockerd/frontend=builtin                                          
        oci.go:74: creatingDaemon                                                                                                                 
        oci.go:77: [d851e2a4f0f71] waiting for daemon to start[d851e2a4f0f71] waiting for daemon to start[d851e2a4f0f71] daemon started
        oci.go:77: [d851e2a4f0f71] stopping daemon[d851e2a4f0f71] exiting daemon[d851e2a4f0f71] daemon stopped
FAIL
SamWhited

comment created time in 5 days

Pull request review commentmoby/buildkit

Run integration tests against dockerd

 ADD %s /dest/ }  func testDockerfileAddArchive(t *testing.T, sb integration.Sandbox) {+	skipDockerd(t, sb)
--- FAIL: TestIntegration (4.32s)                                                                                                                 
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:36763/library/busybox:latest                                     
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:36763/library/alpine:latest                                       
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:37249/library/busybox:latest                                     
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:37249/library/alpine:latest                                       
    run.go:219: copied docker.io/amd64/alpine:latest to local mirror localhost:44681/library/alpine:latest                                       
    run.go:219: copied docker.io/amd64/busybox:latest to local mirror localhost:44681/library/busybox:latest                                     
    --- FAIL: TestIntegration/TestBuildPushAndValidate/worker=dockerd (4.59s)                                                                    
        require.go:794:                                                                                                                           
                Error Trace:    client_test.go:1580                                                                                               
                                                        run.go:164                                                                                
                Error:          Received unexpected error:                                                                                        
                                rpc error: code = Unknown desc = exporter "image" could not be found                                             
                                failed to solve                                                                                                   
                                github.com/moby/buildkit/client.(*Client).solve.func2                                                            
                                        /go/src/github.com/docker/docker/buildkit/client/solve.go:203                                            
                                golang.org/x/sync/errgroup.(*Group).Go.func1                                                                     
                                        /go/src/github.com/docker/docker/buildkit/vendor/golang.org/x/sync/errgroup/errgroup.go:57               
                                runtime.goexit                                                                                                    
                                        /usr/local/go/src/runtime/asm_amd64.s:1357                                                                
                Test:           TestIntegration/TestBuildPushAndValidate/worker=dockerd                                                           
        oci.go:74: creatingDaemon                                                                                                                 
        oci.go:77: [d558988a16523] waiting for daemon to start[d558988a16523] waiting for daemon to start[d558988a16523] daemon started           
        oci.go:77: [d558988a16523] stopping daemon[d558988a16523] exiting daemon[d558988a16523] daemon stopped                                    
FAIL                                                                                                                                              
FAIL    github.com/moby/buildkit/client 10.541
SamWhited

comment created time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 32d075ce574b57d74cfa0354b7ba3650950d5ad0

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha 6a513c8730ecbd5930aff781058cf380c85398be

all: run integration tests against dockerd Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

PR closed moby/buildkit

client: add context to some test failures

The use of an assertion framework is masking the underlying error, making my test failure harder to debug. This adds some context around the failures so that the underlying error is discoverable, and so that someone reading the test output knows what is being tested (not just that true != false).

+6 -2

1 comment

1 changed file

SamWhited

pr closed time in 5 days

Pull request review commentmoby/buildkit

client: add context to some test failures

 func testFileOpRmWildcard(t *testing.T, sb integration.Sandbox) { 	require.Equal(t, true, fi.IsDir())  	_, err = os.Stat(filepath.Join(destDir, "foo/target"))-	require.Equal(t, true, os.IsNotExist(err))+	if !os.IsNotExist(err) {+		t.Errorf("expected %s/foo/target to not exist, got error %v", destDir, err)

Fair enough; I don't really feel comfortable using or introducing the use of more test framework stuff, so I'll close this PR for now and debug locally. At some point I'll write something up on why I think all test frameworks are a bad idea. Thanks for your consideration!

SamWhited

comment created time in 5 days

Pull request review commentmoby/buildkit

client: add context to some test failures

 func testFileOpRmWildcard(t *testing.T, sb integration.Sandbox) { 	require.Equal(t, true, fi.IsDir())  	_, err = os.Stat(filepath.Join(destDir, "foo/target"))-	require.Equal(t, true, os.IsNotExist(err))+	if !os.IsNotExist(err) {+		t.Errorf("expected %s/foo/target to not exist, got error %v", destDir, err)

Does that mean you'd accept a PR to remove it from every test in this repo, because I'll do it :)?

I think this PR provides value as is, and I think the consistency with the vast majority of Go projects is more important than consistency within this project in this particular case.

SamWhited

comment created time in 5 days

Pull request review commentmoby/buildkit

client: add context to some test failures

 func testFileOpRmWildcard(t *testing.T, sb integration.Sandbox) { 	require.Equal(t, true, fi.IsDir())  	_, err = os.Stat(filepath.Join(destDir, "foo/target"))-	require.Equal(t, true, os.IsNotExist(err))+	if !os.IsNotExist(err) {+		t.Errorf("expected %s/foo/target to not exist, got error %v", destDir, err)

Either way. Why is require.True(foo) better than if foo? This just feels like more stuff and I don't see the benefit it provides. The if/t.Errorf is clear and people have already learned Go, they shouldn't need to learn a test framework too (even if it is rather obvious what it's doing in this case, it's still something I have to stop and think about until I've seen it enough and it won't look the same across projects, whereas Go syntax is obviously universal in Go projects).

SamWhited

comment created time in 5 days

PullRequestEvent

PR closed moby/moby

vendor: update buildkit

Bump to latest buildkit to fix some issues that have already been fixed by @tonistiigi in https://github.com/moby/buildkit/pull/1228

Caught by a test run of #40023.

+1355 -471

1 comment

18 changed files

SamWhited

pr closed time in 5 days

pull request commentmoby/moby

vendor: update buildkit

Please wait to merge this until https://github.com/moby/buildkit/pull/1164 is merged and this PR has been updated. Thanks.

SamWhited

comment created time in 5 days

push eventSamWhited/moby

Sam Whited

commit sha 422ad492c4889dfca48d3e5acd0c8ee21ada9557

vendor: update buildkit Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

PR opened moby/moby

vendor: update buildkit

Bump to latest buildkit to fix some issues that have already been fixed by @tonistiigi in https://github.com/moby/buildkit/pull/1228

Caught by a test run of #40023.

+1355 -471

0 comment

18 changed files

pr created time in 5 days

create barnchSamWhited/moby

branch : update_buildkit

created branch time in 5 days

Pull request review commentmoby/moby

hack/validate/vendor: print diff for modified files

 validate_vendor_diff(){ 		vndr 		# check if any files have changed 		diffs="$(git status --porcelain -- vendor 2>/dev/null)"

Should this check vendor.conf as well?

kolyshkin

comment created time in 5 days

Pull request review commentmoby/buildkit

client: add context to some test failures

 func testFileOpRmWildcard(t *testing.T, sb integration.Sandbox) { 	require.Equal(t, true, fi.IsDir())  	_, err = os.Stat(filepath.Join(destDir, "foo/target"))-	require.Equal(t, true, os.IsNotExist(err))+	if !os.IsNotExist(err) {+		t.Errorf("expected %s/foo/target to not exist, got error %v", destDir, err)

This still seems worse than the multi-line version to me. The weird Equal, true, os.IsNotExist seems much less obvious than just !os.IsNotExist(err), sticking to standard Go instead of hiding behavior behind a function seems like a worthwhile goal to me, even if the framework technically allows us to add more context than what was done originally.

SamWhited

comment created time in 5 days

issue commentopthomas-prime/xmpp-webhook

SASL/SCRAM-SHA support using another xmpp lib

It's not really a big deal either way, very few people support SCRAM-SHA-256, and those that do also likely support SHA-1, but thanks for looking into it :)

kishorerv93

comment created time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha a60f82c6cedb847aa76ed4b4f08f78d9d1920c79

client: add context to some test failures Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

push eventSamWhited/buildkit

Sam Whited

commit sha f51a39f48061254c2d2b3ec23aaa4247ae0b636c

client: add context to some test failures Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 5 days

PR opened moby/buildkit

client: add context to some test failures

The use of an assertion framework is masking the underlying error, making my test failure harder to debug. This adds some context around the failures so that the underlying error is discoverable, and so that someone reading the test output knows what is being tested (not just that true != false).

+6 -2

0 comment

1 changed file

pr created time in 5 days

create barnchSamWhited/buildkit

branch : context_around_errors

created branch time in 5 days

pull request commentmoby/buildkit

Run integration tests against dockerd

I'd like to quickly point out that the actual error being encountered in that log for the file that does not exist is masked by the use of a testing framework.

[2019-11-07T17:08:28.346Z]     --- FAIL: TestIntegration/TestFileOpRmWildcard/worker=dockerd (1.60s)

[2019-11-07T17:08:28.346Z]         require.go:157: 

[2019-11-07T17:08:28.346Z]             	Error Trace:	client_test.go:1110

[2019-11-07T17:08:28.346Z]             	            				run.go:164

[2019-11-07T17:08:28.346Z]             	Error:      	Not equal: 

[2019-11-07T17:08:28.346Z]             	            	expected: true

[2019-11-07T17:08:28.346Z]             	            	actual  : false

[2019-11-07T17:08:28.346Z]             	Test:       	TestIntegration/TestFileOpRmWildcard/worker=dockerd

Not context is present in this error message. What are true and false? Why does it matter that they are not equal? What was the actual error that was encountered instead (which we can't even see from digging in the source)? Please don't use testing frameworks. if !os.isNotExist(err) is just as easy to write, and writing out t.Errorf("expected this file to not exist, but got an error %v… maybe a tiny bit longer, but will lead to error messages that are possible to debug. Please take the time to think about what information will be presented in your errors, and whether it is too much or too little during debugging. Test frameworks don't allow you to do this, writing out a bit of information for context does. Thank you for listening to this short rant :)

SamWhited

comment created time in 5 days

pull request commentmoby/buildkit

Run integration tests against dockerd

Looks like another failure got introduced somewhere after the rebase of docker; looking into it: https://ci.docker.com/public/blue/organizations/jenkins/moby/detail/PR-40023/149/pipeline/151

SamWhited

comment created time in 6 days

Pull request review commentmoby/buildkit

Improve solver type godocs

 import ( 	ocispec "github.com/opencontainers/image-spec/specs-go/v1" ) -// Vertex is one node in the build graph+// Vertex is a node in a build graph. Vertex defines an interface for a+// content-addressable operation and its inputs. type Vertex interface {-	// Digest is a content-addressable vertex identifier+	// Digest returns a checksum of the definition up to the vertex including

"all of its inputs"

hinshun

comment created time in 6 days

Pull request review commentmoby/buildkit

Improve solver type godocs

 type CacheLink struct { 	Selector digest.Digest `json:",omitempty"` } -// Op is an implementation for running a vertex+// Op defines how the solver can evaluate the properties of a vertex operation.+// An op is executed in the worker, and is retrieved from the vertex by the+// value of `vertex.Sys()`. The solver is configured with a resolve function to+// convert a `vertex.Sys()` into an `Op`. type Op interface { 	// CacheMap returns structure describing how the operation is cached. 	// Currently only roots are allowed to return multiple cache maps per op. 	CacheMap(context.Context, int) (*CacheMap, bool, error)+ 	// Exec runs an operation given results from previous operations. 	Exec(ctx context.Context, inputs []Result) (outputs []Result, err error) }  type ResultBasedCacheFunc func(context.Context, Result) (digest.Digest, error) +// CacheMap is a description for calculating the cache key of an operation. type CacheMap struct {-	// Digest is a base digest for operation that needs to be combined with-	// inputs cache or selectors for dependencies.+	// Digest returns a checksum for the operation. The operation result can be+	// cached by a checksum that combines this digest and the cache keys of the+	// operation's inputs.+	//+	// For example, in LLB this digest is a manifest digest for OCI images, or+	// commit SHA for git sources. 	Digest digest.Digest-	Deps   []struct {-		// Optional digest that is merged with the cache key of the input++	// Deps contain optional selectors or content-based cache functions for its+	// inputs.+	Deps []struct {+		// Selector is a digest that is merged with the cache key of the input. 		Selector digest.Digest-		// Optional function that returns a digest for the input based on its-		// return value++		// ComputeDigestFunc is a function that returns a digest for the input based

nit: "is a function" is unnecessary, we know that from the type and the name in this case. Maybe just "ComputeDigestFunc should return a digest…" or similar.

hinshun

comment created time in 6 days

Pull request review commentmoby/buildkit

Improve solver type godocs

 import ( 	ocispec "github.com/opencontainers/image-spec/specs-go/v1" ) -// Vertex is one node in the build graph+// Vertex is a node in a build graph. Vertex defines an interface for a

nit: Starting both sentences with "Vertex" feels redundant. Maybe "Vertex is a node in a build graph. It defines an interface…"

hinshun

comment created time in 6 days

push eventtiborvass/docker

Andrew Hsu

commit sha 1102e78c6cb24c9a7452df2d26a657c0846f1f8d

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com> Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 6 days

push eventtiborvass/docker

Andrew Hsu

commit sha 2729d8159875338aeafba78ea09c3a4f9d5669d0

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com> Signed-off-by: Sam Whited <sam@samwhited.com>

view details

push time in 6 days

push eventtiborvass/docker

Hannes Ljungberg

commit sha 4d09fab232ed282d020afbe1e0935b53379df4ad

Update service networks documentation The previous description stated that an array of names / ids could be passed when the API in reality expects objects in the form of NetworkAttachmentConfig. This is fixed by updating the description and adding a definition for NetworkAttachmentConfig. Signed-off-by: Hannes Ljungberg <hannes@5monkeys.se>

view details

Justen Martin

commit sha 3b49bd1d840d64ec603333eae28655b9ff5edc0c

replaced call to deprecated grpc method WithDialer with WithContextDialer Signed-off-by: Justen Martin <jmart@the-coder.com>

view details

Brian Goff

commit sha 6f8c671d702197a189d162d86a3f4cccfa5a3db2

Merge pull request #39495 from hannseman/network-attachment-config-docs Update service networks documentation

view details

Sebastiaan van Stijn

commit sha 3df4f86f21fbcae3535e2231828dce16a1940dbb

swagger: fix "generated code" comment not in correct format As described in https://golang.org/s/generatedcode, Go has a formalized format that should be used to indicate that a file is generated. Matching that format helps linters to skip generated files; From https://golang.org/s/generatedcode (https://github.com/golang/go/issues/13560#issuecomment-288457920); > Generated files are marked by a line of text that matches the regular expression, in Go syntax: > > ^// Code generated .* DO NOT EDIT\.$ > > The `.*` means the tool can put whatever folderol it wants in there, but the comment > must be a single line and must start with `Code generated` and end with `DO NOT EDIT.`, > with a period. > > The text may appear anywhere in the file. This patch updates the template used for our generated types to match that format. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha c511db70ed39f344f41ea8773cc9264a1eeddfda

api/types: re-generate with new template Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Sebastiaan van Stijn

commit sha 6186e9fe8794660d669f19a2e2ba7127321b817f

hack/make/.go-autogen: fix "generated code" comment not in correct format As described in https://golang.org/s/generatedcode, Go has a formalized format that should be used to indicate that a file is generated. Matching that format helps linters to skip generated files; From https://golang.org/s/generatedcode (https://github.com/golang/go/issues/13560#issuecomment-288457920); > Generated files are marked by a line of text that matches the regular expression, in Go syntax: > > ^// Code generated .* DO NOT EDIT\.$ > > The `.*` means the tool can put whatever folderol it wants in there, but the comment > must be a single line and must start with `Code generated` and end with `DO NOT EDIT.`, > with a period. > > The text may appear anywhere in the file. This patch updates the autogenerated code to match that format. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

view details

Brian Goff

commit sha 47c5c67ed825589b0d88d98d05d81c5d22b3e9a9

Merge pull request #40032 from jmartin84/fix-grpc-withdialer-deprecation-warning Fix grpc withdialer deprecation warning

view details

Kirill Kolyshkin

commit sha c36460c437c8c515c543dd31afcbb5c2a9f5dd48

Merge pull request #40077 from thaJeztah/fix_autogen_detection Update "auto-generate" comments to improve detection by linters

view details

Sam Whited

commit sha b96a0c775400821d80972619fbfe6a2070f3e9ba

Add daemon options required by buildkit tests Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Sebastiaan van Stijn

commit sha 31abc6c089eb5acc8161f480335b33b12564a565

Merge pull request #40177 from SamWhited/buildkit_test_options Add daemon options required by buildkit tests

view details

Sam Whited

commit sha 0c9b232bf5263ab896637b394308510c4cfbd45d

Remove unused GlobalFlags Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Akihiro Suda

commit sha 65523469c7e6f100230ba500c1d28516ea6bd384

Merge pull request #40187 from SamWhited/remove_global_args Remove unused GlobalFlags

view details

Sam Whited

commit sha 50efe0f9e9b08de836c5783ff64f7ced524168fc

Run buildkit integration tests Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Andrew Hsu

commit sha f4989bb32c292bf25a4d0edd1e56bdeb433549af

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com>

view details

push time in 6 days

push eventtiborvass/docker

Sam Whited

commit sha a7badc13cafa066f975a97ce1c2f26ac3dbe7b23

Run buildkit integration tests Signed-off-by: Sam Whited <sam@samwhited.com>

view details

Andrew Hsu

commit sha 85e04366fc40d93d4bd4e36340888baa759ceb44

Jenkinsfile: always create bundles tgz for buildkit step Signed-off-by: Andrew Hsu <andrewhsu@docker.com>

view details

push time in 6 days

more