Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

/_synapse/admin/v2/users is broken #6552

@aaronraimist

Description

@aaronraimist

Running the /_synapse/admin/v2/users as documented produces an internal server error

Postgres logs:

STATEMENT:  SELECT name, password_hash, is_guest, admin, user_type, deactivated FROM users WHERE is_guest = false AND deactivated = false ORDER BY name ASC LIMIT 10 OFFSET 0
ERROR:  operator does not exist: smallint = boolean at character 95

\d users shows that is_guest and deactivated are type smallint not boolean.


                          Table "public.users"
           Column           |   Type   | Collation | Nullable | Default
----------------------------+----------+-----------+----------+---------
 name                       | text     |           |          |
 password_hash              | text     |           |          |
 creation_ts                | bigint   |           |          |
 admin                      | smallint |           | not null | 0
 upgrade_ts                 | bigint   |           |          |
 is_guest                   | smallint |           | not null | 0
 appservice_id              | text     |           |          |
 consent_version            | text     |           |          |
 consent_server_notice_sent | text     |           |          |
 user_type                  | text     |           |          |
 deactivated                | smallint |           | not null | 0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions