pg_activity: bytea field causing stacktrace

Can pg_activity ignore columns? Thanks.

  File "/usr/local/bin/pg_activity", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.8/dist-packages/pgactivity/cli.py", line 299, in main
    ui.main(term, dataobj, host, options, dsn)
  File "/usr/local/lib/python3.8/dist-packages/pgactivity/ui.py", line 196, in main
    pg_procs.set_items(data.pg_get_activities(ui.duration_mode))
  File "/usr/local/lib/python3.8/dist-packages/pgactivity/data.py", line 261, in pg_get_activities
    cur.execute(
  File "/usr/local/lib/python3.8/dist-packages/psycopg2/extras.py", line 146, in execute
    return super().execute(query, vars)
psycopg2.errors.InvalidTextRepresentation: invalid input syntax for type bytea

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 15 (1 by maintainers)

Most upvoted comments

@alepaes1975 please try this

postgresql://postgres@localhost/postgres?options=-c%20standard_conforming_strings%3Don

see https://www.postgresql.org/docs/14/libpq-connect.html#id-1.7.3.8.3.6 there is an example about options.

I have pg_activity running on another system, very nice! Nice work and definitely appreciated. SO when a query occurs that is accessing a bytea column the stack trace occurs otherwise normal operation