From d28a147d3c00e31af24b69aaed97cac906991673 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Carlos=20Ch=C3=A1vez?= Date: Sat, 18 Sep 2021 10:57:17 +0200 Subject: [PATCH 1/2] chore: adds support for go 1.17 on CI. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: José Carlos Chávez --- .circleci/config.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index a62505e8b..b3f9c51ed 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -63,6 +63,8 @@ workflows: name: go-1-16 go_version: "1.16" run_lint: true - # Style and unused/missing packages are only checked against - # the latest supported Go version. + - test: + name: go-1-17 + go_version: "1.17" + run_lint: true run_style_and_unused: true From 8535b620213443badedb837314aa0a6d1ee0a22c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20R=C3=BCger?= Date: Fri, 17 Dec 2021 23:07:49 +0100 Subject: [PATCH 2/2] Add new go:build lines for go 1.17 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Manuel Rüger --- prometheus/collectors/dbstats_collector_go115.go | 1 + prometheus/collectors/dbstats_collector_pre_go115.go | 1 + prometheus/process_collector_other.go | 1 + prometheus/process_collector_test.go | 1 + 4 files changed, 4 insertions(+) diff --git a/prometheus/collectors/dbstats_collector_go115.go b/prometheus/collectors/dbstats_collector_go115.go index a6e6268ce..6d152fbf1 100644 --- a/prometheus/collectors/dbstats_collector_go115.go +++ b/prometheus/collectors/dbstats_collector_go115.go @@ -11,6 +11,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build go1.15 // +build go1.15 package collectors diff --git a/prometheus/collectors/dbstats_collector_pre_go115.go b/prometheus/collectors/dbstats_collector_pre_go115.go index 0568affe2..65235069d 100644 --- a/prometheus/collectors/dbstats_collector_pre_go115.go +++ b/prometheus/collectors/dbstats_collector_pre_go115.go @@ -11,6 +11,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build !go1.15 // +build !go1.15 package collectors diff --git a/prometheus/process_collector_other.go b/prometheus/process_collector_other.go index 3117461cd..2dc3660da 100644 --- a/prometheus/process_collector_other.go +++ b/prometheus/process_collector_other.go @@ -11,6 +11,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build !windows // +build !windows package prometheus diff --git a/prometheus/process_collector_test.go b/prometheus/process_collector_test.go index 7b19c5e05..3a604aba9 100644 --- a/prometheus/process_collector_test.go +++ b/prometheus/process_collector_test.go @@ -11,6 +11,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +//go:build linux // +build linux package prometheus