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

sentry: structured.go:1635: missing fk forward reference × to × from × (un-upgraded foreign key references present) -- *errutil.leafError: missing fk forward reference × to × from × (un-upgraded foreign key references present) (1) structured.go:1635: *withstack.withStack (top exception) *assert.withAssertionFailure (check the extra data payloads) #61618

Closed
cockroach-teamcity opened this issue Mar 8, 2021 · 1 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.

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/2260021731/?referrer=webhooks_plugin

Panic message:

structured.go:1635: missing fk forward reference × to × from × (un-upgraded foreign key references present)
--
*errutil.leafError: missing fk forward reference × to × from × (un-upgraded foreign key references present) (1)
structured.go:1635: *withstack.withStack (top exception)
*assert.withAssertionFailure
(check the extra data payloads)

Stacktrace (expand for inline code snippets):

if unupgradedFKsPresent {
return errors.AssertionFailedf("missing fk forward reference %q to %q from %q "+
"(un-upgraded foreign key references present)",
in pkg/sql/catalog/tabledesc.(*Immutable).validateCrossReferences
}
return desc.validateCrossReferences(ctx, dg)
}
in pkg/sql/catalog/tabledesc.(*Immutable).Validate
}
if err := immTable.Validate(ctx, dg); err != nil {
return nil, err
in pkg/sql/catalog/catalogkv.unwrapDescriptor
var err error
if descs[i], err = unwrapDescriptor(ctx, dg, kv.Value.Timestamp, desc); err != nil {
return nil, err
in pkg/sql/catalog/catalogkv.GetAllDescriptors
if tc.allDescriptors == nil {
descs, err := catalogkv.GetAllDescriptors(ctx, txn, tc.codec())
if err != nil {
in pkg/sql/catalog/descs.(*Collection).GetAllDescriptors
) error {
descs, err := p.Descriptors().GetAllDescriptors(ctx, p.txn)
if err != nil {
in pkg/sql.forEachTableDescWithTableLookupInternal
) error {
return forEachTableDescWithTableLookupInternal(ctx, p, dbContext, virtualOpts, false /* allowAdding */, fn)
}
in pkg/sql.forEachTableDescWithTableLookup
h := makeOidHasher()
return forEachTableDescWithTableLookup(ctx, p, dbContext, virtualOpts,
func(db *dbdesc.Immutable, scName string, table catalog.TableDescriptor, lookup tableLookupFn) error {
in pkg/sql.makeAllRelationsVirtualTableWithDescriptorIDIndex.func1
generator, cleanup := setupGenerator(ctx, func(pusher rowPusher) error {
return def.populate(ctx, p, dbDesc, func(row ...tree.Datum) error {
if err := e.validateRow(row, columns); err != nil {
in pkg/sql.virtualDefEntry.getPlanInfo.func1.1
}
err := worker(funcRowPusher(addRow))
// If the query was canceled, next() will already return a
in pkg/sql.setupGenerator.func2
/usr/local/go/src/runtime/asm_amd64.s#L1356-L1358 in runtime.goexit

pkg/sql/catalog/tabledesc/structured.go in pkg/sql/catalog/tabledesc.(*Immutable).validateCrossReferences at line 1635
pkg/sql/catalog/tabledesc/structured.go in pkg/sql/catalog/tabledesc.(*Immutable).Validate at line 1440
pkg/sql/catalog/catalogkv/catalogkv.go in pkg/sql/catalog/catalogkv.unwrapDescriptor at line 298
pkg/sql/catalog/catalogkv/catalogkv.go in pkg/sql/catalog/catalogkv.GetAllDescriptors at line 390
pkg/sql/catalog/descs/collection.go in pkg/sql/catalog/descs.(*Collection).GetAllDescriptors at line 1545
pkg/sql/information_schema.go in pkg/sql.forEachTableDescWithTableLookupInternal at line 1864
pkg/sql/information_schema.go in pkg/sql.forEachTableDescWithTableLookup at line 1825
pkg/sql/pg_catalog.go in pkg/sql.makeAllRelationsVirtualTableWithDescriptorIDIndex.func1 at line 930
pkg/sql/virtual_schema.go in pkg/sql.virtualDefEntry.getPlanInfo.func1.1 at line 492
pkg/sql/virtual_table.go in pkg/sql.setupGenerator.func2 at line 115
/usr/local/go/src/runtime/asm_amd64.s in runtime.goexit at line 1357
Tag Value
Cockroach Release v20.2.2
Cockroach SHA: 92d9495
Platform darwin amd64
Distribution CCL
Environment v20.2.2
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 Mar 8, 2021
@yuzefovich
Copy link
Member

dup of #57032

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

2 participants