Environment:
- Go Version:
go1.23.8 darwin/arm64
github.com/ClickHouse/ch-go version: v0.66.0 (and later versions pulled as a dependency by github.com/ClickHouse/clickhouse-go/[email protected] or @latest)
- Operating System: macOS (darwin/arm64)
Observed Behavior:
When attempting to build a project that depends on github.com/ClickHouse/clickhouse-go/v2 (which in turn depends on ch-go), the build fails with the following error:
This error occurs because the file proto/col_arr_go123.go within the ch-go module, which is compiled due to the //go:build go1.23 build tag, attempts to import "iter".
File content (proto/col_arr_go123.go in [email protected]):
//go:build go1.23
package proto
import "iter"
// RowRange returns a [iter.Seq] iterator over i-th row.
func (c ColArr[T]) RowRange(i int) iter.Seq[T] {
var start int
end := int(c.Offsets[i])
if i > 0 {
start = int(c.Offsets[i-1])
}
return func(yield func(T) bool) {
for idx := start; idx < end; idx++ {
if !yield(c.Data.Row(idx)) {
return
}
}
}
}