Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package chart-testing for openSUSE:Factory 
checked in at 2022-09-29 18:12:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/chart-testing (Old)
 and      /work/SRC/openSUSE:Factory/.chart-testing.new.2275 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "chart-testing"

Thu Sep 29 18:12:12 2022 rev:4 rq:1006557 version:3.7.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/chart-testing/chart-testing.changes      
2022-08-09 15:27:49.109533659 +0200
+++ /work/SRC/openSUSE:Factory/.chart-testing.new.2275/chart-testing.changes    
2022-09-29 18:12:22.319139769 +0200
@@ -1,0 +2,18 @@
+Tue Sep 27 15:32:08 UTC 2022 - ka...@b1-systems.de
+
+- Update to version 3.7.1:
+  * Bump sigstore/cosign-installer from 2.6.0 to 2.7.0 (#476)
+  * Bump helm/kind-action from 1.3.0 to 1.4.0 (#477)
+  * update tools (#475)
+  * Add configuration option to disable container logging (#472)
+  * reading helm version using template (#474)
+  * add job to check if docs are up to date (#473)
+  * Upgrade go1.19, helm update and add golangci-lint job (#460)
+  * Bump azure/setup-helm from 1.1 to 3.3 (#462)
+  * Bump anchore/sbom-action from 0.11.0 to 0.12.0 (#461)
+  * Bump actions/setup-go from 3.2.1 to 3.3.0 (#466)
+  * Bump goreleaser/goreleaser-action from 3.0.0 to 3.1.0 (#465)
+  * Bump sigstore/cosign-installer from 2.5.0 to 2.6.0 (#469)
+  * Bump github.com/spf13/viper from 1.12.0 to 1.13.0 (#468)
+
+-------------------------------------------------------------------

Old:
----
  chart-testing-3.7.0.tar.gz

New:
----
  chart-testing-3.7.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ chart-testing.spec ++++++
--- /var/tmp/diff_new_pack.RCjW4o/_old  2022-09-29 18:12:22.879140864 +0200
+++ /var/tmp/diff_new_pack.RCjW4o/_new  2022-09-29 18:12:22.883140871 +0200
@@ -21,7 +21,7 @@
 %define name_of_binary ct
 
 Name:           chart-testing
-Version:        3.7.0
+Version:        3.7.1
 Release:        0
 Summary:        CLI tool for linting and testing Helm charts
 Group:          Development/Languages/Other

++++++ _service ++++++
--- /var/tmp/diff_new_pack.RCjW4o/_old  2022-09-29 18:12:22.911140926 +0200
+++ /var/tmp/diff_new_pack.RCjW4o/_new  2022-09-29 18:12:22.911140926 +0200
@@ -3,7 +3,7 @@
     <param name="url">https://github.com/helm/chart-testing</param>
     <param name="scm">git</param>
     <param name="exclude">.git</param>
-    <param name="revision">v3.7.0</param>
+    <param name="revision">v3.7.1</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="changesgenerate">enable</param>
     <param name="versionrewrite-pattern">v(.*)</param>
@@ -16,7 +16,7 @@
     <param name="compression">gz</param>
   </service>
   <service name="go_modules" mode="disabled">
-    <param name="archive">chart-testing-3.7.0.tar.gz</param>
+    <param name="archive">chart-testing-3.7.1.tar.gz</param>
   </service>
 </services>
 

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.RCjW4o/_old  2022-09-29 18:12:22.931140965 +0200
+++ /var/tmp/diff_new_pack.RCjW4o/_new  2022-09-29 18:12:22.935140973 +0200
@@ -1,6 +1,6 @@
 <servicedata>
 <service name="tar_scm">
                 <param name="url">https://github.com/helm/chart-testing</param>
-              <param 
name="changesrevision">1d3feac8e5ca55ccf11521ff297ccee7f09aa749</param></service></servicedata>
+              <param 
name="changesrevision">f261a2809ace1dee3e597397c644082638786c64</param></service></servicedata>
 (No newline at EOF)
 

++++++ chart-testing-3.7.0.tar.gz -> chart-testing-3.7.1.tar.gz ++++++
++++ 1627 lines of diff (skipped)

++++++ vendor.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pelletier/go-toml/v2/errors.go 
new/vendor/github.com/pelletier/go-toml/v2/errors.go
--- old/vendor/github.com/pelletier/go-toml/v2/errors.go        2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/pelletier/go-toml/v2/errors.go        2022-09-27 
17:32:09.000000000 +0200
@@ -103,6 +103,7 @@
 //
 // The function copies all bytes used in DecodeError, so that document and
 // highlight can be freely deallocated.
+//
 //nolint:funlen
 func wrapDecodeError(document []byte, de *decodeError) *DecodeError {
        offset := danger.SubsliceOffset(document, de.highlight)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/vendor/github.com/pelletier/go-toml/v2/internal/ast/ast.go 
new/vendor/github.com/pelletier/go-toml/v2/internal/ast/ast.go
--- old/vendor/github.com/pelletier/go-toml/v2/internal/ast/ast.go      
2022-07-27 14:54:08.000000000 +0200
+++ new/vendor/github.com/pelletier/go-toml/v2/internal/ast/ast.go      
2022-09-27 17:32:09.000000000 +0200
@@ -11,10 +11,10 @@
 //
 // For example:
 //
-// it := n.Children()
-// for it.Next() {
-//             it.Node()
-// }
+//     it := n.Children()
+//     for it.Next() {
+//                     it.Node()
+//     }
 type Iterator struct {
        started bool
        node    *Node
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pelletier/go-toml/v2/marshaler.go 
new/vendor/github.com/pelletier/go-toml/v2/marshaler.go
--- old/vendor/github.com/pelletier/go-toml/v2/marshaler.go     2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/pelletier/go-toml/v2/marshaler.go     2022-09-27 
17:32:09.000000000 +0200
@@ -54,7 +54,7 @@
 // This behavior can be controlled on an individual struct field basis with the
 // inline tag:
 //
-//   MyField `inline:"true"`
+//     MyField `toml:",inline"`
 func (enc *Encoder) SetTablesInline(inline bool) *Encoder {
        enc.tablesInline = inline
        return enc
@@ -65,7 +65,7 @@
 //
 // This behavior can be controlled on an individual struct field basis with 
the multiline tag:
 //
-//   MyField `multiline:"true"`
+//     MyField `multiline:"true"`
 func (enc *Encoder) SetArraysMultiline(multiline bool) *Encoder {
        enc.arraysMultiline = multiline
        return enc
@@ -89,7 +89,7 @@
 //
 // If v cannot be represented to TOML it returns an error.
 //
-// Encoding rules
+// # Encoding rules
 //
 // A top level slice containing only maps or structs is encoded as [[table
 // array]].
@@ -117,7 +117,20 @@
 // When encoding structs, fields are encoded in order of definition, with their
 // exact name.
 //
-// Struct tags
+// Tables and array tables are separated by empty lines. However, consecutive
+// subtables definitions are not. For example:
+//
+//     [top1]
+//
+//     [top2]
+//     [top2.child1]
+//
+//     [[array]]
+//
+//     [[array]]
+//     [array.child2]
+//
+// # Struct tags
 //
 // The encoding of each public struct field can be customized by the format
 // string in the "toml" key of the struct field's tag. This follows
@@ -333,13 +346,13 @@
        }
 }
 
+func shouldOmitEmpty(options valueOptions, v reflect.Value) bool {
+       return options.omitempty && isEmptyValue(v)
+}
+
 func (enc *Encoder) encodeKv(b []byte, ctx encoderCtx, options valueOptions, v 
reflect.Value) ([]byte, error) {
        var err error
 
-       if (ctx.options.omitempty || options.omitempty) && isEmptyValue(v) {
-               return b, nil
-       }
-
        if !ctx.inline {
                b = enc.encodeComment(ctx.indent, options.comment, b)
        }
@@ -365,6 +378,8 @@
 
 func isEmptyValue(v reflect.Value) bool {
        switch v.Kind() {
+       case reflect.Struct:
+               return isEmptyStruct(v)
        case reflect.Array, reflect.Map, reflect.Slice, reflect.String:
                return v.Len() == 0
        case reflect.Bool:
@@ -381,6 +396,34 @@
        return false
 }
 
+func isEmptyStruct(v reflect.Value) bool {
+       // TODO: merge with walkStruct and cache.
+       typ := v.Type()
+       for i := 0; i < typ.NumField(); i++ {
+               fieldType := typ.Field(i)
+
+               // only consider exported fields
+               if fieldType.PkgPath != "" {
+                       continue
+               }
+
+               tag := fieldType.Tag.Get("toml")
+
+               // special field name to skip field
+               if tag == "-" {
+                       continue
+               }
+
+               f := v.Field(i)
+
+               if !isEmptyValue(f) {
+                       return false
+               }
+       }
+
+       return true
+}
+
 const literalQuote = '\''
 
 func (enc *Encoder) encodeString(b []byte, v string, options valueOptions) 
[]byte {
@@ -410,7 +453,6 @@
        return b
 }
 
-//nolint:cyclop
 func (enc *Encoder) encodeQuotedString(multiline bool, b []byte, v string) 
[]byte {
        stringQuote := `"`
 
@@ -757,7 +799,13 @@
        }
        ctx.skipTableHeader = false
 
+       hasNonEmptyKV := false
        for _, kv := range t.kvs {
+               if shouldOmitEmpty(kv.Options, kv.Value) {
+                       continue
+               }
+               hasNonEmptyKV = true
+
                ctx.setKey(kv.Key)
 
                b, err = enc.encodeKv(b, ctx, kv.Options, kv.Value)
@@ -768,7 +816,20 @@
                b = append(b, '\n')
        }
 
+       first := true
        for _, table := range t.tables {
+               if shouldOmitEmpty(table.Options, table.Value) {
+                       continue
+               }
+               if first {
+                       first = false
+                       if hasNonEmptyKV {
+                               b = append(b, '\n')
+                       }
+               } else {
+                       b = append(b, "\n"...)
+               }
+
                ctx.setKey(table.Key)
 
                ctx.options = table.Options
@@ -777,8 +838,6 @@
                if err != nil {
                        return nil, err
                }
-
-               b = append(b, '\n')
        }
 
        return b, nil
@@ -791,6 +850,10 @@
 
        first := true
        for _, kv := range t.kvs {
+               if shouldOmitEmpty(kv.Options, kv.Value) {
+                       continue
+               }
+
                if first {
                        first = false
                } else {
@@ -806,7 +869,7 @@
        }
 
        if len(t.tables) > 0 {
-               panic("inline table cannot contain nested tables, online 
key-values")
+               panic("inline table cannot contain nested tables, only 
key-values")
        }
 
        b = append(b, "}"...)
@@ -905,6 +968,10 @@
        b = enc.encodeComment(ctx.indent, ctx.options.comment, b)
 
        for i := 0; i < v.Len(); i++ {
+               if i != 0 {
+                       b = append(b, "\n"...)
+               }
+
                b = append(b, scratch...)
 
                var err error
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/vendor/github.com/pelletier/go-toml/v2/unmarshaler.go 
new/vendor/github.com/pelletier/go-toml/v2/unmarshaler.go
--- old/vendor/github.com/pelletier/go-toml/v2/unmarshaler.go   2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/pelletier/go-toml/v2/unmarshaler.go   2022-09-27 
17:32:09.000000000 +0200
@@ -79,22 +79,22 @@
 // strict mode and a field is missing, a `toml.StrictMissingError` is
 // returned. In any other case, this function returns a standard Go error.
 //
-// Type mapping
+// # Type mapping
 //
 // List of supported TOML types and their associated accepted Go types:
 //
-//   String           -> string
-//   Integer          -> uint*, int*, depending on size
-//   Float            -> float*, depending on size
-//   Boolean          -> bool
-//   Offset Date-Time -> time.Time
-//   Local Date-time  -> LocalDateTime, time.Time
-//   Local Date       -> LocalDate, time.Time
-//   Local Time       -> LocalTime, time.Time
-//   Array            -> slice and array, depending on elements types
-//   Table            -> map and struct
-//   Inline Table     -> same as Table
-//   Array of Tables  -> same as Array and Table
+//     String           -> string
+//     Integer          -> uint*, int*, depending on size
+//     Float            -> float*, depending on size
+//     Boolean          -> bool
+//     Offset Date-Time -> time.Time
+//     Local Date-time  -> LocalDateTime, time.Time
+//     Local Date       -> LocalDate, time.Time
+//     Local Time       -> LocalTime, time.Time
+//     Array            -> slice and array, depending on elements types
+//     Table            -> map and struct
+//     Inline Table     -> same as Table
+//     Array of Tables  -> same as Array and Table
 func (d *Decoder) Decode(v interface{}) error {
        b, err := ioutil.ReadAll(d.r)
        if err != nil {
@@ -123,7 +123,7 @@
        stashedExpr bool
 
        // Skip expressions until a table is found. This is set to true when a
-       // table could not be create (missing field in map), so all KV 
expressions
+       // table could not be created (missing field in map), so all KV 
expressions
        // need to be skipped.
        skipUntilTable bool
 
@@ -344,9 +344,9 @@
                elem := v.Index(idx)
                _, err := d.handleArrayTable(key, elem)
                return v, err
+       default:
+               return reflect.Value{}, fmt.Errorf("toml: cannot decode array 
table into a %s", v.Type())
        }
-
-       return d.handleArrayTable(key, v)
 }
 
 // When parsing an array table expression, each part of the key needs to be
@@ -483,7 +483,7 @@
                d.errorContext.Struct = t
                d.errorContext.Field = path
 
-               f := v.FieldByIndex(path)
+               f := fieldByIndex(v, path)
                x, err := nextFn(key, f)
                if err != nil || d.skipUntilTable {
                        return reflect.Value{}, err
@@ -1071,7 +1071,7 @@
                d.errorContext.Struct = t
                d.errorContext.Field = path
 
-               f := v.FieldByIndex(path)
+               f := fieldByIndex(v, path)
                x, err := d.handleKeyValueInner(key, value, f)
                if err != nil {
                        return reflect.Value{}, err
@@ -1135,6 +1135,21 @@
        return elem
 }
 
+// Same as reflect.Value.FieldByIndex, but creates pointers if needed.
+func fieldByIndex(v reflect.Value, path []int) reflect.Value {
+       for i, x := range path {
+               v = v.Field(x)
+
+               if i < len(path)-1 && v.Kind() == reflect.Ptr {
+                       if v.IsNil() {
+                               v.Set(reflect.New(v.Type().Elem()))
+                       }
+                       v = v.Elem()
+               }
+       }
+       return v
+}
+
 type fieldPathsMap = map[string][]int
 
 var globalFieldPathsCache atomic.Value // map[danger.TypeID]fieldPathsMap
@@ -1192,7 +1207,14 @@
                }
 
                if f.Anonymous && name == "" {
-                       forEachField(f.Type, fieldPath, do)
+                       t2 := f.Type
+                       if t2.Kind() == reflect.Ptr {
+                               t2 = t2.Elem()
+                       }
+
+                       if t2.Kind() == reflect.Struct {
+                               forEachField(t2, fieldPath, do)
+                       }
                        continue
                }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/.gitignore 
new/vendor/github.com/pkg/errors/.gitignore
--- old/vendor/github.com/pkg/errors/.gitignore 2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/.gitignore 1970-01-01 01:00:00.000000000 
+0100
@@ -1,24 +0,0 @@
-# Compiled Object files, Static and Dynamic libs (Shared Objects)
-*.o
-*.a
-*.so
-
-# Folders
-_obj
-_test
-
-# Architecture specific extensions/prefixes
-*.[568vq]
-[568vq].out
-
-*.cgo1.go
-*.cgo2.c
-_cgo_defun.c
-_cgo_gotypes.go
-_cgo_export.*
-
-_testmain.go
-
-*.exe
-*.test
-*.prof
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/.travis.yml 
new/vendor/github.com/pkg/errors/.travis.yml
--- old/vendor/github.com/pkg/errors/.travis.yml        2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/pkg/errors/.travis.yml        1970-01-01 
01:00:00.000000000 +0100
@@ -1,10 +0,0 @@
-language: go
-go_import_path: github.com/pkg/errors
-go:
-  - 1.11.x
-  - 1.12.x
-  - 1.13.x
-  - tip
-
-script:
-  - make check
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/LICENSE 
new/vendor/github.com/pkg/errors/LICENSE
--- old/vendor/github.com/pkg/errors/LICENSE    2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/LICENSE    1970-01-01 01:00:00.000000000 
+0100
@@ -1,23 +0,0 @@
-Copyright (c) 2015, Dave Cheney <d...@cheney.net>
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are met:
-
-* Redistributions of source code must retain the above copyright notice, this
-  list of conditions and the following disclaimer.
-
-* Redistributions in binary form must reproduce the above copyright notice,
-  this list of conditions and the following disclaimer in the documentation
-  and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
-SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
-CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/Makefile 
new/vendor/github.com/pkg/errors/Makefile
--- old/vendor/github.com/pkg/errors/Makefile   2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/Makefile   1970-01-01 01:00:00.000000000 
+0100
@@ -1,44 +0,0 @@
-PKGS := github.com/pkg/errors
-SRCDIRS := $(shell go list -f '{{.Dir}}' $(PKGS))
-GO := go
-
-check: test vet gofmt misspell unconvert staticcheck ineffassign unparam
-
-test: 
-       $(GO) test $(PKGS)
-
-vet: | test
-       $(GO) vet $(PKGS)
-
-staticcheck:
-       $(GO) get honnef.co/go/tools/cmd/staticcheck
-       staticcheck -checks all $(PKGS)
-
-misspell:
-       $(GO) get github.com/client9/misspell/cmd/misspell
-       misspell \
-               -locale GB \
-               -error \
-               *.md *.go
-
-unconvert:
-       $(GO) get github.com/mdempsky/unconvert
-       unconvert -v $(PKGS)
-
-ineffassign:
-       $(GO) get github.com/gordonklaus/ineffassign
-       find $(SRCDIRS) -name '*.go' | xargs ineffassign
-
-pedantic: check errcheck
-
-unparam:
-       $(GO) get mvdan.cc/unparam
-       unparam ./...
-
-errcheck:
-       $(GO) get github.com/kisielk/errcheck
-       errcheck $(PKGS)
-
-gofmt:  
-       @echo Checking code is gofmted
-       @test -z "$(shell gofmt -s -l -d -e $(SRCDIRS) | tee /dev/stderr)"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/README.md 
new/vendor/github.com/pkg/errors/README.md
--- old/vendor/github.com/pkg/errors/README.md  2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/README.md  1970-01-01 01:00:00.000000000 
+0100
@@ -1,59 +0,0 @@
-# errors 
[![Travis-CI](https://travis-ci.org/pkg/errors.svg)](https://travis-ci.org/pkg/errors)
 
[![AppVeyor](https://ci.appveyor.com/api/projects/status/b98mptawhudj53ep/branch/master?svg=true)](https://ci.appveyor.com/project/davecheney/errors/branch/master)
 
[![GoDoc](https://godoc.org/github.com/pkg/errors?status.svg)](http://godoc.org/github.com/pkg/errors)
 [![Report 
card](https://goreportcard.com/badge/github.com/pkg/errors)](https://goreportcard.com/report/github.com/pkg/errors)
 
[![Sourcegraph](https://sourcegraph.com/github.com/pkg/errors/-/badge.svg)](https://sourcegraph.com/github.com/pkg/errors?badge)
-
-Package errors provides simple error handling primitives.
-
-`go get github.com/pkg/errors`
-
-The traditional error handling idiom in Go is roughly akin to
-```go
-if err != nil {
-        return err
-}
-```
-which applied recursively up the call stack results in error reports without 
context or debugging information. The errors package allows programmers to add 
context to the failure path in their code in a way that does not destroy the 
original value of the error.
-
-## Adding context to an error
-
-The errors.Wrap function returns a new error that adds context to the original 
error. For example
-```go
-_, err := ioutil.ReadAll(r)
-if err != nil {
-        return errors.Wrap(err, "read failed")
-}
-```
-## Retrieving the cause of an error
-
-Using `errors.Wrap` constructs a stack of errors, adding context to the 
preceding error. Depending on the nature of the error it may be necessary to 
reverse the operation of errors.Wrap to retrieve the original error for 
inspection. Any error value which implements this interface can be inspected by 
`errors.Cause`.
-```go
-type causer interface {
-        Cause() error
-}
-```
-`errors.Cause` will recursively retrieve the topmost error which does not 
implement `causer`, which is assumed to be the original cause. For example:
-```go
-switch err := errors.Cause(err).(type) {
-case *MyError:
-        // handle specifically
-default:
-        // unknown error
-}
-```
-
-[Read the package documentation for more 
information](https://godoc.org/github.com/pkg/errors).
-
-## Roadmap
-
-With the upcoming [Go2 error 
proposals](https://go.googlesource.com/proposal/+/master/design/go2draft.md) 
this package is moving into maintenance mode. The roadmap for a 1.0 release is 
as follows:
-
-- 0.9. Remove pre Go 1.9 and Go 1.10 support, address outstanding pull 
requests (if possible)
-- 1.0. Final release.
-
-## Contributing
-
-Because of the Go2 errors changes, this package is not accepting proposals for 
new functionality. With that said, we welcome pull requests, bug fixes and 
issue reports. 
-
-Before sending a PR, please discuss your change by raising an issue.
-
-## License
-
-BSD-2-Clause
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/appveyor.yml 
new/vendor/github.com/pkg/errors/appveyor.yml
--- old/vendor/github.com/pkg/errors/appveyor.yml       2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/pkg/errors/appveyor.yml       1970-01-01 
01:00:00.000000000 +0100
@@ -1,32 +0,0 @@
-version: build-{build}.{branch}
-
-clone_folder: C:\gopath\src\github.com\pkg\errors
-shallow_clone: true # for startup speed
-
-environment:
-  GOPATH: C:\gopath
-
-platform:
-  - x64
-
-# http://www.appveyor.com/docs/installed-software
-install:
-  # some helpful output for debugging builds
-  - go version
-  - go env
-  # pre-installed MinGW at C:\MinGW is 32bit only
-  # but MSYS2 at C:\msys64 has mingw64
-  - set PATH=C:\msys64\mingw64\bin;%PATH%
-  - gcc --version
-  - g++ --version
-
-build_script:
-  - go install -v ./...
-
-test_script:
-  - set PATH=C:\gopath\bin;%PATH%
-  - go test -v ./...
-
-#artifacts:
-#  - path: '%GOPATH%\bin\*.exe'
-deploy: off
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/errors.go 
new/vendor/github.com/pkg/errors/errors.go
--- old/vendor/github.com/pkg/errors/errors.go  2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/errors.go  1970-01-01 01:00:00.000000000 
+0100
@@ -1,288 +0,0 @@
-// Package errors provides simple error handling primitives.
-//
-// The traditional error handling idiom in Go is roughly akin to
-//
-//     if err != nil {
-//             return err
-//     }
-//
-// which when applied recursively up the call stack results in error reports
-// without context or debugging information. The errors package allows
-// programmers to add context to the failure path in their code in a way
-// that does not destroy the original value of the error.
-//
-// Adding context to an error
-//
-// The errors.Wrap function returns a new error that adds context to the
-// original error by recording a stack trace at the point Wrap is called,
-// together with the supplied message. For example
-//
-//     _, err := ioutil.ReadAll(r)
-//     if err != nil {
-//             return errors.Wrap(err, "read failed")
-//     }
-//
-// If additional control is required, the errors.WithStack and
-// errors.WithMessage functions destructure errors.Wrap into its component
-// operations: annotating an error with a stack trace and with a message,
-// respectively.
-//
-// Retrieving the cause of an error
-//
-// Using errors.Wrap constructs a stack of errors, adding context to the
-// preceding error. Depending on the nature of the error it may be necessary
-// to reverse the operation of errors.Wrap to retrieve the original error
-// for inspection. Any error value which implements this interface
-//
-//     type causer interface {
-//             Cause() error
-//     }
-//
-// can be inspected by errors.Cause. errors.Cause will recursively retrieve
-// the topmost error that does not implement causer, which is assumed to be
-// the original cause. For example:
-//
-//     switch err := errors.Cause(err).(type) {
-//     case *MyError:
-//             // handle specifically
-//     default:
-//             // unknown error
-//     }
-//
-// Although the causer interface is not exported by this package, it is
-// considered a part of its stable public interface.
-//
-// Formatted printing of errors
-//
-// All error values returned from this package implement fmt.Formatter and can
-// be formatted by the fmt package. The following verbs are supported:
-//
-//     %s    print the error. If the error has a Cause it will be
-//           printed recursively.
-//     %v    see %s
-//     %+v   extended format. Each Frame of the error's StackTrace will
-//           be printed in detail.
-//
-// Retrieving the stack trace of an error or wrapper
-//
-// New, Errorf, Wrap, and Wrapf record a stack trace at the point they are
-// invoked. This information can be retrieved with the following interface:
-//
-//     type stackTracer interface {
-//             StackTrace() errors.StackTrace
-//     }
-//
-// The returned errors.StackTrace type is defined as
-//
-//     type StackTrace []Frame
-//
-// The Frame type represents a call site in the stack trace. Frame supports
-// the fmt.Formatter interface that can be used for printing information about
-// the stack trace of this error. For example:
-//
-//     if err, ok := err.(stackTracer); ok {
-//             for _, f := range err.StackTrace() {
-//                     fmt.Printf("%+s:%d\n", f, f)
-//             }
-//     }
-//
-// Although the stackTracer interface is not exported by this package, it is
-// considered a part of its stable public interface.
-//
-// See the documentation for Frame.Format for more details.
-package errors
-
-import (
-       "fmt"
-       "io"
-)
-
-// New returns an error with the supplied message.
-// New also records the stack trace at the point it was called.
-func New(message string) error {
-       return &fundamental{
-               msg:   message,
-               stack: callers(),
-       }
-}
-
-// Errorf formats according to a format specifier and returns the string
-// as a value that satisfies error.
-// Errorf also records the stack trace at the point it was called.
-func Errorf(format string, args ...interface{}) error {
-       return &fundamental{
-               msg:   fmt.Sprintf(format, args...),
-               stack: callers(),
-       }
-}
-
-// fundamental is an error that has a message and a stack, but no caller.
-type fundamental struct {
-       msg string
-       *stack
-}
-
-func (f *fundamental) Error() string { return f.msg }
-
-func (f *fundamental) Format(s fmt.State, verb rune) {
-       switch verb {
-       case 'v':
-               if s.Flag('+') {
-                       io.WriteString(s, f.msg)
-                       f.stack.Format(s, verb)
-                       return
-               }
-               fallthrough
-       case 's':
-               io.WriteString(s, f.msg)
-       case 'q':
-               fmt.Fprintf(s, "%q", f.msg)
-       }
-}
-
-// WithStack annotates err with a stack trace at the point WithStack was 
called.
-// If err is nil, WithStack returns nil.
-func WithStack(err error) error {
-       if err == nil {
-               return nil
-       }
-       return &withStack{
-               err,
-               callers(),
-       }
-}
-
-type withStack struct {
-       error
-       *stack
-}
-
-func (w *withStack) Cause() error { return w.error }
-
-// Unwrap provides compatibility for Go 1.13 error chains.
-func (w *withStack) Unwrap() error { return w.error }
-
-func (w *withStack) Format(s fmt.State, verb rune) {
-       switch verb {
-       case 'v':
-               if s.Flag('+') {
-                       fmt.Fprintf(s, "%+v", w.Cause())
-                       w.stack.Format(s, verb)
-                       return
-               }
-               fallthrough
-       case 's':
-               io.WriteString(s, w.Error())
-       case 'q':
-               fmt.Fprintf(s, "%q", w.Error())
-       }
-}
-
-// Wrap returns an error annotating err with a stack trace
-// at the point Wrap is called, and the supplied message.
-// If err is nil, Wrap returns nil.
-func Wrap(err error, message string) error {
-       if err == nil {
-               return nil
-       }
-       err = &withMessage{
-               cause: err,
-               msg:   message,
-       }
-       return &withStack{
-               err,
-               callers(),
-       }
-}
-
-// Wrapf returns an error annotating err with a stack trace
-// at the point Wrapf is called, and the format specifier.
-// If err is nil, Wrapf returns nil.
-func Wrapf(err error, format string, args ...interface{}) error {
-       if err == nil {
-               return nil
-       }
-       err = &withMessage{
-               cause: err,
-               msg:   fmt.Sprintf(format, args...),
-       }
-       return &withStack{
-               err,
-               callers(),
-       }
-}
-
-// WithMessage annotates err with a new message.
-// If err is nil, WithMessage returns nil.
-func WithMessage(err error, message string) error {
-       if err == nil {
-               return nil
-       }
-       return &withMessage{
-               cause: err,
-               msg:   message,
-       }
-}
-
-// WithMessagef annotates err with the format specifier.
-// If err is nil, WithMessagef returns nil.
-func WithMessagef(err error, format string, args ...interface{}) error {
-       if err == nil {
-               return nil
-       }
-       return &withMessage{
-               cause: err,
-               msg:   fmt.Sprintf(format, args...),
-       }
-}
-
-type withMessage struct {
-       cause error
-       msg   string
-}
-
-func (w *withMessage) Error() string { return w.msg + ": " + w.cause.Error() }
-func (w *withMessage) Cause() error  { return w.cause }
-
-// Unwrap provides compatibility for Go 1.13 error chains.
-func (w *withMessage) Unwrap() error { return w.cause }
-
-func (w *withMessage) Format(s fmt.State, verb rune) {
-       switch verb {
-       case 'v':
-               if s.Flag('+') {
-                       fmt.Fprintf(s, "%+v\n", w.Cause())
-                       io.WriteString(s, w.msg)
-                       return
-               }
-               fallthrough
-       case 's', 'q':
-               io.WriteString(s, w.Error())
-       }
-}
-
-// Cause returns the underlying cause of the error, if possible.
-// An error value has a cause if it implements the following
-// interface:
-//
-//     type causer interface {
-//            Cause() error
-//     }
-//
-// If the error does not implement Cause, the original error will
-// be returned. If the error is nil, nil will be returned without further
-// investigation.
-func Cause(err error) error {
-       type causer interface {
-               Cause() error
-       }
-
-       for err != nil {
-               cause, ok := err.(causer)
-               if !ok {
-                       break
-               }
-               err = cause.Cause()
-       }
-       return err
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/go113.go 
new/vendor/github.com/pkg/errors/go113.go
--- old/vendor/github.com/pkg/errors/go113.go   2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/go113.go   1970-01-01 01:00:00.000000000 
+0100
@@ -1,38 +0,0 @@
-// +build go1.13
-
-package errors
-
-import (
-       stderrors "errors"
-)
-
-// Is reports whether any error in err's chain matches target.
-//
-// The chain consists of err itself followed by the sequence of errors 
obtained by
-// repeatedly calling Unwrap.
-//
-// An error is considered to match a target if it is equal to that target or if
-// it implements a method Is(error) bool such that Is(target) returns true.
-func Is(err, target error) bool { return stderrors.Is(err, target) }
-
-// As finds the first error in err's chain that matches target, and if so, sets
-// target to that error value and returns true.
-//
-// The chain consists of err itself followed by the sequence of errors 
obtained by
-// repeatedly calling Unwrap.
-//
-// An error matches target if the error's concrete value is assignable to the 
value
-// pointed to by target, or if the error has a method As(interface{}) bool 
such that
-// As(target) returns true. In the latter case, the As method is responsible 
for
-// setting target.
-//
-// As will panic if target is not a non-nil pointer to either a type that 
implements
-// error, or to any interface type. As returns false if err is nil.
-func As(err error, target interface{}) bool { return stderrors.As(err, target) 
}
-
-// Unwrap returns the result of calling the Unwrap method on err, if err's
-// type contains an Unwrap method returning error.
-// Otherwise, Unwrap returns nil.
-func Unwrap(err error) error {
-       return stderrors.Unwrap(err)
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/pkg/errors/stack.go 
new/vendor/github.com/pkg/errors/stack.go
--- old/vendor/github.com/pkg/errors/stack.go   2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/pkg/errors/stack.go   1970-01-01 01:00:00.000000000 
+0100
@@ -1,177 +0,0 @@
-package errors
-
-import (
-       "fmt"
-       "io"
-       "path"
-       "runtime"
-       "strconv"
-       "strings"
-)
-
-// Frame represents a program counter inside a stack frame.
-// For historical reasons if Frame is interpreted as a uintptr
-// its value represents the program counter + 1.
-type Frame uintptr
-
-// pc returns the program counter for this frame;
-// multiple frames may have the same PC value.
-func (f Frame) pc() uintptr { return uintptr(f) - 1 }
-
-// file returns the full path to the file that contains the
-// function for this Frame's pc.
-func (f Frame) file() string {
-       fn := runtime.FuncForPC(f.pc())
-       if fn == nil {
-               return "unknown"
-       }
-       file, _ := fn.FileLine(f.pc())
-       return file
-}
-
-// line returns the line number of source code of the
-// function for this Frame's pc.
-func (f Frame) line() int {
-       fn := runtime.FuncForPC(f.pc())
-       if fn == nil {
-               return 0
-       }
-       _, line := fn.FileLine(f.pc())
-       return line
-}
-
-// name returns the name of this function, if known.
-func (f Frame) name() string {
-       fn := runtime.FuncForPC(f.pc())
-       if fn == nil {
-               return "unknown"
-       }
-       return fn.Name()
-}
-
-// Format formats the frame according to the fmt.Formatter interface.
-//
-//    %s    source file
-//    %d    source line
-//    %n    function name
-//    %v    equivalent to %s:%d
-//
-// Format accepts flags that alter the printing of some verbs, as follows:
-//
-//    %+s   function name and path of source file relative to the compile time
-//          GOPATH separated by \n\t (<funcname>\n\t<path>)
-//    %+v   equivalent to %+s:%d
-func (f Frame) Format(s fmt.State, verb rune) {
-       switch verb {
-       case 's':
-               switch {
-               case s.Flag('+'):
-                       io.WriteString(s, f.name())
-                       io.WriteString(s, "\n\t")
-                       io.WriteString(s, f.file())
-               default:
-                       io.WriteString(s, path.Base(f.file()))
-               }
-       case 'd':
-               io.WriteString(s, strconv.Itoa(f.line()))
-       case 'n':
-               io.WriteString(s, funcname(f.name()))
-       case 'v':
-               f.Format(s, 's')
-               io.WriteString(s, ":")
-               f.Format(s, 'd')
-       }
-}
-
-// MarshalText formats a stacktrace Frame as a text string. The output is the
-// same as that of fmt.Sprintf("%+v", f), but without newlines or tabs.
-func (f Frame) MarshalText() ([]byte, error) {
-       name := f.name()
-       if name == "unknown" {
-               return []byte(name), nil
-       }
-       return []byte(fmt.Sprintf("%s %s:%d", name, f.file(), f.line())), nil
-}
-
-// StackTrace is stack of Frames from innermost (newest) to outermost (oldest).
-type StackTrace []Frame
-
-// Format formats the stack of Frames according to the fmt.Formatter interface.
-//
-//    %s       lists source files for each Frame in the stack
-//    %v       lists the source file and line number for each Frame in the 
stack
-//
-// Format accepts flags that alter the printing of some verbs, as follows:
-//
-//    %+v   Prints filename, function, and line number for each Frame in the 
stack.
-func (st StackTrace) Format(s fmt.State, verb rune) {
-       switch verb {
-       case 'v':
-               switch {
-               case s.Flag('+'):
-                       for _, f := range st {
-                               io.WriteString(s, "\n")
-                               f.Format(s, verb)
-                       }
-               case s.Flag('#'):
-                       fmt.Fprintf(s, "%#v", []Frame(st))
-               default:
-                       st.formatSlice(s, verb)
-               }
-       case 's':
-               st.formatSlice(s, verb)
-       }
-}
-
-// formatSlice will format this StackTrace into the given buffer as a slice of
-// Frame, only valid when called with '%s' or '%v'.
-func (st StackTrace) formatSlice(s fmt.State, verb rune) {
-       io.WriteString(s, "[")
-       for i, f := range st {
-               if i > 0 {
-                       io.WriteString(s, " ")
-               }
-               f.Format(s, verb)
-       }
-       io.WriteString(s, "]")
-}
-
-// stack represents a stack of program counters.
-type stack []uintptr
-
-func (s *stack) Format(st fmt.State, verb rune) {
-       switch verb {
-       case 'v':
-               switch {
-               case st.Flag('+'):
-                       for _, pc := range *s {
-                               f := Frame(pc)
-                               fmt.Fprintf(st, "\n%+v", f)
-                       }
-               }
-       }
-}
-
-func (s *stack) StackTrace() StackTrace {
-       f := make([]Frame, len(*s))
-       for i := 0; i < len(f); i++ {
-               f[i] = Frame((*s)[i])
-       }
-       return f
-}
-
-func callers() *stack {
-       const depth = 32
-       var pcs [depth]uintptr
-       n := runtime.Callers(3, pcs[:])
-       var st stack = pcs[0:n]
-       return &st
-}
-
-// funcname removes the path prefix component of a function's name reported by 
func.Name().
-func funcname(name string) string {
-       i := strings.LastIndex(name, "/")
-       name = name[i+1:]
-       i = strings.Index(name, ".")
-       return name[i+1:]
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/spf13/viper/Makefile 
new/vendor/github.com/spf13/viper/Makefile
--- old/vendor/github.com/spf13/viper/Makefile  2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/spf13/viper/Makefile  2022-09-27 17:32:09.000000000 
+0200
@@ -16,7 +16,7 @@
 
 # Dependency versions
 GOTESTSUM_VERSION = 1.8.0
-GOLANGCI_VERSION = 1.45.2
+GOLANGCI_VERSION = 1.49.0
 
 # Add the ability to override some variables
 # Use with care
@@ -48,7 +48,7 @@
        @ln -sf golangci-lint-${GOLANGCI_VERSION} bin/golangci-lint
 bin/golangci-lint-${GOLANGCI_VERSION}:
        @mkdir -p bin
-       curl -sfL 
https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s 
-- -b ./bin/ v${GOLANGCI_VERSION}
+       curl -sfL 
https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | 
bash -s -- -b ./bin/ v${GOLANGCI_VERSION}
        @mv bin/golangci-lint "$@"
 
 .PHONY: lint
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/spf13/viper/README.md 
new/vendor/github.com/spf13/viper/README.md
--- old/vendor/github.com/spf13/viper/README.md 2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/spf13/viper/README.md 2022-09-27 17:32:09.000000000 
+0200
@@ -119,7 +119,7 @@
 viper.AddConfigPath(".")               // optionally look for config in the 
working directory
 err := viper.ReadInConfig() // Find and read the config file
 if err != nil { // Handle errors reading the config file
-       panic(fmt.Errorf("Fatal error config file: %w \n", err))
+       panic(fmt.Errorf("fatal error config file: %w", err))
 }
 ```
 
@@ -447,6 +447,13 @@
 err := viper.ReadRemoteConfig()
 ```
 
+#### etcd3
+```go
+viper.AddRemoteProvider("etcd3", "http://127.0.0.1:4001","/config/hugo.json";)
+viper.SetConfigType("json") // because there is no file extension in a stream 
of bytes, supported extensions are "json", "toml", "yaml", "yml", "properties", 
"props", "prop", "env", "dotenv"
+err := viper.ReadRemoteConfig()
+```
+
 #### Consul
 You need to set a key to Consul key/value storage with JSON value containing 
your desired config.
 For example, create a Consul key/value store key `MY_CONSUL_KEY` with value:
@@ -594,7 +601,7 @@
 
 Viper can access array indices by using numbers in the path. For example:
 
-```json
+```jsonc
 {
     "host": {
         "address": "localhost",
@@ -622,7 +629,7 @@
 Lastly, if there exists a key that matches the delimited key path, its value
 will be returned instead. E.g.
 
-```json
+```jsonc
 {
     "datastore.metric.host": "0.0.0.0",
     "host": {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/spf13/viper/logger.go 
new/vendor/github.com/spf13/viper/logger.go
--- old/vendor/github.com/spf13/viper/logger.go 2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/spf13/viper/logger.go 2022-09-27 17:32:09.000000000 
+0200
@@ -7,8 +7,8 @@
 )
 
 // Logger is a unified interface for various logging use cases and practices, 
including:
-//             - leveled logging
-//             - structured logging
+//   - leveled logging
+//   - structured logging
 type Logger interface {
        // Trace logs a Trace event.
        //
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/spf13/viper/util.go 
new/vendor/github.com/spf13/viper/util.go
--- old/vendor/github.com/spf13/viper/util.go   2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/spf13/viper/util.go   2022-09-27 17:32:09.000000000 
+0200
@@ -64,18 +64,25 @@
        return nm
 }
 
+func insensitiviseVal(val interface{}) interface{} {
+       switch val.(type) {
+       case map[interface{}]interface{}:
+               // nested map: cast and recursively insensitivise
+               val = cast.ToStringMap(val)
+               insensitiviseMap(val.(map[string]interface{}))
+       case map[string]interface{}:
+               // nested map: recursively insensitivise
+               insensitiviseMap(val.(map[string]interface{}))
+       case []interface{}:
+               // nested array: recursively insensitivise
+               insensitiveArray(val.([]interface{}))
+       }
+       return val
+}
+
 func insensitiviseMap(m map[string]interface{}) {
        for key, val := range m {
-               switch val.(type) {
-               case map[interface{}]interface{}:
-                       // nested map: cast and recursively insensitivise
-                       val = cast.ToStringMap(val)
-                       insensitiviseMap(val.(map[string]interface{}))
-               case map[string]interface{}:
-                       // nested map: recursively insensitivise
-                       insensitiviseMap(val.(map[string]interface{}))
-               }
-
+               val = insensitiviseVal(val)
                lower := strings.ToLower(key)
                if key != lower {
                        // remove old key (not lower-cased)
@@ -86,6 +93,12 @@
        }
 }
 
+func insensitiveArray(a []interface{}) {
+       for i, val := range a {
+               a[i] = insensitiviseVal(val)
+       }
+}
+
 func absPathify(logger Logger, inPath string) string {
        logger.Info("trying to resolve absolute path", "path", inPath)
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/spf13/viper/viper.go 
new/vendor/github.com/spf13/viper/viper.go
--- old/vendor/github.com/spf13/viper/viper.go  2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/github.com/spf13/viper/viper.go  2022-09-27 17:32:09.000000000 
+0200
@@ -132,10 +132,10 @@
 // DecodeHook returns a DecoderConfigOption which overrides the default
 // DecoderConfig.DecodeHook value, the default is:
 //
-//  mapstructure.ComposeDecodeHookFunc(
-//             mapstructure.StringToTimeDurationHookFunc(),
-//             mapstructure.StringToSliceHookFunc(","),
-//     )
+//      mapstructure.ComposeDecodeHookFunc(
+//                     mapstructure.StringToTimeDurationHookFunc(),
+//                     mapstructure.StringToSliceHookFunc(","),
+//             )
 func DecodeHook(hook mapstructure.DecodeHookFunc) DecoderConfigOption {
        return func(c *mapstructure.DecoderConfig) {
                c.DecodeHook = hook
@@ -156,18 +156,18 @@
 //
 // For example, if values from the following sources were loaded:
 //
-//  Defaults : {
-//     "secret": "",
-//     "user": "default",
-//     "endpoint": "https://localhost";
-//  }
-//  Config : {
-//     "user": "root"
-//     "secret": "defaultsecret"
-//  }
-//  Env : {
-//     "secret": "somesecretkey"
-//  }
+//     Defaults : {
+//             "secret": "",
+//             "user": "default",
+//             "endpoint": "https://localhost";
+//     }
+//     Config : {
+//             "user": "root"
+//             "secret": "defaultsecret"
+//     }
+//     Env : {
+//             "secret": "somesecretkey"
+//     }
 //
 // The resulting config will have the following values:
 //
@@ -300,7 +300,7 @@
 func Reset() {
        v = New()
        SupportedExts = []string{"json", "toml", "yaml", "yml", "properties", 
"props", "prop", "hcl", "tfvars", "dotenv", "env", "ini"}
-       SupportedRemoteProviders = []string{"etcd", "consul", "firestore"}
+       SupportedRemoteProviders = []string{"etcd", "etcd3", "consul", 
"firestore"}
 }
 
 // TODO: make this lazy initialization instead
@@ -419,7 +419,7 @@
 var SupportedExts = []string{"json", "toml", "yaml", "yml", "properties", 
"props", "prop", "hcl", "tfvars", "dotenv", "env", "ini"}
 
 // SupportedRemoteProviders are universally supported remote providers.
-var SupportedRemoteProviders = []string{"etcd", "consul", "firestore"}
+var SupportedRemoteProviders = []string{"etcd", "etcd3", "consul", "firestore"}
 
 func OnConfigChange(run func(in fsnotify.Event)) { v.OnConfigChange(run) }
 func (v *Viper) OnConfigChange(run func(in fsnotify.Event)) {
@@ -573,7 +573,7 @@
 
 // AddRemoteProvider adds a remote configuration source.
 // Remote Providers are searched in the order they are added.
-// provider is a string value: "etcd", "consul" or "firestore" are currently 
supported.
+// provider is a string value: "etcd", "etcd3", "consul" or "firestore" are 
currently supported.
 // endpoint is the url.  etcd requires http://ip:port  consul requires ip:port
 // path is the path in the k/v store to retrieve configuration
 // To retrieve a config file called myapp.json from /configs/myapp.json
@@ -604,7 +604,7 @@
 
 // AddSecureRemoteProvider adds a remote configuration source.
 // Secure Remote Providers are searched in the order they are added.
-// provider is a string value: "etcd", "consul" or "firestore" are currently 
supported.
+// provider is a string value: "etcd", "etcd3", "consul" or "firestore" are 
currently supported.
 // endpoint is the url.  etcd requires http://ip:port  consul requires ip:port
 // secretkeyring is the filepath to your openpgp secret keyring.  e.g. 
/etc/secrets/myring.gpg
 // path is the path in the k/v store to retrieve configuration
@@ -785,7 +785,8 @@
 // isPathShadowedInDeepMap makes sure the given path is not shadowed somewhere
 // on its path in the map.
 // e.g., if "foo.bar" has a value in the given map, it ???shadows???
-//       "foo.bar.baz" in a lower-priority map
+//
+//     "foo.bar.baz" in a lower-priority map
 func (v *Viper) isPathShadowedInDeepMap(path []string, m 
map[string]interface{}) string {
        var parentVal interface{}
        for i := 1; i < len(path); i++ {
@@ -810,7 +811,8 @@
 // isPathShadowedInFlatMap makes sure the given path is not shadowed somewhere
 // in a sub-path of the map.
 // e.g., if "foo.bar" has a value in the given map, it ???shadows???
-//       "foo.bar.baz" in a lower-priority map
+//
+//     "foo.bar.baz" in a lower-priority map
 func (v *Viper) isPathShadowedInFlatMap(path []string, mi interface{}) string {
        // unify input map
        var m map[string]interface{}
@@ -835,7 +837,8 @@
 // isPathShadowedInAutoEnv makes sure the given path is not shadowed somewhere
 // in the environment, when automatic env is on.
 // e.g., if "foo.bar" has a value in the environment, it ???shadows???
-//       "foo.bar.baz" in a lower-priority map
+//
+//     "foo.bar.baz" in a lower-priority map
 func (v *Viper) isPathShadowedInAutoEnv(path []string) string {
        var parentKey string
        for i := 1; i < len(path); i++ {
@@ -856,11 +859,11 @@
 // would return a string slice for the key if the key's type is inferred by
 // the default value and the Get function would return:
 //
-//   []string {"a", "b", "c"}
+//     []string {"a", "b", "c"}
 //
 // Otherwise the Get function would return:
 //
-//   "a b c"
+//     "a b c"
 func SetTypeByDefaultValue(enable bool) { v.SetTypeByDefaultValue(enable) }
 
 func (v *Viper) SetTypeByDefaultValue(enable bool) {
@@ -988,6 +991,13 @@
        return cast.ToUint(v.Get(key))
 }
 
+// GetUint16 returns the value associated with the key as an unsigned integer.
+func GetUint16(key string) uint16 { return v.GetUint16(key) }
+
+func (v *Viper) GetUint16(key string) uint16 {
+       return cast.ToUint16(v.Get(key))
+}
+
 // GetUint32 returns the value associated with the key as an unsigned integer.
 func GetUint32(key string) uint32 { return v.GetUint32(key) }
 
@@ -1137,9 +1147,8 @@
 // BindPFlag binds a specific key to a pflag (as used by cobra).
 // Example (where serverCmd is a Cobra instance):
 //
-//      serverCmd.Flags().Int("port", 1138, "Port to run Application server 
on")
-//      Viper.BindPFlag("port", serverCmd.Flags().Lookup("port"))
-//
+//     serverCmd.Flags().Int("port", 1138, "Port to run Application server on")
+//     Viper.BindPFlag("port", serverCmd.Flags().Lookup("port"))
 func BindPFlag(key string, flag *pflag.Flag) error { return v.BindPFlag(key, 
flag) }
 
 func (v *Viper) BindPFlag(key string, flag *pflag.Flag) error {
@@ -1870,6 +1879,10 @@
                return RemoteConfigError("Enable the remote features by doing a 
blank import of the viper/remote package: '_ github.com/spf13/viper/remote'")
        }
 
+       if len(v.remoteProviders) == 0 {
+               return RemoteConfigError("No Remote Providers")
+       }
+
        for _, rp := range v.remoteProviders {
                val, err := v.getRemoteConfig(rp)
                if err != nil {
@@ -1896,6 +1909,10 @@
 
 // Retrieve the first found remote configuration.
 func (v *Viper) watchKeyValueConfigOnChannel() error {
+       if len(v.remoteProviders) == 0 {
+               return RemoteConfigError("No Remote Providers")
+       }
+
        for _, rp := range v.remoteProviders {
                respc, _ := RemoteConfig.WatchChannel(rp)
                // Todo: Add quit channel
@@ -1913,9 +1930,15 @@
 
 // Retrieve the first found remote configuration.
 func (v *Viper) watchKeyValueConfig() error {
+       if len(v.remoteProviders) == 0 {
+               return RemoteConfigError("No Remote Providers")
+       }
+
        for _, rp := range v.remoteProviders {
                val, err := v.watchRemoteConfig(rp)
                if err != nil {
+                       v.logger.Error(fmt.Errorf("watch remote config: %w", 
err).Error())
+
                        continue
                }
                v.kvstore = val
@@ -1958,9 +1981,10 @@
 
 // flattenAndMergeMap recursively flattens the given map into a map[string]bool
 // of key paths (used as a set, easier to manipulate than a []string):
-// - each path is merged into a single key string, delimited with v.keyDelim
-// - if a path is shadowed by an earlier value in the initial shadow map,
-//   it is skipped.
+//   - each path is merged into a single key string, delimited with v.keyDelim
+//   - if a path is shadowed by an earlier value in the initial shadow map,
+//     it is skipped.
+//
 // The resulting set of paths is merged to the given shadow set at the same 
time.
 func (v *Viper) flattenAndMergeMap(shadow map[string]bool, m 
map[string]interface{}, prefix string) map[string]bool {
        if shadow != nil && prefix != "" && shadow[prefix] {
@@ -2111,14 +2135,17 @@
 
 // Debug prints all configuration registries for debugging
 // purposes.
-func Debug() { v.Debug() }
+func Debug()              { v.Debug() }
+func DebugTo(w io.Writer) { v.DebugTo(w) }
+
+func (v *Viper) Debug() { v.DebugTo(os.Stdout) }
 
-func (v *Viper) Debug() {
-       fmt.Printf("Aliases:\n%#v\n", v.aliases)
-       fmt.Printf("Override:\n%#v\n", v.override)
-       fmt.Printf("PFlags:\n%#v\n", v.pflags)
-       fmt.Printf("Env:\n%#v\n", v.env)
-       fmt.Printf("Key/Value Store:\n%#v\n", v.kvstore)
-       fmt.Printf("Config:\n%#v\n", v.config)
-       fmt.Printf("Defaults:\n%#v\n", v.defaults)
+func (v *Viper) DebugTo(w io.Writer) {
+       fmt.Fprintf(w, "Aliases:\n%#v\n", v.aliases)
+       fmt.Fprintf(w, "Override:\n%#v\n", v.override)
+       fmt.Fprintf(w, "PFlags:\n%#v\n", v.pflags)
+       fmt.Fprintf(w, "Env:\n%#v\n", v.env)
+       fmt.Fprintf(w, "Key/Value Store:\n%#v\n", v.kvstore)
+       fmt.Fprintf(w, "Config:\n%#v\n", v.config)
+       fmt.Fprintf(w, "Defaults:\n%#v\n", v.defaults)
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/github.com/subosito/gotenv/gotenv.go 
new/vendor/github.com/subosito/gotenv/gotenv.go
--- old/vendor/github.com/subosito/gotenv/gotenv.go     2022-07-27 
14:54:08.000000000 +0200
+++ new/vendor/github.com/subosito/gotenv/gotenv.go     2022-09-27 
17:32:09.000000000 +0200
@@ -124,6 +124,7 @@
        if err != nil {
                return nil, err
        }
+       defer f.Close()
        return strictParse(f, false)
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/gopkg.in/ini.v1/deprecated.go 
new/vendor/gopkg.in/ini.v1/deprecated.go
--- old/vendor/gopkg.in/ini.v1/deprecated.go    2022-07-27 14:54:08.000000000 
+0200
+++ new/vendor/gopkg.in/ini.v1/deprecated.go    2022-09-27 17:32:09.000000000 
+0200
@@ -14,12 +14,9 @@
 
 package ini
 
-const (
+var (
        // Deprecated: Use "DefaultSection" instead.
        DEFAULT_SECTION = DefaultSection
-)
-
-var (
        // Deprecated: AllCapsUnderscore converts to format ALL_CAPS_UNDERSCORE.
        AllCapsUnderscore = SnackCase
 )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/gopkg.in/ini.v1/ini.go 
new/vendor/gopkg.in/ini.v1/ini.go
--- old/vendor/gopkg.in/ini.v1/ini.go   2022-07-27 14:54:08.000000000 +0200
+++ new/vendor/gopkg.in/ini.v1/ini.go   2022-09-27 17:32:09.000000000 +0200
@@ -23,15 +23,15 @@
 )
 
 const (
-       // DefaultSection is the name of default section. You can use this 
constant or the string literal.
-       // In most of cases, an empty string is all you need to access the 
section.
-       DefaultSection = "DEFAULT"
-
        // Maximum allowed depth when recursively substituing variable names.
        depthValues = 99
 )
 
 var (
+       // DefaultSection is the name of default section. You can use this var 
or the string literal.
+       // In most of cases, an empty string is all you need to access the 
section.
+       DefaultSection = "DEFAULT"
+
        // LineBreak is the delimiter to determine or compose a new line.
        // This variable will be changed to "\r\n" automatically on Windows at 
package init time.
        LineBreak = "\n"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/vendor/modules.txt new/vendor/modules.txt
--- old/vendor/modules.txt      2022-07-27 14:54:08.000000000 +0200
+++ new/vendor/modules.txt      2022-09-27 17:32:09.000000000 +0200
@@ -55,15 +55,12 @@
 # github.com/pelletier/go-toml v1.9.5
 ## explicit; go 1.12
 github.com/pelletier/go-toml
-# github.com/pelletier/go-toml/v2 v2.0.2
+# github.com/pelletier/go-toml/v2 v2.0.5
 ## explicit; go 1.16
 github.com/pelletier/go-toml/v2
 github.com/pelletier/go-toml/v2/internal/ast
 github.com/pelletier/go-toml/v2/internal/danger
 github.com/pelletier/go-toml/v2/internal/tracker
-# github.com/pkg/errors v0.9.1
-## explicit
-github.com/pkg/errors
 # github.com/pmezard/go-difflib v1.0.0
 ## explicit
 github.com/pmezard/go-difflib/difflib
@@ -90,7 +87,7 @@
 # github.com/spf13/pflag v1.0.5
 ## explicit; go 1.12
 github.com/spf13/pflag
-# github.com/spf13/viper v1.12.0
+# github.com/spf13/viper v1.13.0
 ## explicit; go 1.17
 github.com/spf13/viper
 github.com/spf13/viper/internal/encoding
@@ -109,7 +106,7 @@
 github.com/stretchr/testify/assert
 github.com/stretchr/testify/mock
 github.com/stretchr/testify/require
-# github.com/subosito/gotenv v1.4.0
+# github.com/subosito/gotenv v1.4.1
 ## explicit; go 1.18
 github.com/subosito/gotenv
 # golang.org/x/sys v0.0.0-20220727055044-e65921a090b8
@@ -123,7 +120,7 @@
 golang.org/x/text/unicode/norm
 # gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c
 ## explicit; go 1.11
-# gopkg.in/ini.v1 v1.66.6
+# gopkg.in/ini.v1 v1.67.0
 ## explicit
 gopkg.in/ini.v1
 # gopkg.in/yaml.v2 v2.4.0

Reply via email to