Closed acheccuc closed 8 years ago
I tried to create the bloat objects in a non-default schema without a lot of luck:
-bash-4.2$ ./pg_bloat_check.py -c "dbname=unpprpro" --create_stats_table --bloat_schema myschema Traceback (most recent call last): File "./pg_bloat_check.py", line 327, in <module> create_bloat_table(conn) File "./pg_bloat_check.py", line 77, in create_bloat_table create_sql += args.view_schema + "." AttributeError: 'Namespace' object has no attribute 'view_schema'
Checking the code it seems like args.view_schema never gets a value... This is a simple printout of the parsed command line arguments:
-bash-4.2$ ./pg_bloat_check.py -c "dbname=unpprpro" --create_stats_table --bloat_schema myschema Namespace(bloat_schema='myschema', commit_rate=5, connection='dbname=unpprpro', create_stats_table=True, debug=False, exclude_object_file=None, exclude_schema=None, format='simple', min_size=1, min_wasted_percentage=0.1, min_wasted_size=1, mode='both', norescan=False, pgstattuple_schema=None, quick=False, quiet=False, schema=None, tablename=None, version=False)
That's what I get for not testing all my options. Will have this fixed in next version. Thanks!
Released v2.1.0 with this fixed. Thanks again!
I tried to create the bloat objects in a non-default schema without a lot of luck:
Checking the code it seems like args.view_schema never gets a value... This is a simple printout of the parsed command line arguments: