Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sql: v20.2.0-alpha.1: unsupported comparison op with collated strings #56257

Closed
cockroach-teamcity opened this issue Nov 3, 2020 · 2 comments
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. O-sentry Originated from an in-the-wild panic report.

Comments

@cockroach-teamcity
Copy link
Member

This issue was autofiled by Sentry. It represents a crash or reported error on a live cluster with telemetry enabled.

Sentry link: https://sentry.io/organizations/cockroach-labs/issues/2005075033/?referrer=webhooks_plugin

Panic message:

*barriers.barrierError: -- details for github.com/cockroachdb/cockroach/pkg/sql/pgwire/pgerror/*pgerror.withCandidateCode::: (1)
*errutil.withMessage
*safedetails.withSafeDetails: %s (2)
expr.go:78: *withstack.withStack (top exception)
*assert.withAssertionFailure
(check the extra data payloads)

Stacktrace (expand for inline code snippets):

// Type checking must succeed by now.
return nil, errors.NewAssertionErrorWithWrappedErrf(err, "%s", expr)
}
in pkg/sql/execinfra.processExpression
semaContext.TypeResolver = evalCtx.DistSQLTypeResolver
eh.Expr, err = processExpression(expr, evalCtx, &semaContext, &eh.Vars)
if err != nil {
in pkg/sql/execinfra.(*ExprHelper).Init
h.filter = &ExprHelper{}
if err := h.filter.Init(post.Filter, typs, evalCtx); err != nil {
return err
in pkg/sql/execinfra.(*ProcOutputHelper).Init
return pb.Out.Init(post, types, pb.EvalCtx, output)
}
in pkg/sql/execinfra.(*ProcessorBase).InitWithEvalCtx
) error {
return pb.InitWithEvalCtx(
self, post, types, flowCtx, flowCtx.NewEvalCtx(), processorID, output, memMonitor, opts,
in pkg/sql/execinfra.(*ProcessorBase).Init
tr.ignoreMisplannedRanges = flowCtx.Local
if err := tr.Init(
tr,
in pkg/sql/rowexec.newTableReader
}
return newTableReader(flowCtx, processorID, core.TableReader, post, outputs[0])
}
in pkg/sql/rowexec.NewProcessor
outputs := []execinfra.RowReceiver{output}
proc, err := rowexec.NewProcessor(
ctx,
in pkg/sql/rowflow.(*rowBasedFlow).makeProcessor
pspec := &spec.Processors[i]
p, err := f.makeProcessor(ctx, pspec, inputSyncs[i])
if err != nil {
in pkg/sql/rowflow.(*rowBasedFlow).setupProcessors
// Then, populate processors.
return ctx, f.setupProcessors(ctx, spec, inputSyncs)
}
in pkg/sql/rowflow.(*rowBasedFlow).Setup
var err error
if ctx, err = f.Setup(ctx, &req.Flow, opt); err != nil {
log.Errorf(ctx, "error setting up flow: %s", err)
in pkg/sql/distsql.(*ServerImpl).setupFlow
) (context.Context, flowinfra.Flow, error) {
ctx, f, err := ds.setupFlow(ctx, opentracing.SpanFromContext(ctx), parentMonitor, req, output,
localState)
in pkg/sql/distsql.(*ServerImpl).SetupLocalSyncFlow
defer physicalplan.ReleaseSetupFlowRequest(&localReq)
ctx, flow, err := dsp.distSQLSrv.SetupLocalSyncFlow(ctx, evalCtx.Mon, &localReq, recv, localState)
if err != nil {
in pkg/sql.(*DistSQLPlanner).setupFlows
ctx, flow, err := dsp.setupFlows(ctx, evalCtx, leafInputState, flows, recv, localState, vectorizedThresholdMet)
if err != nil {
in pkg/sql.(*DistSQLPlanner).Run
recv.expectedRowsRead = int64(physPlan.TotalEstimatedScannedRows)
return dsp.Run(planCtx, txn, physPlan, recv, evalCtx, nil /* finishedSetupFn */)
}
in pkg/sql.(*DistSQLPlanner).PlanAndRun
// the planner whether or not to plan remote table readers.
cleanup := ex.server.cfg.DistSQLPlanner.PlanAndRun(
ctx, evalCtx, planCtx, planner.txn, planner.curPlan.main, recv,
in pkg/sql.(*connExecutor).execWithDistSQLEngine
ex.sessionTracing.TraceExecStart(ctx, "distributed")
bytesRead, rowsRead, err := ex.execWithDistSQLEngine(ctx, planner, stmt.AST.StatementType(), res, distributePlan, progAtomic)
ex.sessionTracing.TraceExecEnd(ctx, res.Err(), res.RowsAffected())
in pkg/sql.(*connExecutor).dispatchToExecutionEngine
p.autoCommit = os.ImplicitTxn.Get() && !ex.server.cfg.TestingKnobs.DisableAutoCommit
if err := ex.dispatchToExecutionEngine(ctx, p, res); err != nil {
return nil, nil, err
in pkg/sql.(*connExecutor).execStmtInOpenState
} else {
ev, payload, err = ex.execStmtInOpenState(ctx, stmt, res, pinfo)
}
in pkg/sql.(*connExecutor).execStmt
stmtCtx := withStatement(ctx, ex.curStmt)
ev, payload, err = ex.execStmt(stmtCtx, curStmt, stmtRes, nil /* pinfo */)
if err != nil {
in pkg/sql.(*connExecutor).execCmd
var err error
if err = ex.execCmd(ex.Ctx()); err != nil {
if errors.IsAny(err, io.EOF, errDrainingComplete) {
in pkg/sql.(*connExecutor).run
}()
return h.ex.run(ctx, s.pool, reserved, cancel)
}
in pkg/sql.(*Server).ServeConn
reservedOwned = false // We're about to pass ownership away.
retErr = sqlServer.ServeConn(ctx, connHandler, reserved, cancelConn)
}()
in pkg/sql/pgwire.(*conn).processCommandsAsync.func1
/usr/local/go/src/runtime/asm_amd64.s#L1356-L1358 in runtime.goexit

pkg/sql/execinfra/expr.go in pkg/sql/execinfra.processExpression at line 78
pkg/sql/execinfra/expr.go in pkg/sql/execinfra.(*ExprHelper).Init at line 162
pkg/sql/execinfra/processorsbase.go in pkg/sql/execinfra.(*ProcOutputHelper).Init at line 108
pkg/sql/execinfra/processorsbase.go in pkg/sql/execinfra.(*ProcessorBase).InitWithEvalCtx at line 805
pkg/sql/execinfra/processorsbase.go in pkg/sql/execinfra.(*ProcessorBase).Init at line 775
pkg/sql/rowexec/tablereader.go in pkg/sql/rowexec.newTableReader at line 95
pkg/sql/rowexec/processors.go in pkg/sql/rowexec.NewProcessor at line 138
pkg/sql/rowflow/row_based_flow.go in pkg/sql/rowflow.(*rowBasedFlow).makeProcessor at line 228
pkg/sql/rowflow/row_based_flow.go in pkg/sql/rowflow.(*rowBasedFlow).setupProcessors at line 81
pkg/sql/rowflow/row_based_flow.go in pkg/sql/rowflow.(*rowBasedFlow).Setup at line 64
pkg/sql/distsql/server.go in pkg/sql/distsql.(*ServerImpl).setupFlow at line 366
pkg/sql/distsql/server.go in pkg/sql/distsql.(*ServerImpl).SetupLocalSyncFlow at line 480
pkg/sql/distsql_running.go in pkg/sql.(*DistSQLPlanner).setupFlows at line 265
pkg/sql/distsql_running.go in pkg/sql.(*DistSQLPlanner).Run at line 388
pkg/sql/distsql_running.go in pkg/sql.(*DistSQLPlanner).PlanAndRun at line 1008
pkg/sql/conn_executor_exec.go in pkg/sql.(*connExecutor).execWithDistSQLEngine at line 903
pkg/sql/conn_executor_exec.go in pkg/sql.(*connExecutor).dispatchToExecutionEngine at line 800
pkg/sql/conn_executor_exec.go in pkg/sql.(*connExecutor).execStmtInOpenState at line 488
pkg/sql/conn_executor_exec.go in pkg/sql.(*connExecutor).execStmt at line 99
pkg/sql/conn_executor.go in pkg/sql.(*connExecutor).execCmd at line 1356
pkg/sql/conn_executor.go in pkg/sql.(*connExecutor).run at line 1285
pkg/sql/conn_executor.go in pkg/sql.(*Server).ServeConn at line 490
pkg/sql/pgwire/conn.go in pkg/sql/pgwire.(*conn).processCommandsAsync.func1 at line 595
/usr/local/go/src/runtime/asm_amd64.s in runtime.goexit at line 1357
Tag Value
Cockroach Release v20.2.0-alpha.1
Cockroach SHA: 59b7964
Platform darwin amd64
Distribution CCL
Environment v20.2.0-alpha.1
Command start-single-node
Go Version ``
# of CPUs
# of Goroutines
@cockroach-teamcity cockroach-teamcity added C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. O-sentry Originated from an in-the-wild panic report. labels Nov 3, 2020
@yuzefovich
Copy link
Member

SELECT * FROM _ WHERE _ = (_ COLLATE en_US_u_ks_level2)
-- details for github.com/cockroachdb/cockroach/pkg/sql/pgwire/pgerror/*pgerror.withCandidateCode:::
22023
-- details for github.com/cockroachdb/cockroach/vendor/github.com/cockroachdb/errors/withstack/*withstack.withStack:::

github.com/cockroachdb/cockroach/pkg/sql/sem/tree.typeCheckComparisonOp
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/sem/tree/type_check.go:2023
github.com/cockroachdb/cockroach/pkg/sql/sem/tree.(*ComparisonExpr).TypeCheck
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/sem/tree/type_check.go:728
github.com/cockroachdb/cockroach/pkg/sql/sem/tree.TypeCheck
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/sem/tree/type_check.go:276
github.com/cockroachdb/cockroach/pkg/sql/execinfra.processExpression
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/execinfra/expr.go:75
github.com/cockroachdb/cockroach/pkg/sql/execinfra.(*ExprHelper).Init
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/execinfra/expr.go:162
github.com/cockroachdb/cockroach/pkg/sql/execinfra.(*ProcOutputHelper).Init
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/execinfra/processorsbase.go:108
github.com/cockroachdb/cockroach/pkg/sql/execinfra.(*ProcessorBase).InitWithEvalCtx
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/execinfra/processorsbase.go:805
github.com/cockroachdb/cockroach/pkg/sql/execinfra.(*ProcessorBase).Init
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/execinfra/processorsbase.go:775
github.com/cockroachdb/cockroach/pkg/sql/rowexec.newTableReader
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/rowexec/tablereader.go:95
github.com/cockroachdb/cockroach/pkg/sql/rowexec.NewProcessor
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/rowexec/processors.go:138
github.com/cockroachdb/cockroach/pkg/sql/rowflow.(*rowBasedFlow).makeProcessor
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/rowflow/row_based_flow.go:228
github.com/cockroachdb/cockroach/pkg/sql/rowflow.(*rowBasedFlow).setupProcessors
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/rowflow/row_based_flow.go:81
github.com/cockroachdb/cockroach/pkg/sql/rowflow.(*rowBasedFlow).Setup
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/rowflow/row_based_flow.go:64
github.com/cockroachdb/cockroach/pkg/sql/distsql.(*ServerImpl).setupFlow
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/distsql/server.go:366
github.com/cockroachdb/cockroach/pkg/sql/distsql.(*ServerImpl).SetupLocalSyncFlow
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/distsql/server.go:480
github.com/cockroachdb/cockroach/pkg/sql.(*DistSQLPlanner).setupFlows
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/distsql_running.go:265
github.com/cockroachdb/cockroach/pkg/sql.(*DistSQLPlanner).Run
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/distsql_running.go:388
github.com/cockroachdb/cockroach/pkg/sql.(*DistSQLPlanner).PlanAndRun
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/distsql_running.go:1008
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).execWithDistSQLEngine
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor_exec.go:903
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).dispatchToExecutionEngine
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor_exec.go:800
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).execStmtInOpenState
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor_exec.go:488
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).execStmt
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor_exec.go:99
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).execCmd
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor.go:1356
github.com/cockroachdb/cockroach/pkg/sql.(*connExecutor).run
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor.go:1285
github.com/cockroachdb/cockroach/pkg/sql.(*Server).ServeConn
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/conn_executor.go:490
github.com/cockroachdb/cockroach/pkg/sql/pgwire.(*conn).processCommandsAsync.func1
	/go/src/github.com/cockroachdb/cockroach/pkg/sql/pgwire/conn.go:595
runtime.goexit
	/usr/local/go/src/runtime/asm_amd64.s:1357
-- details for github.com/cockroachdb/cockroach/vendor/github.com/cockroachdb/errors/safedetails/*safedetails.withSafeDetails:::
unsupported comparison operator: %s
-- arg 1: <string>
-- details for errors/*errors.errorString:::

@yuzefovich yuzefovich changed the title sentry: *barriers.barrierError: -- details for github.com/cockroachdb/cockroach/pkg/sql/pgwire/pgerror/*pgerror.withCandidateCode::: (1) *errutil.withMessage *safedetails.withSafeDetails: %s (2) expr.go:78: *withstack.withStack (top exception) *assert.withAssertionFailure (check the extra data payloads) sql: v20.2.0-alpha.1: unsupported comparison op with collated strings Nov 3, 2020
@asubiotto
Copy link
Contributor

Customer issue that is being looked into (#56335).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. O-sentry Originated from an in-the-wild panic report.
Projects
None yet
Development

No branches or pull requests

3 participants