hypothesis / agreements

the promises we make to our users
6 stars 3 forks source link

OperationalError: (psycopg2.OperationalError) index row size 3456 exceeds maximum 2712 for index "uq__document_uri_... #12

Closed sentry-io[bot] closed 4 years ago

sentry-io[bot] commented 4 years ago

Sentry Issue: H-1SP

OperationalError: index row size 3456 exceeds maximum 2712 for index "uq__document_uri__claimant_normalized"
HINT:  Values larger than 1/3 of a buffer page cannot be indexed.
Consider a function index of an MD5 hash of the value, or use full text indexing.

  File "sqlalchemy/engine/base.py", line 1244, in _execute_context
    cursor, statement, parameters, context
  File "sqlalchemy/engine/default.py", line 552, in do_execute
    cursor.execute(statement, parameters)
  File "newrelic/hooks/database_psycopg2.py", line 51, in execute
    **kwargs)
  File "newrelic/hooks/database_dbapi2.py", line 25, in execute
    *args, **kwargs)

OperationalError: (psycopg2.OperationalError) index row size 3456 exceeds maximum 2712 for index "uq__document_uri__claimant_normalized"
HINT:  Values larger than 1/3 of a buffer page cannot be indexed.
Consider a function index of an MD5 hash of the value, or use full text indexing.

[SQL: INSERT INTO document_uri (created, updated, claimant, claimant_normalized, uri, uri_normalized, type, content_type, document_id) VALUES (%(created)s, %(updated)s, %(claimant)s, %(claimant_normalized)s, %(uri)s, %(uri_normalized)s, %(ty...
(42 additional frame(s) were not displayed)
...
  File "sqlalchemy/util/compat.py", line 152, in reraise
    raise value.with_traceback(tb)
  File "sqlalchemy/engine/base.py", line 1244, in _execute_context
    cursor, statement, parameters, context
  File "sqlalchemy/engine/default.py", line 552, in do_execute
    cursor.execute(statement, parameters)
  File "newrelic/hooks/database_psycopg2.py", line 51, in execute
    **kwargs)
  File "newrelic/hooks/database_dbapi2.py", line 25, in execute
    *args, **kwargs)