pg_bloat_check icon indicating copy to clipboard operation
pg_bloat_check copied to clipboard

Using --debug with other options does not work

Open turnstep opened this issue 2 years ago • 2 comments

I can use --debug just fine if the only option.

I can use --table pgbench_accounts fine as the only option.

Combined, they give an error:


$ pg_bloat_check.py --table pgbench_accounts --debug
quiet level: 0
Traceback (most recent call last):
  File "/bin/pg_bloat_check.py", line 698, in <module>
    get_bloat(conn, tuple(exclude_schema_list), tuple(include_schema_list), exclude_object_list)
  File "/bin/pg_bloat_check.py", line 201, in get_bloat
    print("sql_class: " + cur.mogrify(sql_class, [args.tablename, args.tablename] ) )
TypeError: must be str, not bytes

Version is 2.7.0

turnstep avatar Oct 24 '22 21:10 turnstep

Pushed a fix to branch https://github.com/keithf4/pg_bloat_check/tree/2.7.1

Found a few other spots that were missing the conversion as well. Let me know if that works ok now.

keithf4 avatar Oct 24 '22 21:10 keithf4

Working now, thanks!

turnstep avatar Oct 28 '22 15:10 turnstep

Released version 2.7.1 with fix. Thanks for reporting and testing!

keithf4 avatar Oct 31 '22 17:10 keithf4