ProgrammingError raised from silk_clear_request_log #293
Closed
Description
$ sudo docker exec -i -t compose_backend_1 python manage.py silk_clear_request_log
WARNING|2018-07-03 12:36:42,765|silk.profiling.profiler>>
Cannot execute silk_profile as silk is not installed correctly.
Traceback (most recent call last):
File "manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 364, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 356, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 283, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 330, in execute
output = self.handle(*args, **options)
File "/usr/local/lib/python2.7/dist-packages/silk/management/commands/silk_clear_request_log.py", line 41, in handle
Command.delete_model(silk.models.Profile)
File "/usr/local/lib/python2.7/dist-packages/silk/management/commands/silk_clear_request_log.py", line 21, in delete_model
cursor.execute("ALTER TABLE %s DISABLE TRIGGER ALL;", [table])
File "/usr/local/lib/python2.7/dist-packages/cachalot/monkey_patch.py", line 119, in inner
return original(cursor, sql, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/local/lib/python2.7/dist-packages/django/db/utils.py", line 94, in __exit__
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/local/lib/python2.7/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
django.db.utils.ProgrammingError: syntax error at or near "'silk_profile'"
LINE 1: ALTER TABLE 'silk_profile' DISABLE TRIGGER ALL;
^
DB is library/postgres:9.4.5
Metadata
Assignees
Labels
No labels