diff --git a/acme/api/handler.go b/acme/api/handler.go index ca5de02e..e6aad131 100644 --- a/acme/api/handler.go +++ b/acme/api/handler.go @@ -16,7 +16,6 @@ import ( "github.com/smallstep/certificates/api/render" "github.com/smallstep/certificates/authority" "github.com/smallstep/certificates/authority/provisioner" - "github.com/smallstep/certificates/utils/debug/q" ) func link(url, typ string) string { @@ -356,8 +355,6 @@ func GetChallenge(w http.ResponseWriter, r *http.Request) { return } - q.Q(ch) - linker.LinkChallenge(ctx, ch, azID) w.Header().Add("Link", link(linker.GetLink(ctx, acme.AuthzLinkType, azID), "up")) diff --git a/acme/db/nosql/challenge.go b/acme/db/nosql/challenge.go index bb1c4080..c9224574 100644 --- a/acme/db/nosql/challenge.go +++ b/acme/db/nosql/challenge.go @@ -10,7 +10,6 @@ import ( "github.com/smallstep/nosql" "github.com/smallstep/certificates/acme" - "github.com/smallstep/certificates/utils/debug/q" ) type dbChallenge struct { @@ -32,7 +31,6 @@ func (dbc *dbChallenge) clone() *dbChallenge { func (db *DB) getDBChallenge(ctx context.Context, id string) (*dbChallenge, error) { data, err := db.db.Get(challengeTable, []byte(id)) - q.Q(data) if nosql.IsErrNotFound(err) { return nil, acme.NewError(acme.ErrorMalformedType, "challenge %s not found", id) } else if err != nil { @@ -43,7 +41,6 @@ func (db *DB) getDBChallenge(ctx context.Context, id string) (*dbChallenge, erro if err := json.Unmarshal(data, dbch); err != nil { return nil, errors.Wrap(err, "error unmarshaling dbChallenge") } - q.Q(dbch) return dbch, nil } diff --git a/go.mod b/go.mod index e4f5848f..784827b2 100644 --- a/go.mod +++ b/go.mod @@ -56,8 +56,6 @@ require ( gopkg.in/square/go-jose.v2 v2.6.0 ) -require github.com/ryboe/q v1.0.18 - require ( cloud.google.com/go/compute v1.14.0 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect @@ -124,7 +122,6 @@ require ( github.com/jackc/pgx/v4 v4.17.2 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/klauspost/compress v1.15.11 // indirect - github.com/kr/text v0.2.0 // indirect github.com/manifoldco/promptui v0.9.0 // indirect github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect github.com/miekg/pkcs11 v1.1.1 // indirect @@ -136,7 +133,6 @@ require ( github.com/oklog/run v1.0.0 // indirect github.com/pierrec/lz4 v2.5.2+incompatible // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/rogpeppe/go-internal v1.9.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/ryanuber/go-glob v1.0.0 // indirect github.com/shopspring/decimal v1.2.0 // indirect diff --git a/go.sum b/go.sum index 6760b242..83aab357 100644 --- a/go.sum +++ b/go.sum @@ -599,8 +599,6 @@ github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/ryanuber/go-glob v1.0.0 h1:iQh3xXAumdQ+4Ufa5b25cRpC5TYKlno6hsv6Cb3pkBk= github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc= -github.com/ryboe/q v1.0.18 h1:uTonPt1eZjy7GSpB0XpYpsCvX+Yf9f+M4CUKuH2r+vg= -github.com/ryboe/q v1.0.18/go.mod h1:elqvVf/GBuZHvZ9gvHv4MKM6NZAMz2rFajnTgQZ46wU= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= diff --git a/utils/debug/q/debug.go b/utils/debug/q/debug.go deleted file mode 100644 index e12c73cd..00000000 --- a/utils/debug/q/debug.go +++ /dev/null @@ -1,13 +0,0 @@ -package q - -import ( - ryboeq "github.com/ryboe/q" -) - -func Q(v ...interface{}) { - // TODO(hs): do or do not call ryboeq.Q based on e.g. debug flag, - // runtime (go run vs. build), based on compiled or not. Goal would be - // to not debug in prod builds at all times. Ideally, never leave a leftover - // call to q.Q in the code, so panic if there is? - ryboeq.Q(v...) -}